FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora Development

 
 
LinkBack Thread Tools
 
Old 11-03-2008, 06:24 PM
Harry Hoffman
 
Default iscsi lvm and /dev and bootup

Hi,

I'm stuck here...

I've got iscsi running here with two drives on a lefthand networks iscsi
box.

I'm able to successfully login and can see the targets.

I'm using lvm to create physical volumes:
pvcreate external_iscsi /dev/sdb /dev/sdc


I then create a logical volume:
lvcreate -l 1310718 external_iscsi -n srv

and finally create a filesystem:
mkfs.ext3 -m 1 /dev/external_iscsi/srv

All of this works well and I can mount the filesystem just fine.

When I reboot it all goes to hell. I see iscsi logging into the lefthand
box and it reports success.

and if I run vgdisplay I get:
vgdisplay external_iscsi
--- Volume group ---
VG Name external_iscsi
System ID
Format lvm2
Metadata Areas 2
Metadata Sequence No 2
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 1
Open LV 0
Max PV 0
Cur PV 2
Act PV 2
VG Size 5.00 TB
PE Size 4.00 MB
Total PE 1310718
Alloc PE / Size 1310718 / 5.00 TB
Free PE / Size 0 / 0
VG UUID vLGcVU-cAj0-Z7Ox-EcYF-bx5e-fMWs-9wGh3t


however, there's no /dev/ entry for /dev/external_iscsi

Can someone tell me what I'm missing?

Cheers,
Harry



--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 11-04-2008, 01:41 AM
Jim Wildman
 
Default iscsi lvm and /dev and bootup

On Mon, 3 Nov 2008, Harry Hoffman wrote:


I'm using lvm to create physical volumes:
pvcreate external_iscsi /dev/sdb /dev/sdc


You need to use the /dev/mapper entries since the /dev/sd? are not
guaranteed to be permanent across reboots (which device is the first
one??)

----------------------------------------------------------------------
Jim Wildman, CISSP, RHCE jim@rossberry.com http://www.rossberry.com
"Society in every state is a blessing, but Government, even in its best
state, is a necessary evil; in its worst state, an intolerable one."
Thomas Paine

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 11-04-2008, 09:10 AM
"Bryn M. Reeves"
 
Default iscsi lvm and /dev and bootup

Harry Hoffman wrote:

All of this works well and I can mount the filesystem just fine.

When I reboot it all goes to hell. I see iscsi logging into the lefthand
box and it reports success.

and if I run vgdisplay I get:
vgdisplay external_iscsi
--- Volume group ---
VG Name external_iscsi
System ID

[snip]


however, there's no /dev/ entry for /dev/external_iscsi


Sounds like your VG has not been activated by your distribution's init
sripts. Run "vgchange -ay external_iscsi" and the VG should be activated
and made accessible, creating the entries in /dev. There's no need to
use the /dev/mapper/$vg-$lv entries - for LVM2 devices, the /dev/$vg/$lv
symlinks are guaranteed to be persistent.

What distro are you using here? Some perform a vgchange -ay from the
iscsi initialisation script (Fedora and RHEL both do this). If that's
not the case for your distribution then you might need to either add the
command to the script yourself, or make sure that if the distribution
provides an "lvm" initscript, that it's set to start later than the
iscsi script.

Assuming this is Fedora, it might be that it's taking a long time for
the login to the storage to complete, and we're "missing" the VG when
the vgchange in the iscsi script runs - I don't see a call to udevsettle
in the script which would sync up with the new device discovery.


Regards,
Bryn.


--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 
Old 11-04-2008, 12:44 PM
"Bryn M. Reeves"
 
Default iscsi lvm and /dev and bootup

Bryn M. Reeves wrote:

Sounds like your VG has not been activated by your distribution's init
sripts. Run "vgchange -ay external_iscsi" and the VG should be activated
and made accessible, creating the entries in /dev. There's no need to
use the /dev/mapper/$vg-$lv entries - for LVM2 devices, the /dev/$vg/$lv
symlinks are guaranteed to be persistent.

What distro are you using here? Some perform a vgchange -ay from the
iscsi initialisation script (Fedora and RHEL both do this). If that's


Actually, I'm wrong - for Fedora/RHEL/CentOS the vgchange is done from
the netfs script rather than directly from the iscsi script, but only in
the case that at least one entry in /etc/fstab or /etc/mtab has the
"_netdev" option present.


RHEL/CentOS up to 5.2 have a bug in this script that may cause devices
to be misssed due to not syncing up with udev - see:


https://bugzilla.redhat.com/show_bug.cgi?id=452866

Looking on my f9 boxes, this bug still appears to be present in Fedora,
will clone the BZ for rawhide if it's still there too.


Regards,
Bryn.

--
fedora-devel-list mailing list
fedora-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-list
 

Thread Tools




All times are GMT. The time now is 03:54 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org