How to fsck between import and mounts
Created: 28 Nov 2012 | Updated: 04 Dec 2012 | 4 comments
This issue has been solved. See solution.
Is there a way to define that an fsck command needs to be run on each file system between the time the dg is imported and the file systems are actually mounted? In case we have an abnormal shutdown we'd like to make sure we check the file systems for errors.
Discussion Filed Under:
Comments 4 Comments • Jump to latest comment
The mount agent does an fsck if required - see extract from bundled agent guide for FsckOpt attribute:
BLOCK_DEVICE=$2 LOCKFILE=/tmp/.{$3}.DO_NOT_REMOVE case "$1" in start) touch $LOCKFILE fsck $BLOCK_DEVICE;; stop) rm $LOCKFILE ;; monitor) if [ -a $LOCKFILE ] then exit 110 else exit 100 fi ;; *) echo "Usage: $0 {start|stop|monitor} block_device lock_file exit 1 ;; esacThen create a resource using Application agent like:
and make this resource dependent on diskgroup resource and make associated mount point dependent on this application resource
Mike
UK Symantec Consultant in VCS, GCO, SF, VVR, VxAT on Solaris, AIX, HP-ux, Linux & Windows
If this post has helped you, please vote or mark as solution
Mike - now in see (in some doc provided by the consultant that set this all up) that fskcopt is defined:
hares -modify <resource_name> FsckOpt %-y
But I've never seen an fsck run when the resource was started. I know we've had some start ups after abnormal shutdowns and I would have expected to see some evidence of the fsck while the online process was running.
We do believe we have some file system corruption - which is why I ask.
Scott
I believe Fsck is only run if the mount fails and if Fsck is set to "n", then if mount fails, then agent does not try an fsck.
Mike
UK Symantec Consultant in VCS, GCO, SF, VVR, VxAT on Solaris, AIX, HP-ux, Linux & Windows
If this post has helped you, please vote or mark as solution
Thanks guys. I think we'll try to schedule some down time to run an fsck just to be sure.
Would you like to reply?
Login or Register to post your comment.