[Linux-cluster] lv and its snapshot can be mounted at the same time in one node?

Rocty Wang rocty at 21cn.com
Thu Oct 21 09:59:45 UTC 2004


Hi, all

       As we know, snapshot of lv(logical volume) is the important
technology implementation of data "backup" 

and "recovery". And now I use lvm2's snapshot(also should insmod the
dm-snapshot module in kernel) as 

the result to deal with data.

       But when I tested XFS or ext3 file system in the standalone LVM2
under Linux, found that if you want to use the snapshot

data, you must umount the original lv firstly and mount the snapshot volume
to finish that.

 

     Due to the cluster project, I use GFS as our storage solution, but when
I do the following operations, it seems

that the lv and its snapshot can't be mounted at the same time? 

 

Is that any method to mount lv and its snapshot at the same time? Use
lock_gulm?

Or if any file system can support this feature?

 

Any help will be appreciated.

 

*****operations:

OS: Linux FC2 (kernel upgraded to 2.6.8.1)

Linux Cluster project: (DEVEL.1098174560 (built Oct 19 2004 16:30:29))

GFS: DEVEL.1098174560 (built Oct 19 2004 16:30:43)

LVM2 version:     2.00.26-cvs (2004-09-29)

dm Library version: 1.00.20-ioctl-cvs (2004-07-03)

Driver version:  4.1.0

 

***I have create a vg as named "vg2" firstly

 

# lvcreate -L 8G -n test2 vg2

  Logical volume "test2" created

# lvcreate -s -L 2G -n snap2 /dev/vg2/test2

  Logical volume "snap2" created

 

# gfs_mkfs -p lock_dlm -t cluster1:myfs -j 2 /dev/vg2/test2

This will destroy any data on /dev/vg2/test2.

Are you sure you want to proceed? [y/n] y

Device:                    /dev/vg2/test2

Blocksize:                 4096

Filesystem Size:           2031440

Journals:                  2

Resource Groups:           32

Locking Protocol:          lock_dlm

Lock Table:                cluster1:myfs

 

Syncing...

All Done

 

# mount -t gfs /dev/vg2/test2 /home/test2

GFS: fsid=cluster1:myfs.0: Joined cluster. Now mounting FS...

GFS: fsid=cluster1:myfs.0: jid=0: Trying to acquire journal lock...

GFS: fsid=cluster1:myfs.0: jid=0: Looking at journal...

GFS: fsid=cluster1:myfs.0: jid=0: Done

GFS: fsid=cluster1:myfs.0: jid=1: Trying to acquire journal lock...

GFS: fsid=cluster1:myfs.0: jid=1: Looking at journal...

GFS: fsid=cluster1:myfs.0: jid=1: Done

 

# mount -t gfs /dev/vg2/snap2 /home/snap2

FAT: bogus number of reserved sectors

VFS: Can't find a valid FAT filesystem on dev dm-3.

GFS: not a GFS filesystem

mount: wrong fs type, bad option, bad superblock on /dev/vg2/snap2,

       or too many mounted file systems

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/linux-cluster/attachments/20041021/4b2462e9/attachment.htm>


More information about the Linux-cluster mailing list