1834640 Members
3314 Online
110069 Solutions
New Discussion

share filesystem lv

 
steven pan
Occasional Advisor

share filesystem lv

how can i create a share filesystem, what lv parameters will be set?
now , i have created a filesystem , it can be mounted on both nodes, but when i create a directory on one node , this directory can't be seen by other node.

what's the matter?
StevenPan
4 REPLIES 4
Michael Steele_2
Honored Contributor

Re: share filesystem lv

First, let me verify that you have a ServiceGuard environment.

Second, you need the vgimport and vgexport commands within ServiceGuard to complete the LVM procedure, only.

Third, you need to update your package.cntl file on both nodes to complete the procedure.

To answer your question, the vgexport and vgimport "...-s..." parameter is for shared file systems. Review this link:

http://docs.hp.com/cgi-bin/fsearch/framedisplay?top=/hpux/onlinedocs/B2355-90692/B2355-90692_top.html&con=/hpux/onlinedocs/B2355-90692/00/02/215-con.html&toc=/hpux/onlinedocs/B2355-90692/00/02/215-toc.html&searchterms=vgexport&queryid=20030316-052807

Here is the LVM procedure:

1a) Create a new map file of the vg## with the file system and lv:

1b) vgexport -p -s -m /tmp/map /dev/vg## (* NOTE: -p preview *)

1c) vgexport -s -m /tmp/map /dev/vg## (* When ready to commit *)

1d ) ftp 2nd node
put /tmp/map

2a) vgexport /dev/vg## (* Remove the vg from the first node. *)

2b) mkdir /dev/vg##

2c) mknod /dev/vg##/group c 64 0x#0000

2d) vgimport -p -s -m /tmp/map /dev/vg## (* preview *)

2e) vgimport -s -m /tmp/map /dev/vg## (* When ready to commit *)

Here is the package.cntl file update procedure starting with the first node:

1a) vi package.cntl

1b) Locate the vg## and add the lv and fs. For example:

VG[0] vg01
LV[0] /dev/vg01/lvol1
FS[0] /ora1

...etc.

1c) save package.cntl

1d) cmcheckconf -P package.conf

1e) cmapplyconf -P package.conf

1f) vgchange -c y /dev/vg##

1g) vgchange -a n /dev/vg## (* deactivate and unmount *)

1h ) cmmodpkg -e package (* The package will activate and mount the vg's and lv's and fs's *)

For the second node, copy the new package.cntl over and test with a fail over.
Support Fatherhood - Stop Family Law
Printaporn_1
Esteemed Contributor

Re: share filesystem lv

Hi,
From my understanding for shared file system.
at any given time the file system will only mount at a node not both.
if you want those feature , better use nfs.

HTH
enjoy any little thing in my life
A. Clay Stephenson
Acclaimed Contributor

Re: share filesystem lv

DON'T DO THIS. The only way a filesystem can be mounted on more than one host is read-only on all hosts. The systems will blindly allow you to mount the filesystems but absolute chaos is assurred. The problem is that hostB has no idea what is going on in hostA's buffer cache and vice-versa. You can mount the filesystemread-write on one host and then export via NFS and then safely nfs mount it read-write on any number of hosts.
If it ain't broke, I can fix that.
steven pan
Occasional Advisor

Re: share filesystem lv

thanks for all
i think i see how to deal with it.
StevenPan