On May 20 13:22:26, mikyde...@yahoo.fr wrote: > Hello, > > I have two use cases and problems with fsck. > > 1) When my openbsd boots after an outage, the system asks me to fsck /, /usr, > /var or /home manually. > So I do > fsck /dev/sd0a > And then I'm asked questions and I usually answer F > > So my question is that I want this process to be done automatically at boot > time for each partition that has a problem.
The /etc/rc boot script calls fsck -p; if that fails, it means fsck -p was unable to fix a major problem. It is the point that it requires an admin's intervention. You would have to change the fsck call to fsck -y; but don't do that. (Also, don't let a server have power outages, obviously.) > This is because I use a small server without screen and keyboard. So what? That is no excuse to leave broken filesystems unattended. > 2) I have another disk in my small server, and I mount one partition of it > with in fstab > aa929243b0f59999.a /var/mylogs ffs rw,nodev,nosuid 1 2 > When I remove that disk the boot sequence stops and asks for a fsck > I would like that this disk is mounted when it's present, but when it's not > installed I don't want the boot sequence to stop Make it also "noauto" in fstab and mount it in rc.local. (Also, don't remove disks from servers, obviously.)