问题总结第一张专辑(2005年开始)[10]

[入库:2005年9月19日] [更新:2007年3月24日]

本文简介:

The error messages that is most frustrating, however, are this pair of messages. On some installations, We get these errors, and on other installations, We don’t. 


INIT: f a i l e d o n w r i t e o f u t m p x entry:“sO” 
INIT: f a i l e d o n w r i t e o f u t m p x entry:“fw” 
For a long time, We’ve just been putting up with these error messages. It turns out that these messages occur for a similar reason as the previous error. 
Here, the init command is trying to update the utmpx log file, which contains information about system run-level transitions, as well as user login and logout information. On some Solaris installations, the /var file system was on a separate partition! 
When Solaris goes to run level 0, it un-mounts all the expendable file systems, such as /var. However, init then tries to enter this information in the log file, which is no longer accessible. That certainly clears things up! 
Thus, all you do is provide a place for init to write your log file entries. If you really don’t care about the run-level transition messages, you can just write the information to/dev/null, and it’ll be thrown away without a trace. To do this, shut down your system and restart it. However, when you restart it, make sure you issue a boot -s command to boot it initially in single-user mode. Once you’ve booted up in single-user mode, enter these commands: 

# umount /var 
# mkdir /var/adm 
# ln -s /dev/null /var/adm/utmpx 
# ln -s /dev/null /var/adm/utmp 
(If you try to bypass the boot -s step by executing the init S command to go to single-user mode, umount will tell you that the /var file system is busy. Don’t even try to circumvent the shutdown/boot -s procedure, it won’t work.) 
Now we simply have a fake file system at the /var mount point. So when Solaris unmounts /var, the files /var/adm/utmpx and /var/adm/utmp will still exist. (They just won’t be the same ones.) Now, init won’t fail when it writes the log entries. You might wonder why we created both utmpx and utmp, when init was complaining only about utmpx. It turns out that if you create the utmpx file, init then complains about the utmp file. It writes log entries to both files, but writes to utmpx (and fails) first. 

本文关键:问题总结第一张专辑(2005年开始)
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top