[CentOS-docs] HowTo activate LVs after reboot automatically

Sun Nov 30 13:47:51 UTC 2008
Alain Reguera Delgado <al at ciget.cienfuegos.cu>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello !

What to do if after reboot, your LVs get inactive ?

Maybe add the following to /etc/rc.local :

{{{
#
# Mounting MyLogVols
#
/usr/sbin/vgchange -a y MyVolGroup

for i in `ls /dev/Backup/`; do

        e2fsck -p /dev/Backup/$i

        case $? in
                0)
                mount -t ext3 /dev/MyVolGroup/$i    /mnt/MyVolGroup/$i
                ;;
                1)
                mount -t ext3 /dev/MyVolGroup/$i    /mnt/MyVolGroup/$i
                ;;
                2)
                /usr/bin/reboot
                ;;
        esac

done
}}}

Other solutions ?

Could we document this issue on the wiki ?

Cheers,
- --
Alain Reguera Delgado <al at ciget.cienfuegos.cu>
GnuPG : http://ciget.cienfuegos.cu/~al/publickey.asc
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with CentOS - http://enigmail.mozdev.org

iD8DBQFJMpmHyXxCQEoXDZARArTGAKCjtR/Q/xPrhu0ycpXKJlqHJjCLAQCeMBug
TKdCSb/up0WJwInMT2TrLf4=
=i2V8
-----END PGP SIGNATURE-----