This is a certainly harder than just accepting the default monolithic disk partition from the factory, or even the default "user disk" paritions (/, and /usr) which fx gives you. Unfortunately, it seems the only way of establishing a non-default partition configuration.
Function MB Type Unit Notes / 25 efs 0 swap 160 raw 1 (64MB RAM) * 2.5 /usr 500 efs 6 all vendor SW /var (tmp) 125 efs 7 includes tmp /share ~1300 efs 5 HOG: NFS export for local, people, etcThese numbers may not match those in the sample fx log, nor will the be right for you -- chose values appropriate to your site.
As described earlier, you can use fx to create a "user disk" which has a /, /usr and swap partitions. After selecting those defaults, leaving space of course for new partions of course, create the other partitions you want, eg: space for /var and /share.
[want some example here, or a link into the earlier example
The disk needs to be repartitioned using fx, which you can run multiuser -- until you label the disk. After approximating the proper number of MB/cylinder and a little trial-and-error, we were able to get what we wanted. The documentation is a bit weak on this procedure, so you can look at a log of the fx session. Make sure you label and sync the disk before you exit fx.
At this point the system will start complaining because it's concept of the partitions just got hosed. You need to boot from CDROM but before you can load the miniroot onto disk, you'll have to make filesystems in the new partitions.
First shutdown and reboot from the CDROM; the reboot will fail since the disk partition info is no longer accurate for the current filesystems. In Irix 5.3, select the Install Software option from the menu; and answer YES to makefs the / (root) and /usr filesystems. This will give it some place to install the software.
First create UNIX devices which access the disk partitions you created earlier with fx, then make UNIX filesystems on them so files can be installed there. This is done with the mknod command to make devices, and mkfs to make filesystems. Be careful to associate the right device major and minor nodes, and device type (c or b) with the proper partition. Check existing entries in /dev for / and /usr for their device numbers, and compare those with the devices in /dev/dsk and /dev/rdsk. Then you will be able to determine the appropriate device nodes, SCSI disk/file names, and UNIX device names for the partitions you will be mknod-ing and mkfs-ing.
# cd /dev/rdsk # mknod dks0d1s5 c 128 21 # chmod go-rw dks0d1s1 # cd /dev/dsk # mknod dks0d1s5 b 128 21 # chmod go-rw dks0d1s1 # cd /dev # mknod share b 128 21 # chmod go-rw share # mknod rshare c 128 21 # chmod go-rw rshareNo create a file system on it:
# cd /dev # mkfs rshareNow create a mount point:
# mkdir /shareand put an entry in /etc/fstab for the new /share partition:
/dev/share /share efs rw,raw=/dev/rshare 0 0[?? Need to document the ``0 0'' fields for fsck and dump]
Now mount it:
# mount /share
Again, these parition names and node numbers may not be right for your system; compare with your fx information.
First, make the devices:
# cd /dev/rdsk # mknod dks0d1s7 # chmod go-rw dks0d1s7 # cd /dev/dsk # mknod dks0d1s7 # chmod go-rw dks0d1s7 # cd /dev # mknod var b 128 23 # chmod go-rw var # mknod rvar c 128 23 # chmod go-rw rvarAnd make the filesystem on it:
# cd /dev # mkfs rvarBefore you mount it, you must move the old /var files out of the way so we can create the mount point. This is best done on a quiescent system so that mail and log files and such don't get lost -- best to shutdown to single user mode first:
# shutdown -i1 # cd / # mv var var.ORIG # mkdir /varNow put an entry in /etc/fstab for the new /var partition:
/dev/var /var efs rw,raw=/dev/rvar 0 0Now mount this new /var and copy the existing files from the old /var.ORIG so we have a place to spool mail, logs, etc.
# mount /var # cd /var.ORIG # tar cf - . | (cd /var ; tar xpf -)Now you need to remove /usr/var and replace it with a link to the new /var:
# cd /usr # mv var var.ORIG # ln -s ../var var