[comp.sys.sun] How do you make a bootable floppy?

sld@beach.cis.ufl.edu (01/16/91)

Is it possible (without enormous pain) to make a bootable floppy for a
SPARCstation or a 386i?  We have about 20 386i's and in the course of a
week we have knocked out three of them so that root login is not allowed
(some NIS problem).  Since we're tired of reloading the system from tape
we thought it would be nice to break in with a bootable floppy.

The software support person at Sun wanted nothing to do with this
neferious procedure and refused to provide any help citing some sort of
copyright violation (the act of copying /boot to a floppy).  Since we're
tired of reloading the system and feel that we have every right to break
in to our own property we're going to the net for assistance.

Here is the procedure we have tried:

1. fdformat			(fdformat knows to use /dev/rfd0c)
2. newfs /dev/rfd0c		(or mkfs for 4.0.2 since newfs is broken)
3. mount /dev/fd0c /mount-point	(/mount-point is of your choosing)
4. cp /boot /mount-point
5. /usr/mdec/installboot /mount-point/boot /usr/mdec/bootfd /dev/rfd0c
6. cp /vmunix /mount-point	(or use a cut down kernel)
7. cp /etc/mount /mount-point
8. cp /etc/fsck /mount-point	(if it will fit)

This seems to make an almost booting floppy that reads the kernel file and
starts most of the device drivers.  On a SPARCstation the process dies
with the following messages:

	fd0: read failed (40 10 0)
	fd0: data overrun/underrun
	panic: vfs_mountroot cannot mount root

and on the 386i it crashes a few device drivers later with:

	can't invoke /usr/bin/init  error 2
	panic: writing all file system information
	xxxx pages left fddump: not implemented
	fddump: not implemented
	fddump: not implemented
	fddump: not implemented
	fddump: not implemented
	fddump: not implemented
	fddump: not implemented
	xxxx pages left fddump: not implemented
	.
	.
	.

Thanks in advance, any help will be greatly appreciated.

StSteven L. Davis  Internet: sld@beach.cis.ufl.edu
                     UUCP: ...gatech!uflorida!beach.cis.ufl.edu!sld

sjg@sun0.melb.bull.oz.au (Simon J. Gerraty) (01/30/91)

In <1289@brchh104.bnr.ca> sld@beach.cis.ufl.edu writes:
>Is it possible (without enormous pain) to make a bootable floppy for a
>SPARCstation or a 386i?  We have about 20 386i's and in the course of a
>...

>Here is the procedure we have tried:

>1. fdformat			(fdformat knows to use /dev/rfd0c)
>2. newfs /dev/rfd0c		(or mkfs for 4.0.2 since newfs is broken)

Wish I could help more...

On SunOS 4.0.2 on a 386i I use:

mkfs /dev/rfd0c 2880 18 2 4096 512 8 5 6

The 6 at the end, is 6 revs per second (360 pm) vs the default of 60
(3600).  Without this the floppy file system gets corrupted very easily.

Even with the above, I find that no amount of sync'ing before umount
prevents the diskette from becomming corrupted after a while.   It may be
necessary to leave the diskette _in_ the drive for some time after unmount
(and after the drive light goes out).

We had a set of boot floppies for one of our 386i's but of course it
failed (before I made a backup).  I'd like to be able to make a
replacement.


>This seems to make an almost booting floppy that reads the kernel file and
>starts most of the device drivers.  On a SPARCstation the process dies
>with the following messages:

>	fd0: read failed (40 10 0)
>	fd0: data overrun/underrun
>	panic: vfs_mountroot cannot mount root

This sounds consitent with the rps param to mkfs being wrong.

>and on the 386i it crashes a few device drivers later with:

Well, I would like to hear if/when you get it working.

Simon J. Gerraty		<sjg@melb.bull.oz.au>