Path: utzoo!utgpu!water!watmath!uunet!ukma!cwjcc!tut.cis.ohio-state.edu!osu-cis!att!ihopa!ihop3!ihtlt!kosman!kevin From: kevin@kosman.UUCP (Kevin O'Gorman) Newsgroups: unix-pc.general Subject: Re: /usr/adm/unix.log Message-ID: <458@kosman.UUCP> Date: 20 Sep 88 16:30:05 GMT References: <10585@stb.UUCP> Reply-To: kevin@kosman.UUCP (Root) Organization: K.O.'s Manor - Vital Computer Systems, Oxnard, CA 93035 Lines: 45 In article <10585@stb.UUCP> michael@stb.UUCP (Michael) writes: >I just discovered /usr/adm/unix.log > >Questions: >#1. Does the system verify writes to the hard drive? >#2. How many repeats will the system take before it considers the read to >fail? (If it takes 10 tries, I won't consider my repeats of 1 to be a problem) >#3. Why doesn't a surface check find these? >#4. Is there any way to get these mesages into a more noticable place >(such as SMRG's message queue?) Well, here's the shell script I run every night from /usr/lib/crontab. It saves the log daily, keeping a week's worth, and mails the daily segments to root, so that you actually see this stuff. It could be made lots better with some massaging, a la perl, but this at least lets me see what's what. # /usr/local/bin/trimlog # if this is run once per day, it will save the last # weeks worth of hardware error-log files. You can, of course, comment # out some of the lines to save less cd /usr/adm mv ulog.5 ulog.6 mv ulog.4 ulog.5 mv ulog.3 ulog.4 mv ulog.2 ulog.3 mv ulog.1 ulog.2 mv ulog.0 ulog.1 mv unix.log ulog.0 cp /dev/null unix.log if [ -s ulog.0 ] then (echo "Contents of unix.log:"; cat ulog.0) | /bin/mail -t root fi > Michael >p.s. If the system doesn't verify writes (to both floppy and hard), how can >we/I make it verify them? >: --- >: Michael Gersten uunet.uu.net!denwa!stb!michael >: sdcsvax!crash!gryphon!denwa!stb!michael >: Coff Coff <=== Stop smoking.