Operating System - HP-UX
1834201 Members
2427 Online
110066 Solutions
New Discussion

Re: ioscan & insf command question

 
Vinay Narayana
New Member

ioscan & insf command question

I have a HP 11i host to which I allocate new devices quite regularly. So each time I allocate the devices I run `ioscan -fnC disk` command and the newly allocated device becomes visible to the host. But sometimes I have to issue `insf -e -C disk` for the host to recognize the new devices. I dont know why this happens.

I want to know 2 things:
1. Why doesn't HP need the insf command all the times?
2. Is issuing the above insf command in a multi-user mode recommended? I always issue the command in a multi-user mode and Iam yet to see any problem with that.

Thanks
Vinay
6 REPLIES 6
SS_6
Valued Contributor

Re: ioscan & insf command question

ioscan is to scan hardware and insf is to create device files. There is no harm to run this in multiuser mode. I have used this command so many times as we have to allocate disks from XP time to time. Do man on both commands for more informatioin.
By providing solutions I am helping myself
Sundar_7
Honored Contributor

Re: ioscan & insf command question

I have never seen my device files automatically created after ioscan - HP-UX always would require insf unless u had a reboot of the system.

1. As far as I know, HP-UX requires ioscan followed by a insf to recognize new devices

2. Issuing insf in mutiuser mode is absolutely fine. It does nothing destructive.
Learn What to do ,How to do and more importantly When to do ?
Jeff Schussele
Honored Contributor

Re: ioscan & insf command question

Hi Vinay,

To answer your questions:

1) IF the device already exists then you won't need the insf command. For instance /dev/dsk/c12t6d4 *was* in use months ago & then was no longer there AND you hadn't used rmsf to remove it. Then if a new LUN is presented & it's c12t6d4 then you wouldn't have to insf the new device into existence.

2) Yes - it's allowed. But you really don't need any parameters on insf - the command alone will create the newly discovered devices.

HTH,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
SS_6
Valued Contributor

Re: ioscan & insf command question

sometimes if old device file is present but not the physical, it will be used by new device. using -C (particular device class) is always useful and it only look for those devices.
By providing solutions I am helping myself
Vinay Narayana
New Member

Re: ioscan & insf command question

Thanks All for your replies.

The reason I was concerned about issuing the insf command is because the man page for insf states the below:

"WARNINGS insf should only be run in single-user mode. It can change the mode, owner, or group of an existing special file, or unlink and recreate one; special files that are currently open may be left in an indeterminate state.
Many commands and subsystems assume their device files are in /dev, therefore the use of the -D option is discouraged."

So do you all think I can safely disregard this message.
SS_6
Valued Contributor

Re: ioscan & insf command question

Vinay, I understand what you are after. No, we never ignore any vendor,s warnings but practically as I told my experience I have done it many times and no issues and I also I think it is not easy to bring production servers down every time just to allocate disks.
By providing solutions I am helping myself