andyf@brueer.UUCP (Andrew Findlay) (01/23/86)
Adding an Eagle-2 (Fujitsu 2361) to a 4.2Bsd system =================================================== I have just put an Eagle-2 onto a VAX 750 under 4.2Bsd. This article describes how it was done so you need not repeat my mistakes. The software preparation and debugging took about 40 man-hours, but with the information presented here it should be possible in less than 8. The initial configuration was: 2MB, TU80, RA80 on UDA50, DMF-32 The expanded configuration is: 5MB, TU80, RA80 on UDA50, 2*DMF-32 Eagle-2 on SC7002 The Fujitsu 2361 Eagle-2 is an expanded version of the well known 2351A Eagle. It has an unformatted capacity of 689MB against the Eagle's 474MB. The first thing to note is that the disk transfer rate has gone up from 1.859 MB/s to 2.458 MB/s. This means that the Emulex SC7000 is not fast enough to handle the new drive. You will need an SC7002, which is just a faster version of the SC7000. Another hardware point is that the Eagle-2 is in a bigger box than the Eagle - 770mm long rather than 700mm. In our case this means that it sticks out at the front of the cabinet. Since the Eagle-2 was designed after the 4.2Bsd release, it does not appear in /etc/disktab or in the hp.c drivers. You will need to put it in. A quick-and-dirty workaround is to set up the SC7002 to treat the disk as an old-style Eagle - you lose storage capacity, but get up and running very easily. I have not tried this. Setting up the SC7002 ===================== Set up for an 'expanded RM02' emulation with 64 sectors/track. This is code 30 on SW1-4. The hp.c drivers use 'RM02' as a flag indicating that the disk type should be determined by asking for the number of tracks, cylinders, and sectors. You need at least revision F of PROM 994. Preparing the drivers ===================== (1) Use diskpart(8) to generate entries for /etc/disktab and for the hp.c drivers. Put the result in files for use later. Call the disk 'eagle2'. The parameters are as follows: Type: winchester Sector size: 512 # Sectors/track: 64 # Tracks/cylinder: 20 # Cylinders: 842 Revs per minute: 3600 You should end up with a 'c' partition of 1077760 blocks. (2) Install the 'eagle2' entry in /etc/disktab (3) Put entries into your configuration file in /sys/conf, something like this: controller mba0 at nexus ? disk hp0 at mba0 drive 0 This assumes the SC7002 will be the only massbus device - if you already have massbus devices, the 0's above will change. The SC7002 actually emulates a massbus controller AND up to eight massbus disks on one board. (It can split a physical drive into two logical devices) (4) Before modifying the system source code, generate a system from the new config file to check all is ok. If the controller is installed at this stage, the system should note the existence of an 'RM02 with 64 sectors/track?' but should not try to use the device. (5) Go into /sys/vaxmba to modify the main hp driver. First take a copy of hp.c for safety, then make changes to hp.c as follows: Add the eagle2_sizes entry generated in stage (1) - put it after eagle_sizes. It should look like this: }, eagle2_sizes[8] = { 15884, 0, /* A=cyl 0 thru 12 */ 66880, 13, /* B=cyl 13 thru 65 */ 1077760, 0, /* C=cyl 0 thru 841 */ 15884, 294, /* D=cyl 294 thru 306 */ 307200, 307, /* E=cyl 307 thru 546 */ 377408, 547, /* F=cyl 547 thru 841 */ 701248, 294, /* G=cyl 294 thru 841 */ 291346, 66, /* H=cyl 66 thru 293 */ Add two lines to hptypes[], just before the final 0: #define HPDT_EAGLE2 15 -1, These go just after the line that says 'beware, actually capricorn or eagle' Add TWO lines to the hpst[] array, as follows: { 64, 20, 64*20, 842, eagle2_sizes, 7, 8 }, /* DUMMY (place holder) */ { 64, 20, 64*20, 842, eagle2_sizes, 7, 8 }, /* EAGLE-2 */ The dummy line is needed because hptypes[] has a dummy element 14, representing the RM02, whereas hpst[] does not. This one held me up for a couple of days - the system panics when trying to reference the disk if you miss the dummy entry. In the section headed 'EMULEX SC750 or SC780', add code to recognise the disk at boot time. Put it after the bit that recognises an eagle: if (ntracks == 20 && nsectors == 64) { type = HPDT_EAGLE2; printf("hp%d: eagle-II\n", mi->mi_unit); goto done; } (6) Re-generate the system with the modified driver. (7) Use /dev/MAKEDEV to make device entries for hp0 (8) Go into /sys/stand to modify the stand-alone hp driver. In hp.c add a line to the end of hptypes[], so it looks like this: . . . MBDT_RM02, /* actually something else */ -1, /* 9300 */ -1, /* Eagle-II */ 0 }; In hpmaptype.c add a line to describe the eagle2 and its disk partitions. Be particularly careful if you did not use diskpart in stage (1). short eagle_off[8] = { 0, 17, 0, 391, 408, 728, 391, 87 }; short eagle2_off[8] = { 0, 13, 0, 294, 307, 547, 294, 66 }; Now add two lines in hpst[] so it looks like this: . . . #define HPDT_9300 13 32, 19, 32*19, 815, rm05_off, /* Ampex 9300 */ #define HPDT_EAGLE2 14 64, 20, 64*20, 842, eagle2_off, /* Fuji Eagle-II */ }; Now add the code to recognise the eagle2: if (ntracks == 48) { newtype = HPDT_EAGLE; /* 48 sector Eagle */ goto done; } if (ntracks == 64) { newtype = HPDT_EAGLE2; /* 64 sector Eagle */ goto done; } printf("RM02 with %d sectors/track?\n", ntracks); done: (9) Reconstruct the standalone utilities with make, and copy what you need into the root filesystem. This will probably be: format copy boot drtest On a 780, these should go onto the console floppy (?) (10) Dump the ENTIRE system onto tape and then get the hardware installed! (11) The Emulex formatter does not seem to get the bad block info in the right place for the hp driver, so use the newly generated version of format(8) to sort that out (in standalone mode of course). It is then worth using drtest(8) to check that all the bad blocks have been found. (12) When you boot up the new system, the lines: mba0 at tr4 hp0 at mba0 drive 0 hp0: Eagle-II (or something very similar) should appear on the console. (13) You should now have a working 540MB disk. Create filesystems with newfs(8) and put it to work. To get the best possible performance out of the filesystems, the rotational delay parameter needs to be set appropriately with tunefs. I used Don Speck's test program and found 8ms to be good, so the command is: tunefs -d 8 /dev/hp0h Remember to do this for each filesystem after creating it. Perhaps surprisingly, I can find no significant difference in performance between a filesystem on an RA80 and one on an Eagle-2. These tests were done with a load factor of about 1.4 - one active user with a cpu-bound process: % time dd if=<big file on RA80> of=/dev/null bs=1024 count=1024 1024+0 records in 1024+0 records out 0.4u 4.8s 0:09 57% 13+9k 129+2io 2pf+0w % time dd if=<big file on Eagle-II> of=/dev/null bs=1024 count=1024 1024+0 records in 1024+0 records out 0.3u 5.0s 0:09 59% 13+9k 263+2io 2pf+0w Good luck, and please let me know if I have missed out anything vital.... Andrew Findlay ... ukc!reading!brueer!andyf ... andyf@uk.ac.bru.ee -- ------------------------------------------------------------ UUCP: ...ukc!reading!brueer!andyf JANET: andyf%brueer@uk.ac.reading ARPANET, CSNET: andyf%brueer@ucl-cs.arpa ------------------------------------------------------------