LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-06-2005, 06:09 PM   #1
jbanafato
Newbie
 
Registered: Mar 2002
Posts: 28

Rep: Reputation: 15
LVM2 (non-root) lv's won't mount at boot time


Hey everyone...

I've got LVM2 set up and working. My only problem is that the volumes will not activate at boot time. I have a 20GB volume named homevol (/dev/vg0/homevol). When I manually do 'lvchange -ay /dev/vg0/homevol' all is well.

I though simply adding the appropriate vgchange and lvchange commands to /etc/rc would activate everything at boot time, but no luck. I will make an initrd if I must, but I don't see why I would have to. Anybody have a similar experience?

Applicable info:
linux 2.6.6
devfs (daemon and kernel protocol rev 5), mounts at boot
lvm 2.00.33

Thanks...
 
Old 03-06-2005, 10:09 PM   #2
nonzero
Member
 
Registered: Feb 2005
Distribution: Debian FC4 LFS Slackware
Posts: 174

Rep: Reputation: 31
My /etc/fstab, give you any ideas?

[nonzero@blacky ~]$ cat /etc/fstab
LABEL=/1 / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
/dev/VolGroup00/LogVol01 /home ext3 defaults 1 2
/dev/VolGroup01/LogVol01 /opt ext3 defaults 1 2
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
/dev/VolGroup01/LogVol00 /usr ext3 defaults 1 2
/dev/VolGroup00/LogVol00 /var ext3 defaults 1 2
LABEL=SWAP-ida/c0d0p2 swap swap defaults 0 0
/dev/hda /media/cdrom auto pamconsole,exec,noauto,managed 0 0
/dev/fd0 /media/floppy auto pamconsole,exec,noauto,managed 0 0

nz

EDIT: This machine is running FC3.

Last edited by nonzero; 03-06-2005 at 10:10 PM.
 
Old 03-07-2005, 12:04 AM   #3
jbanafato
Newbie
 
Registered: Mar 2002
Posts: 28

Original Poster
Rep: Reputation: 15
Thanks for the reply. My fstab is good. For instance, I have the following entry:

/dev/vg0/homevol /home reiserfs defaults 0 0

If I were to log in after a reboot, however, /home won't be mounted. So,

#mount /home
mount: special device /dev/vg0/homevol does not exist

Wow, that's weird...

#lvdisplay
LV Name /dev/vg0/homevol
VG Name vg0
LV Write Access read/write
LV Status NOT available
...

There's the culprit. homevol's not active.

#lvchange -ay /dev/vg0/homevol
#mount /home

Homes are back.

But when I put the vgchange and lvchange commands in my rc scripts, they just don't seem to do anything. No logs, nothing. I'm running out of ideas. Maybe you could grep -R "\(lv\|vg\)change" /etc/* for me?

Thanks again...
 
Old 03-07-2005, 12:29 AM   #4
nonzero
Member
 
Registered: Feb 2005
Distribution: Debian FC4 LFS Slackware
Posts: 174

Rep: Reputation: 31
Here ya go.

[root@blacky nonzero]# grep -R "\(lv\|vg\)change" /etc/*
grep: /etc/httpd/run/dbus/system_bus_socket: No such device or address
grep: /etc/rc0.d/K90bluetooth: No such file or directory
grep: /etc/rc0.d/K74apmd: No such file or directory
grep: /etc/rc1.d/K90bluetooth: No such file or directory
grep: /etc/rc1.d/K74apmd: No such file or directory
grep: /etc/rc2.d/K90bluetooth: No such file or directory
grep: /etc/rc2.d/S26apmd: No such file or directory
grep: /etc/rc3.d/K90bluetooth: No such file or directory
grep: /etc/rc3.d/S26apmd: No such file or directory
grep: /etc/rc4.d/K90bluetooth: No such file or directory
grep: /etc/rc4.d/S26apmd: No such file or directory
grep: /etc/rc5.d/K90bluetooth: No such file or directory
grep: /etc/rc5.d/S26apmd: No such file or directory
grep: /etc/rc6.d/K90bluetooth: No such file or directory
grep: /etc/rc6.d/K74apmd: No such file or directory
grep: /etc/rc.d/rc6.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc6.d/K74apmd: No such file or directory
grep: /etc/rc.d/rc1.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc1.d/K74apmd: No such file or directory
grep: /etc/rc.d/rc3.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc3.d/S26apmd: No such file or directory
grep: /etc/rc.d/rc5.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc5.d/S26apmd: No such file or directory
/etc/rc.d/rc.sysinit: action $"Setting up Logical Volume Management:" /sbi n/lvm.static vgchange -a y --ignorelockingfailure
/etc/rc.d/rc.sysinit: if [ -e /proc/lvm -a -x /sbin/vgchange ]; then
/etc/rc.d/rc.sysinit: action $"Setting up Logical Volume Management:" /sbin/vg scan && /sbin/vgchange -a y
/etc/rc.d/rc.sysinit: action $"Setting up Logical Volume Manag ement:" /sbin/lvm.static vgscan --mknodes --ignorelockingfailure && /sbin/lvm.st atic vgchange -a y --ignorelockingfailure
/etc/rc.d/rc.sysinit: if [ -e /proc/lvm -a -x /sbin/vgchange -a -f /etc/lvmtab ]; then
/etc/rc.d/rc.sysinit: action $"Setting up Logical Volume Management:" /sbin/vgscan && /sbin/vgchange -a y
grep: /etc/rc.d/rc2.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc2.d/S26apmd: No such file or directory
grep: /etc/rc.d/rc0.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc0.d/K74apmd: No such file or directory
grep: /etc/rc.d/rc4.d/K90bluetooth: No such file or directory
grep: /etc/rc.d/rc4.d/S26apmd: No such file or directory
/etc/rc.sysinit: action $"Setting up Logical Volume Management:" /sbi n/lvm.static vgchange -a y --ignorelockingfailure
/etc/rc.sysinit: if [ -e /proc/lvm -a -x /sbin/vgchange ]; then
/etc/rc.sysinit: action $"Setting up Logical Volume Management:" /sbin/vg scan && /sbin/vgchange -a y
/etc/rc.sysinit: action $"Setting up Logical Volume Manag ement:" /sbin/lvm.static vgscan --mknodes --ignorelockingfailure && /sbin/lvm.st atic vgchange -a y --ignorelockingfailure
/etc/rc.sysinit: if [ -e /proc/lvm -a -x /sbin/vgchange -a -f /etc/lvmtab ]; then
/etc/rc.sysinit: action $"Setting up Logical Volume Management:" /sbin/vgscan && /sbin/vgchange -a y

nz
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to mount WinXP drive at boot-time? voly Linux - General 10 07-16-2005 08:13 AM
suse 9.3 and root on lvm2 sam_vde SUSE / openSUSE 0 07-14-2005 07:24 AM
LVM2 on Sarge - HD failure in the volume group container /root Golovko Debian 3 06-20-2005 10:54 PM
RAID drives won't mount at boot time dsp444 Slackware 5 01-23-2005 01:43 AM
After reboot LVM2 partitions will not mount sendas4 Linux - General 0 10-12-2004 05:35 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration