Operating System - HP-UX
1833290 Members
2766 Online
110051 Solutions
New Discussion

removing of Tape from system

 
Milan Sykora
Occasional Advisor

removing of Tape from system

Please Help me,

how can I remove Tape device from HP Ux 11?

I have now 3 tapes - Instance 6, 7 and 8 in the system and I would like to have Instance 0, 1 and 2 what have I to do?
9 REPLIES 9
Pete Randall
Outstanding Contributor

Re: removing of Tape from system

Milan,

You can create new device files of your own choosing. I'm attaching the procedure I've used in the past.


Pete

Pete
Milan Sykora
Occasional Advisor

Re: removing of Tape from system

Thank you Pete,

this is from man mksf:

The mksf command makes a special file in the devices directory,
normally /dev, for an existing device, a device that has already been
assigned an instance number by the system.

but I have not assigned Instance numbers 0,1 and 2.

If I tried it - was this message:
mksf: Couldn't find driver matching arguments

Milan
Pete Randall
Outstanding Contributor

Re: removing of Tape from system

Milan,

I guess I mis-understood your question, then. Why would you be concerned about what the instance numbers are?


Pete

Pete
A. Clay Stephenson
Acclaimed Contributor

Re: removing of Tape from system

If this is important to you then the fix is rather simple.

cd /dev/rmt
ls -l 6m* 7m* 8m* | lp

Note the major and minor device numbers for 6m,6mb,6mn, and 6mnb (and the 7x and 8x nodes as well).

Now remove 6m*, 7m*, and 8m* using rm.

Finally recreate the device nodes using the desired major/minor device numver tuples.

Let's say that 6m was 205 0x020000
rm 6m
mknod 0m c 205 0x020000

You have now changed 6m to 0m. The box only cares about the major/minor device number; us dumb humans use the names.
If it ain't broke, I can fix that.
Milan Sykora
Occasional Advisor

Re: removing of Tape from system

Sorry Pete,

O.K.

I have in my system (if I use ioscan) only 3 tapes. And they have numbers 6, 7 and 8. And my question is WHY? I think, that there were in the past tapes 0....5 , but they were removed from system, but the system remembered their Instance numbers and for the new tapes assined the folowing
Instance numbers.
And I would like to have now the numbers from Tape 0 again.

Milan
Pete Randall
Outstanding Contributor

Re: removing of Tape from system

Milan,

If you really want to change the instance numbers, you could try using rmsf to remove all the device files associated with your tape drives, old and new, then reboot. I don't know if that will change the instance numbers or not, but it might be worth a try.


Pete

Pete
Milan Sykora
Occasional Advisor

Re: removing of Tape from system

Pete,

yes it was done. But without success.

I removed all special files from all tapes
(rmsf). I disconnected all tapes , I rebooted system (in ioscan were not any tapes) than I connected the tapes and If I made ioscan the Instance numbers were higher.

Milan
Pete Randall
Outstanding Contributor

Re: removing of Tape from system

Sorry, Milan. Something is nagging the back of my mind about changing instance numbers but I can't for the life of me recall what it was. Maybe someone else can come up with something.


Pete

Pete
Milan Sykora
Occasional Advisor

Re: removing of Tape from system

IÅ¥s O.K. Pete

Thank you

Mil