The FreeBSD Diary

The FreeBSD Diary (TM)

Providing practical examples since 1998

If you buy from Amazon USA, please support us by using this link.
[ HOME | TOPICS | INDEX | WEB RESOURCES | BOOKS | CONTRIBUTE | SEARCH | FEEDBACK | FAQ | FORUMS ]
Using your floppy 16 January 1999
Need more help on this topic? Click here
This article has 4 comments
Show me similar articles
The following is an answer I sent to the FreeBSD questions mailing list:

On 15 Jan 99, at 22:19, Roy D. Fulton wrote:
> I'm new to FreeBSD and am quite rusty with UNIX period. I'm having
> trouble trying to use the floppy. Can anyone give me examples of the
> commands needed to prepare, read, and write to a blank floppy, and also
> how to use DOS floppies?

I was trying the same thing last night. I was told to do the following:

format: 		fdformat /dev/rfd0
disk label:		disklabel -w -r /dev/rfd0 fd1440
new file system:	newfs /dev/rfd0

[I'm now running 5.2.1 on my laptop, and I don't have a /dev/rfd0. I'm using /dev/fd0 instead and all seems well.]

I've been told to do the above, then mount it. Then you can treat it like any other file system. Use cp to copy, mv to move, etc.

mount floppy: 		mount /dev/fd0 /mnt
mount DOS floppy: 	mount -t msdos /dev/fd0 /mnt

The above commands allow you to access the contents of the floppy via the /mnt directory.

and remember to unmount:

umount /mnt

Hope this helps.

This tip is thanks to aLan Tait <aLan@fil.net>.

You might have seen the article on quickly mounting the CD-ROM.  Well, here's one for your floppy.  First, create a mount point for your floppy:

mkdir /fdd

Then add this line to you /etc/fstab file:

/dev/fd0    /fdd    ufs  rw,noauto    0    0

With such a line, you can mount/unmount your fdd with just the following commands:

mount  /fdd
umount /fdd 

Need more help on this topic? Click here
This article has 4 comments
Show me similar articles