Operating System - HP-UX
1829456 Members
2287 Online
109992 Solutions
New Discussion

Adding new disk to hpux 10.20

 
SOLVED
Go to solution
Julian Sinclair
Advisor

Adding new disk to hpux 10.20

I am new to hpux but have spent some time administering solaris systems so take it easy on me.

I have a new external disk that I want to add to the back of a hp visualize that we have here.

In solaris i would add the disk to the back and do a boot -r from the ok prompt. This would reconfigure /dev and /devices and all i would need to do then is format it and mkfs.

What is the equivalent process in hp-ux ?

I have tried searching the itrc for this but they have returned nothing of use that I can find. Any help appreciated.
If it ain't broke don't fix it
4 REPLIES 4
Victor BERRIDGE
Honored Contributor

Re: Adding new disk to hpux 10.20

The same, after reboot you would type ioscan -fnC disk to see its there (with the others) then add the disk to a volume group or create a new and use it by creating new lvms or by extending existing...

Use SAM for you will not have to know all the commands for the beginning...

Good luck

Victor
Rainer_1
Honored Contributor

Re: Adding new disk to hpux 10.20

in HP-UX new disks are recognized automatically after reboot.
Shut down the system, connect the disk and start up.
Make sure that the new disk has an unique SCSI-ID.
After reboot new device entries can be found at /dev/dsk/c#t#d0 and /dev/rdsk/c#t#do (raw device).
If you don't want to use LVM you could make a filesysteme with

newfs -F vxfs /dev/rdsk/c#t#d0

and mount it ie:

mkdir /mnt
mount /dev/dsk/c#t#d0 /mnt

To make it permanent edit /etc/fstab ie:

/dev/dsk/c#t#d0 /mnt vxfs rw,suid,delaylog,datainlog 0 2

If you want to use LVM you could add the disk with SAM into a (new) volume group and create log. volumes.
Julian Sinclair
Advisor

Re: Adding new disk to hpux 10.20

Thnakyou for the quick answers. The fact the disks are automatically recognised probably explains why I couldn't find anything about it on itrc.
If it ain't broke don't fix it
Trevor Dyson
Trusted Contributor
Solution

Re: Adding new disk to hpux 10.20

Hi Julian,

Assuming that you have the correct SCSI termination and the disk is the correct type for the type of SCSI bus it is connected to (single-ended versus fast/wide) then do the following:

To check to see if the disk can be seen by the workstation then power up the workstation and interupt the boot sequence by hitting any key within 10 seconds when prompted to do so (some times the monitors on these take a while to power up and you may miss the 10 second message - just keep hitting the escape key till you see something like a boot-admin> prompt)

When you get the boot admin prompt then type in the word 'search' and hit enter. This should list all scsi devices. If you don't see your new disk then re-check your SCSI termination and correct bus connection and try again. Alos check you are not using a SCSI address that is already in use.

Once you see the disk then you can proceed to do a full boot, easiest way is to just hit the power on the workstation and let the boot go through.

When HP-UX boots up it will autocreate the device files for your disk, block device will be created under /dev/dsk and raw under /dev/rdsk.

You can confirm that HP-UX has done this by doing:

ioscan -funC disk

You should see a list of disks and their associated device file names, including your new disk.

You have a number of options available to create a filesystem:

LVM partitioning or Whole of disk approach
HFS or JFS filesystem.

It may help for you to give us an idea of what you want to use the disk for.

Anyway, here is how I would use the whole disk for a JFS filesystem using LVM with a logical volume in vg00:

pvcreate -f /dev/rdsk/c?t?d?

(You need to replace the question marks with the correct numbers as shown by the ioscan output as mentioned above.)

vgextend /dev/vg00 /dev/dsk/c?t?d?

lvcreate -L (mbytes) -n lvname /dev/vg00 /dev/dsk/c?t?d?

(Replace (mbytes) with the size of the disk, replace lvname with a useful name)

Create a filesystem:

newfs -F vxfs /dev/vg00/rlvname

Create a mount point directory with mkdir:

mkdir /mountpoint

Mount it:

mount /dev/vg00/lvname /mountpoint

Then update /etc/fstab to mount this filesystem each time you boot.

If you are unsure about using these commands then you can use sam to make things easier. Just type sam at the prompt, selct Disks and Filesystems and follow your nose from there. Once sam has finished then view /var/sam/log/samlog to see what commands were used.

Regards, trevor

I've got a little black book with me poems in