This article is from a FAQ concerning SCO operating systems. While some of the information may be applicable to any OS, or any Unix or Linux OS, it may be specific to SCO Xenix, Open This is an old article about sar on SCO Unix and is only left here for historical purposes. There is lots of Linux, Mac OS X and general Unix info elsewhere on this site: Search this site is the best way to find anything.
First off - did you run sar_enable? This is a new command in OSR5 which sets everything up so that sar runs as it did previously. If sar isn't enabled, it simply won't run. Run /usr/lib/sa/sar_enable -y for starters. You will also need to edit root's and sys' crontab files if you wish data to be collected 24 hours a day, seven days a week. Also, if you wish to keep sar data for more than seven days, remove the 'find' command in the last line of /usr/lib/sar/sa2.
The file /etc/ps/booted.kernel gives the name of the booted kernel, and sar needs this to work properly. This file gets created each time the system is rebooted. In case it's messed up, try running kernel -uv and see if that cures it.
There is another problem, though, which may not be cured by the above. There is a bug in the code in /boot. If the inode number of the kernel is greater than 32767, /boot improperly sign-extends it as a signed short integer rather than an unsigned one, and the end result is a completely wacky inode number. This should only happen on systems without a separate boot filesystem, which generally means those which were upgraded from an earlier release in place. The following is a patch to /boot which should cure the problem in 5.0.0; the TA from which it was derived (482688) states that this problem is for 5.0.0, but it also exists in 5.0.2. Be VERY careful, as always, applying patches; this one in particular may disable your system entirely if not done correctly.
# cp -p /boot /boot.orig # what /boot /boot: SCO boot 23 Apr 95 # sum -r /boot 00357 134 /boot
If either the results of what, or the results of sum -r, don't match exactly what you see above, stop! Do not apply this patch unless these are identical to the results you see.
# echo 3f:feb?h 90 | _fst -w /boot - * 3f:feb?h 90 0x3f:0xfeb: 0x99 = 0x90 # sum -r /boot 09082 134 boot
Again, if the results of sum -r don't match exactly what you see, something did not work correctly. You should copy /boot.orig back to /boot.
If you found something useful today, please consider a small donation.
Got something to add? Send me email.
Whenever the literary German dives into a sentence, that is the last you are going to see of him till he emerges on the other side of his Atlantic with his verb in his mouth. (Mark Twain)