Operating System - Tru64 Unix
1748169 Members
4275 Online
108758 Solutions
New Discussion юеВ

Using dsfmgr to add a device file

 
SOLVED
Go to solution
Matt Hearn
Regular Advisor

Using dsfmgr to add a device file

Hey all, at some point in the last few months we had a SCSI-attached TL891 DLX DLT tape library on our GS60E go bad on us. We thought it was just a tape drive, but no; we replaced it, but then we were getting "changer not responding" messages when we tried to issue "robot" commands. So we rebooted, but that had no effect. Finally, we replaced the entire library, but that caused problems too; we still couldn't use the robot command, and also our tape drives were in the wrong place, and we were seeing too many of everything in hwmgr:

SCSI DEVICE DEVICE DRIVER NUM DEVICE FIRST
HWID: DEVICEID HOSTNAME TYPE SUBTYPE OWNER PATH FILE VALID PATH
-------------------------------------------------------------------------
71: 13 pdsdev changer none 0 1 (null)
72: 14 pdsdev tape none 0 1 (null)
73: 15 pdsdev tape none 0 1 (null)
74: 16 pdsdev tape none 0 1 tape2 [3/5/0]
89: 19 pdsdev tape none 0 1 (null)
92: 20 pdsdev tape none 0 1 tape4 [1/5/0]
93: 21 pdsdev changer none 0 2 (null) [1/0/0]
94: 22 pdsdev tape none 0 1 tape5 [1/4/0]

tape2, btw, is a standalone SDLT. I was able to use hwmgr -delete component -id on the extras, and then I did the dsfmgr -m to move the tape drives to the right device files, and mt commands on those respond fine. However, the device file /dev/changer/mc0 (that the robot points to by default) is now gone, and I'm left with a changer with no device file:

SCSI DEVICE DEVICE DRIVER NUM DEVICE FIRST
HWID: DEVICEID HOSTNAME TYPE SUBTYPE OWNER PATH FILE VALID PATH
-------------------------------------------------------------------------
93: 21 pdsdev changer none 0 2 (null) [1/0/0]

A little digging leads me to believe I can use dsfmgr -a to add a device file for it, but I'll be darned if I can figure out what the options are. Here are the two sets of options for dsfmgr -a, according to the manpage:

dsfmgr [-QSxV] -a class dir_name [entry_type [mode]]

dsfmgr [-QSxV] -a category s_1 s_2 s_3 dev_dir flags node_type mode pre-fix

I'm guessing that the "category" method is what I need, but I have no idea what the s_[123], flags, node_type, mode, and pre-fix are.

Oh, how I wish HP would let us choose a font that would align all those tables properly, but oh well.

Thanks!
2 REPLIES 2
Rob Leadbeater
Honored Contributor
Solution

Re: Using dsfmgr to add a device file

Hi Matt,

Been in your shoes before !

What you'll need to do, is go through the the output of "hwmgr view device", or "hwmgr show scsi" and delete all of the old null devices.

Note that this is a two stage process. For example:

# dsfmgr -R hwid 93
# hwmgr delete component -id 93

Note that the man page for dsfmgr is wrong - it has these two commands the other way round.

You could also (if you want) remove any active tape and mc devices. Once everything is cleaned up scan the SCSI bus.

# hwmgr scan scsi

You should then (hopefully!) see new tape and mc devices.

Finally move them back to the devices you're expecting with (something like):

# dsfmgr -m mcX mc0
# dsfmgr -m tapeY tape0

You might also need to to run

# dsfmgr -F -v

to verify and fix the device naming.

Hope this helps,

Regards,

Rob
Matt Hearn
Regular Advisor

Re: Using dsfmgr to add a device file

You are a gentleman and a scholar! That did the job perfectly. If I could figure out some way of allocating 50 points to that response, I would. THANK YOU!