ULTRIX Tipps & Tricks

Stepstones

Since the ULTRIX documentation is a litte sparse, to put it mildly. So you get stuck much to often.

I don't want to eat my disk!

You should never try to mary a disk with more than one gigabyte with an ULTRIX predating V4.2A. I had the problem with a V4.1 built in 1993 ...

 

The pre V4.2A versions cannot deal with block numbers above 221-1. Instead of just not working, it's nasty and wraps around, overwriting the data on the low numbered blocks. Booom.

 

The only solution is to use only the first gigabyte of the disk.

Woah! My disk is too large!

All ULTRIX versions can only administer partitions smaller than 2GB. Of course no one prevents you from creating a larger partition, but the following newfs fails with an obscure error message.

The new disk won't boot!

There are two possibilities. Either it just does not work (happened to me once) or, more probable, it lacks a boot block. In the first case the monitor complains that it cannot find a boot block, in second case abount the boot block having a wrong format.

 

If it just does not work, you can only use another disk. In the other case you typicaly did not create the root file system with newfs but with mkfs. Only when creating a file system on an a-partition with newfs a boot block is written to the disk. Since newfs expects to find a disk geometry description in /etc/disktab, you might have to create one.

Procedures

 

Replacing the system disk with a larger one.

Since the typical DECstation disk hold between 200 and 500MB, the wish for more storage is not uncommon. The simplest way is to attach an extra data disk. But when the system disk is an external 5.25" disk (yes, this was sold), wouldn't it be nice to replace that brick with a sweet internal 3.5" disk.

 

To accomplisch that you attach the the new disk in addition to the the old one. When the system disk has e.g. ID1, you can jumper to new disk for ID2. Now power up the system and check if the new disk is recognised in the boot process. Query the disk geometry with rzdisk.
$ rzdisk -g /dev/rrz2a
You need the number of cylinders, the tracks per cylinder and the sectors per track. With this you create an entry in /etc/disktab, naming it apropritatly, e.g. "med4g" for a Seagate Medalist 4GB.

 

Next create the partitions with chpt. The partition is selected with the -p option. Arguments are the starting block, the number of blocks and the device name of the a- or c-partition.
$ chpt -pd 2354365 4364574 /dev/rrz2c
Defines a d-partition starting at 2354365 with 4364574 blocks on the disk with ID2. Now create file systems for all partitions (except b and c, which are swap and overlap). For this newfs uses the partizioning information from /etc/disktab.
$ newfs /dev/rz2d med4g
Creates a file system on the g-partition according the data in /etc/disktab. Unlike many other systems ULTRIX has no command to explicitly write the boot block. Instead the boot block is written automagically each time you create an a-partition with newfs.

 

Now the partitions are mounted on after the other and the data is coopied from the old disk to the new one.
$ mount /dev/rz2d /mnt $ cd /mnt $ dump 0f - /usr | restore rf -
Mounts the d-partition and copies the data in the /usr partition of the old disk. Its important to change the directory because restore unpacks all data into the current working directory.

 

Finally the DECstation is schut down and the old disk removed. Now you jumper the new disk to have the same ID as the old one, and the system should boot of the new disk.