So the install image on my IDE drive hd0a has the /etc/fstab file point to sd0a for / instead of hd0a.
How do I mount /dev/hd0a as writable [/] so I can edit the fstab file to change sd0a to hd0a so it can mount and boot.
What commands do I type in single user mode so I can achieve this?
Thanks.
Is the problem that you've booted into single-user mode and / has been mounted readonly from /dev/hd0a?
If so, here's what I would try, based on my Linux experience. I'm not sure it works for NEXTSTEP, though I note the NS 3.3 manpage does include the remount option, which is encouraging:
# fsck /dev/hd0a # Check root filesystem for damage first
# mount -o remount,rw /dev/hd0a / # Remount / as read-write
# vi /etc/fstab # Change /etc/fstab
# sync; sync; sync # Flush all writes to disk
# mount -o remount,ro /dev/hd0a / # Remount / as read-only
This should leave you back at the starting state but with /etc/fstab changed.
Thanks
@stepleton your advice worked. Used the following:
# fsck /dev/hd1a # Check root filesystem for damage first
# mount -o remount,rw /dev/hd1a / # Remount / as read-write
# sed 's/sd0a/hd1a/g' /etc/fstab >/etc/fstab2 # Use /bin/sed to replace sd0a with hd1a to output /etc/fstab2.
# cp /etc/fstab2 /etc/fstab # replace original /etc/fstab with /etc/fstab2
to edit the fstab file. Typed
exit and the install image crashed with a error message ;D . Shortcuts never work, creating my own image.