-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Chadley Wilson wrote:
|On Wednesday 12 January 2005 19:09, Alexander Dalloz wrote: | |>Am Mi, den 12.01.2005 schrieb Chadley Wilson um 17:52: |> |>>>grep "cpu1" /proc/stat |>>> |>>>Test this. If at least cpu1 appears there, then you have an SMP system. |>>>This is more reliable than to check whether an SMP kernel is running. |>>> |>>>>Chadley Wilson |>>> |>>>Alexander |>> |>>Thanks Alexander I will try your suggestion but in the morning, I will |>>add it to my script so long. |>> |>>Question though, will that not reflect results based on the current |>>running kernel? (should it be a non smp kernel) |>> |>>Chadley Wilson |> |>You mean the case, you have an SMP system but don't want to run the SMP |>kernel? Then improve your decision logic in the script! |> |>if cpu1 exists and uname has smp -> install SMP kernel |>if cpu1 exists and uname shows single CPU kernel running -> install |>normal kernel |> |>Or install both kernel types (if cpu1 exists) and decide which you make |>active in grub based on the info which kernel is running actually. |> |>Alexander | | |No no, you misunderstand what I mean, Sorry I will explain. |If I have an smp cpu but I am running the std kernel, will | |grep "cpu1" /proc/stat | |return the value of a std cpu running instead of a smp cpu? |ie: nothing | | | | | | No, Alexander is correct. An SMP kernel only applies to running on more than one CPU. With a normal kernel and single, dual or quad (SMP) you will only get cpu0 file. If you have an SMP kernel and running on a board with more than one CPU, you will get multiple cpu? files. One file for each CPU.
SMP is not the CPU; but a standard way of handling multiple CPUs in the same system.
Good Luck, James -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFB5XR7kNLDmnu1kSkRAqSYAJ92k40W/YO/RqLd2YlZ8gBy2AImmQCdGzYB s9+pU5KNAcqXvV3VQOL18I0= =EO0v -----END PGP SIGNATURE-----