cancel
Showing results for 
Search instead for 
Did you mean: 

devices file name

SOLVED
Go to solution
Boris_31
Frequent Advisor

devices file name

Hi!
I have some problem.
i have DS25(Tru64 5.x) connecting to EVA 5000,
on EVA i make snapclon of this system and i need mount this snapclon on second DS25.
When EVA create snapclon and present to host, i do
hwmgr -scan scsi; and i can see /dev/disk/dskXXc COMPAQ HSV110 (C)COMPAQ bus-4-targ-0-lun-3.
All work ok, but i cant make script because on ever snapclon i have dskXX+1 device.
How i can do static name for disk device ?
9 REPLIES
Ivan Ferreira
Honored Contributor

Re: devices file name

When you create the snapclone, you can manually set the WWID. The information I got is that if you set always the same WWN, you will always see the same device name, because device names are associated to WWN.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Ivan Ferreira
Honored Contributor

Re: devices file name

In case that you cannot get always the same device ID, you can set the OS unit ID, and you will see the Unit ID with hwmgr, for example:

hwmgr v d

79: /dev/disk/dsk4c COMPAQ HSV110 (C)COMPAQ IDENTIFIER=2202

use

hwmgr v d |grep "IDENTIFIER=2202" |awk '{print $2}'

Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Johan Brusche
Honored Contributor

Re: devices file name


Since dskXX was created at previous snapclone and does not exist anymore and not in use. You can use hwmgr to delete it and then use
dsfmgr -m dskXX+1 dskXX
or, if you do not delete it with hwmgr, you can use:
dsfmgr -e dskXX+1 dskXX

So you can reuse dskXX in your scripts.

Rgds,
Johan.

_JB_
Boris_31
Frequent Advisor

Re: devices file name

What is happend if i reboot system?
This device name change to dskXX+1 or no?
Can i reset this count to dsk1c w/o dsfmgr?
Johan Brusche
Honored Contributor

Re: devices file name


Boris,

The snapclone contains pointers to the original boot dsk-name in /etc/sysconfigtab "swapdevice" and in /etc/fdmns/* domain links. These should be modified to point to dskXX.

Johan.

_JB_
Ivan Ferreira
Honored Contributor

Re: devices file name

Even if you remove the unused device with hwmgr, unless the device had the same WWN, will be detected as dskx+1. Once detected the device name is persistent across reboots.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Boris_31
Frequent Advisor

Re: devices file name

How can i add device manually w/o hwmgr -scan scsi ?
Can i disable automatic discovery disk devices on reboot?
Johan Brusche
Honored Contributor
Solution

Re: devices file name

Boris,

You cannot disable autodiscovery of new units at boot-time, nor should you add dsk's manually with mknod or MAKEDEV on V5.1x

But, please read the dsfmgr manpage... in particular the purpose of the "-I" switch, it brings the device instance number back to the lowest possible number.
This feature has been introduced to V5.1B with patchkit#1 and in V5.1A with patchkit#5 and was in high demand by customer just for those sites that use snap/clone regulary.

Rgds,
Johan.

_JB_
Boris_31
Frequent Advisor

Re: devices file name

Tnx, dsfmgr -v -I , reset device ID
But now i can't reset HWID on hwmgr :-)
my script:

hwmgr -delete -did 4
sleep 5
dsfmgr -v -I
sleep 3
hwmgr -scan scsi
sleep 3
mount -t advfs eva_domain#my_fs /clone