The NEXTSTEP/OpenStep FAQ
disktab
ST15230N
Seagate, ST15230
This is the /etc/disktab entry for the SEAGATE ST15230N.
ST15230N_1024|SEAGATE ST15230N_1024:\
:ty=fixed_rw_scsi:nc#3992:nt#19:ns#59:ss#1024:rm#5411:\
:fp#160:bp#0:ng#0:gs#0:ga#0:ao#0:\
:os=sdmach:z0#32:z1#96:hn=localhost:ro=a:\
:pa#0:sa#512000:ba#8192:fa#1024:ca#8:da#4096:ra#10:oa=time:\
:ia:ta=4.3BSD:\
:pb#512000:sb#512000:bb#8192:fb#1024:cb#8:db#4096:rb#10:ob=time:\
:ib:tb=4.3BSD:\
:pc#1024000:sc#716800:bc#8192:fc#1024:cc#8:dc#4096:rc#10:oc=time:\
:ic:tc=4.3BSD: \
:pd#1740800:sd#1536000:bd#8192:fd#1024:cd#8:dd#4096:rd#10:od=time:\
:id:td=4.3BSD: \
:pe#3276800:se#1150000:be#8192:fe#1024:ce#8:de#4096:re#10:oe=time:\
:ie:te=4.3BSD:
DEC, DSP3105
DPS3105, 1024 block size
disktab
A DEC DSP3160S was reformatted with 1024-byte blocks using the following entry in /etc/disktab (two partitions)
# DEC DSP3160S
DSP3160S|DEC DSP3160S|DEC DSP3160S w/1024 b/sec as 2 partition:\
:ty=fixed_rw_scsi:nc#1302:nt#16:ns#75:ss#1024:rm#5403:\
:fp#160:bp#0:ng#0:gs#0:ga#0:ao#0:\
:os=sdmach:z0#32:z1#96:r0=a:\
:pa#0:sa#744000:ba#8192:fa#1024:ca#7:da#4096:ra#10:oa=time:\
:ia:ta=4.3BSD:\
:pb#744000:sb#818400:bb#8192:fb#1024:cb#7:db#4096:rb#10:ob=time:\
:ib:tb=4.3BSD:
filesystem, overhead
disk space
space, disk
filesystem, space
Let's assume you bought a disk drive advertised with 400 MB unformatted capacity. Vendors are not consistent with the MB definition. You may have much less space less than you think you have. Which of the following did you buy?
400 * 1000 * 1000 = 400,000,000 bytes
400 * 1024 * 1000 = 409,600,000 bytes
400 * 1024 * 1024 = 419,430,400 bytes
(for Quantum drives the following is true: Quantum defines 1MB to be exactly 1000000 Bytes).
The disk must be formatted. This is often done by the vendor, but occasionally by the user. Formatting maps the disk into sectors. Space is reserved for the disk geometry and bad sectors. Formatting can take 10-20% of the capacity depending on the sector size. Common sector sizes are 512 and 1024. Generally, bigger sectors mean less waste.
Once formatted, the UNIX file system must be created. On the NeXT, this is one of the steps performed by the BuildDisk application. It invokes the mkfs command to make a file system. This reserves space for the UNIX file system (e.g., superblocks, inode tables). This overhead can take another 2-3% of the available disk space.
If you issue the df command, you may be surprised to see another 10 the available disk space has disappeared. The df command shows the total, used, and available disk space. The df units are in kbytes (1024 bytes). The sum of the used and available numbers will generally be about 10 allow the UNIX file system to be efficient in its storage allocation. If your disk fills up, only the superuser can store files in the remaining 10%.
To complete the picture, here's a snapshot of what may occur:
Capacity Lost/Used/ Reason
Reserved
(in bytes) (in bytes)
419,430,000 19,430,000 Marketing hype (~5\%)
400,000,000 60,000,000 Formatting (~15\%)
340,000,000 6,800,000 UNIX file system (~2\%)
333,200,000 33,320,000 Efficiency & superuser (~10\%)
299,880,000
For more information, refer to the df and mkfs man pages.
initializing
Sometimes there are problem initializing disks. This only occurs if the disk is already formatted, but in a different format, e.g. the sector size was changed etc.
Mostly you can overcome this problem by using the sdformat utility available on the FTP sites. (Not sdform by NeXT, which is incapable to do this). After using sdformat, you should be abel to further format the media within Workspace.
OD, NeXT
optical disk, OD
OD, initializing
Do the following:
/etc/mkfs /dev/rsd1a 288339 1803 2 8192 1024 12 10 60 4096 t
tape drive
Using Configure.app add the SCSITape driver to support any SCSI tape drives in the "Others" config.
recover, disk
Often people (mostly on Intel) complain about a formatted disk (sometimes partially) due to an installation process error of some other OS. There is a chance to recover most of the data. The following assumes you are on Intel, other hardware user have to handle things much less complicated, but the way is similar:
- Prepare a new hard drive for booting
- Don't try to repair the broken drive!
- On Intel run fdisk to repartition the drive as it was before. If you are not able to do this, you are lost. Delete all evtl. new created partitions. By repartitioning, you won't loose data on the drive.
- Run disk on the broken drive e.g. type disk -rsd1h.
- Now scan the disk for superblocks by entereing the scan command at the interactive disk command prompt.
- If your disk was partially formatted, use a higher superblock number to supply fsck with an new superblock. E.g. if a superblock was found at 3145 use fsck -b3145 -y /dev/sd1a (assuming the first partition is the broken one).
- After this run, it is most important to reboot without syncing the drives! E.g. just turn off the computer without shutting down, or use the reboot -n command.
- After rebooting the run fsck again, if it isn't done by the system itself.
- You should be able to access the drive again now. Recovered files are placed in the /lost+found directory.
IOmega, ZIP
ZIP drive
There are frequently asked questions about the IOmega ZIP drive. One question will be answered here: 'Yes, it works with NEXTSTEP'.
For other question I'd like to point you to the ZIP-drive FAQ: http://www.radical.com/TheSolutions/RadicalSolution4.html
4GB drive
2GB partition limit
Quantum sizes
If you are going to use large drives (greater 2GB) you need to partition this drive (true at least for OS versions up to 4.0). These are the common ways to go without too much trouble and it provides an very easy way for 4GB drives under NS3.3.
1. Solution: disktab
- If you need more than 3 partitions, you have to write a disktab entry! Using fdisk (Intel systems only) has no effect.
- On how to write a disktab entry, read the NeXTanswers (search for partition)
- other pointers are: 'scsimodes' and 'man disktab'.
2. Solution: installation on drive to partition
- for Quantum drives the following is true: Quantum defines 1MB to be exactly 1.000.000 bytes. So if you are suited best by using 2 partitions on a Quantum Atlas 34300 (4.3GB drive-Quantum size, 4GB+5MB real size)
- 2 partitions are automatically handled on all NS3.3 platforms
- To easily install the drive by not writing a disktab entry do the following:
1) disconnect all other drives and connect the 4GB drive with ID 0
2) start a plain NS3.3 installation via disks and the CD-ROM
3) when the installation of files starts (text based output) you may break the procedure (the disk will get fsck'ed later) or wait until the system reboots and hangs :-) (no fsck needed then)
4) you should previously have read some line telling you: initializing sd0b
5) now reconnect your old boot drives and restart NEXTSTEP with the old boot drives. Switch the 4GB drive to a different ID.
6) Only the first partition of the 4GB drive will get mounted automatically, this is due to a documented bug in the automounter.
7) to permanently mount both partitions, add your drive partitions to the /etc/fstab file. Test mounting and umounting by hand first.
8) everything should work fine now after a second reboot, and if you set up your fstab file correctly, both partitions will get mounted.
- To switch the boot partition to the new 4GB drive continue with:
1) only the first partition is bootable (you'll notice that by doing a ls -l on the mount entry --- there is the 't' file mode)
2) (cd / ; gnutar -clf -)|(cd <1.partition>; gnutar -xvpf -) This transfers your root partition to the new partition.
3) now try a boot from the new drive, by entering in the boot prompt: sd(x)mach_kernel (bsd for NeXT)
fstab
mount, during boot
disk, protection
protection, disk
disk, ignore
foreign filesystems
filesystem, ignore
If you just format a new disk attached to your computer, it will get automounted by the Workspacemanager and unmounted when you log out. To utilize the disk during the boot process or to have fixed pathes and protections you need to create an entry in /etc/fstab for the drive. See the Unix manual pages for more details.
This is also the solution for ignoring disks or partitions of a disk with a foreign filesystem, which the Workspacemanager otherwises would prompt you for formatting.
A common mistake for /etc/fstab is to inlcude the noauto keyword in subsequent mounts. Don't include this keyword for further mount entries!
CD-ROM, multisession
multisession
Argh. Yes it's true. The original NEXTSTEP/OPENSTEP drivers can't read multisession CD-ROMs. Only the first session can be used. If it is audio, CDPlayer is started if it's data it is just automounted to become accessable though Worksapce manager.
Luckily there is a commercial driver out there, which enables NEXTSTEP/OPENSTEP to take advantage of multisession CD-ROMs.
CDXA Driver
Price DM 48,- (about $US 30)
Uwe Tilemann
Tools GmbH
Adolfstr. 5
D-53111 Bonn
GERMANY
Phone: +49 0228 98580-0
Fax: +49 0228 98580-17
Email: ut@Tools.DE (NeXTmail/MIME)
WWW: http://www.Tools.DE/
|