Solaris 10 x86: Constructing a shared disk set between two hosts

Solaris 10 x86: Constructing a shared disk set between two hosts

Post by Dale Ghen » Wed, 13 Apr 2005 01:46:43



For grins, I'm trying to put together a poor man's failover setup using
a fiber channel array that two hosts can see. On the disk level, both
hosts can see the drives with no problem.

So I create a disk set on one host:


And then add disks to it:


c4t600039300001034A01000000D5BF8AEEd0 c4t600039300001057C01000000D5D0DB4Ad0

And it looks right:


Set name = afs-hfs10, Set number = 1

Host                Owner
   hfs10.afs            Yes

Drive                                            Dbase

/dev/dsk/c4t600039300001034A01000000D5BF8AEEd0   Yes

/dev/dsk/c4t600039300001057C01000000D5D0DB4Ad0   Yes

So then I try to add the second host to the disk set and get an error:


metaset: hfs11.afs: rpc.metad: Permission denied

rpc.metad is running on both hosts, and a truss and snoop of both don't
seem to indicate that one is trying to open or write to a file that the
process doesn't have permission to. Google and the Sun docs don't seem
to shed any detail on what may be causing this. Any thoughts?

/dale

 
 
 

Solaris 10 x86: Constructing a shared disk set between two hosts

Post by Dale Ghen » Wed, 13 Apr 2005 05:21:45



> You might be able to do failover where one disk is mounted RW on a
> system and the other is RO or unmounted.  On failover, the remaining
> system would mount the filesystem.

> But to truly share a disk as local on both systems requires using a
> filesystem that allows for this.  UFS does not.  The cluster filesystems
> are on SPARC only, I think, but I could be wrong.

My intention is to have the disks mounted in any fasion by one machine
at a given time. It's a basic active/passive setup. Active machine has
the disks mounted... passive machine monitors the active one. When the
heartbeat fails or user-initiated command is given, the passive machine
takes the disk set (or in the case of VXVM, imports the dg) and mounts
the drives/volumes... perhaps with a quick fsck beforehand. And yes,
logging UFS is fine for this type of application.

Anyway, I figured out the "Permission Denied" error... root had to be a
member of GID 14. Now I'm confronted with a different error on the same
command:


metaset: hfs11.afs: No such file or directory

/dale

 
 
 

Solaris 10 x86: Constructing a shared disk set between two hosts

Post by Dale Ghen » Wed, 13 Apr 2005 05:47:46



> Anyway, I figured out the "Permission Denied" error... root had to be a
> member of GID 14. Now I'm confronted with a different error on the same
> command:


> metaset: hfs11.afs: No such file or directory

Hmm, so I monitored the server I'm trying to add to the disk set, and
noticed that for a fleeting moment, a symlink with the name of the disk
set I'm adding that machine to appears in /dev/md:


total 26
drwxr-xr-x   2 root     root         512 Apr 11 16:43 .
drwxr-xr-x  17 root     sys         9728 Apr 11 12:07 ..
lrwxrwxrwx   1 root     root          31 Apr 11 11:23 admin ->

lrwxrwxrwx   1 root     other          8 Apr 11 16:43 afs-hfs10 -> shared/1

But obviously it's a symlink that's pointing to the non-existent and
apparently never-creates shared/1 directory. This is where I believe the
  "No such file or directory" error is coming from. So why wouldn't the
/dev/md/shared directory be created and added to?

/dale