Re: smp kernel bash script

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Mi, den 12.01.2005 schrieb Chadley Wilson um 16:19:

> When you install Fedora 2 or 3 it detects which CPU and then loads either the 
> smp or normal kernel for you. when it loads the smp it stills give the normal 
> as an option in grub.
> My script simply says something like this ( IIRC don't have it with me! ) :
> 
> uname -a |grep smp
> if [$? -eq 0 ] then 
> rpm -ivh kernel-smp.*.rpm
> rpm -ivh kernel-smp.*.src
> 
> you get the picture I hope ;)
> 
> Today my script bites the dust as it installed a std kernel when it should 
> have installed the smp.
> I can easily fix this. Thats not the issue.

> How can check if the cpu is an smp and add some test to my script. This way 
> even if the Fedora gets it wrong my script will fix it when applying all my 
> atches and upgrading the kernels.

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


-- 
Alexander Dalloz | Enger, Germany | new address - new key: 0xB366A773
legal statement: http://www.uni-x.org/legal.html
Fedora GNU/Linux Core 2 (Tettnang) on Athlon kernel 2.6.10-1.8_FC2smp 
Serendipity 16:39:00 up 1 day, 14:49, load average: 0.15, 0.22, 0.34 

Attachment: signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux