[ale] shutdown from cron

Unix Guru Dude geof at denali.is.net
Mon Mar 4 11:39:00 EST 1996


}
}> }> I posted a question earlier regarding running shutdown from cron causing
}> }> fsck to run upon rebooting.  I don't understand why, but I have a bit more
}> }> info.  The output of stderr is:
}> }> 
}> }> umount: /dev/hdb3: device is busy
}> }> 
}> }> Now this is my / filesystem, and although I fully understand what is going
}> }> this means, I don't understand why I get the device busy message when
}> }> running it out of cron vs. running it on the command line.  In either case
}> }> the / filesystem is occupied.  Any clues? 
}
}> I've tried a few.  Right now it's '/sbin/shutdown -r -t 30 now.' All
}> variations cause fsck to run.  Question is, maybe this is not a problem.
}> Fsck always returns with the same message:
}> 
}> fix summary information (Yes)
}  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^This _really_ is not good...
}
}  I've run '/sbin/shutdown -r now' from at before, with no adverse effects.
}  If you look in /etc/rc.d/rc.M you will find a line like:
}
}  /usr/sbin/crond -l10 >>/var/adm/cron 2>&1
}
}  This would indicate a logging level of 10 (check the source code) and
}  stdout & stderr are captured to a file called cron in /var/adm/
}
}
}  It sounds like something else is wrong.  Check which version of shutdown
}  you are running, it may have a bug.

I don't believe it's shutdown.  It works from the root prompt just fine.

}  check the version with 'strings /sbin/shutdown | head -1'

output is:
@(#) shutdown 1.4 14-05-1993 MvS

}  The version I'm running is 1.4 from 14-05-1993.
}  I'll schedule a cron job to re-boot my box tonight using the same command you
}  tried......
}  I'll get back to you tomarrow with the results.

It must be because cron is trying to log something at the same time, therefore
the filesystem doesn't get unmounted.  I appreciate you trying to duplicate
the problem.

}
}	-George
}
}


-- 
Opinions expressed by me are mine, all mine, only mine.....

Until later:
Geoffrey Myers   geof at denali.is.net   eiger at ichange.com   gamyers at attmail.com
	http://www.ticllc.net/~geof






More information about the Ale mailing list