initialize msdosfs on memory stick?
I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On Thu, 12 Sep 2013 16:13:11 -0600, Gary Aitken wrote: On 09/12/13 15:51, Polytropon wrote: On Thu, 12 Sep 2013 15:39:26 -0600, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? It is possible. The OS provides the newfs_msdos tool. There is no need to deal with Windows for this task. Great, thanks. I checked the newfs manpage but didn't look too carefully when the summary line said construct a new UFS1/UFS2 file system That's correct: newfs refers to newfs_ufs (which obviously initializes a UFS file system), but there are other newfs_* just as there are corresponding (and more) mount_* commands. See man newfs_msdos for more details. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On Thu, 12 Sep 2013 15:39:26 -0600, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? It is possible. The OS provides the newfs_msdos tool. There is no need to deal with Windows for this task. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ... ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On 09/12/13 15:51, Polytropon wrote: On Thu, 12 Sep 2013 15:39:26 -0600, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? It is possible. The OS provides the newfs_msdos tool. There is no need to deal with Windows for this task. Great, thanks. I checked the newfs manpage but didn't look too carefully when the summary line said construct a new UFS1/UFS2 file system ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On Thu, 12 Sep 2013, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? Sure, it's possible. For maximum compatibility, I'd suggest creating an MBR layout on it. Some devices expect that. Assuming it is da0 (make sure) and that everything on it has been backed up... # gpart destroy -F da0 # gpart create -s mbr da0 # gpart add -t \!12 da0 # newfs_msdos -F32 /dev/da0s1 ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On 09/12/13 16:26, Polytropon wrote: On Thu, 12 Sep 2013 16:13:11 -0600, Gary Aitken wrote: On 09/12/13 15:51, Polytropon wrote: On Thu, 12 Sep 2013 15:39:26 -0600, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? It is possible. The OS provides the newfs_msdos tool. There is no need to deal with Windows for this task. Great, thanks. I checked the newfs manpage but didn't look too carefully when the summary line said construct a new UFS1/UFS2 file system That's correct: newfs refers to newfs_ufs (which obviously initializes a UFS file system), but there are other newfs_* just as there are corresponding (and more) mount_* commands. See man newfs_msdos for more details. I see that; but was surprised newfs didn't see-also newfs_msdosfs. Anyhoo... ugh, I think I just screwed it up, not thinking things through. After doing # newfs_msdos -F 32 -S 4096 /dev/da0 newfs_msdos: trim 62 sectors to adjust to a multiple of 63 /dev/da0: 979584 sectors in 30612 FAT32 clusters (131072 bytes/cluster) BytesPerSec=4096 SecPerClust=32 ResSectors=4 FATs=2 Media=0xf0 SecPerTrack=63 Heads=255 HiddenSecs=0 HugeSectors=979650 FATsecs=30 RootCluster=2 FSInfo=1 Backup=2 I can't mount it, and there are no partitions: # ls /dev/da0* /dev/da0 # mount -t msdosfs /dev/da0 /mnt/memstick mount_msdosfs: /dev/da0: Invalid argument Normally there is a /dev/da0s1. I suspect I *should* have used /dev/da0s1 in the newfs_msdos cmd. So, attempting to re-establish the partitions: #gpart create -s MBR da0 da0 created # gpart show -l da0 = 63 7837633 da0 MBR (3.8G) 63 7837633 - free - (3.8G) # gpart add -t mbr da0 gpart: Invalid argument now what? Is mbr the wrong kind of partition type? man gpart indicates the MBR scheme requires the GEOM_PART_MBR kernel option; since the create succeeded, I'm assuming this is present? ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
Gary Aitken wrote: On 09/12/13 16:26, Polytropon wrote: On Thu, 12 Sep 2013 16:13:11 -0600, Gary Aitken wrote: On 09/12/13 15:51, Polytropon wrote: On Thu, 12 Sep 2013 15:39:26 -0600, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? It is possible. The OS provides the newfs_msdos tool. There is no need to deal with Windows for this task. Great, thanks. I checked the newfs manpage but didn't look too carefully when the summary line said construct a new UFS1/UFS2 file system That's correct: newfs refers to newfs_ufs (which obviously initializes a UFS file system), but there are other newfs_* just as there are corresponding (and more) mount_* commands. See man newfs_msdos for more details. I see that; but was surprised newfs didn't see-also newfs_msdosfs. Anyhoo... ugh, I think I just screwed it up, not thinking things through. After doing # newfs_msdos -F 32 -S 4096 /dev/da0 newfs_msdos: trim 62 sectors to adjust to a multiple of 63 /dev/da0: 979584 sectors in 30612 FAT32 clusters (131072 bytes/cluster) BytesPerSec=4096 SecPerClust=32 ResSectors=4 FATs=2 Media=0xf0 SecPerTrack=63 Heads=255 HiddenSecs=0 HugeSectors=979650 FATsecs=30 RootCluster=2 FSInfo=1 Backup=2 I can't mount it, and there are no partitions: # ls /dev/da0* /dev/da0 # mount -t msdosfs /dev/da0 /mnt/memstick mount_msdosfs: /dev/da0: Invalid argument Normally there is a /dev/da0s1. I suspect I *should* have used /dev/da0s1 in the newfs_msdos cmd. So, attempting to re-establish the partitions: #gpart create -s MBR da0 da0 created # gpart show -l da0 = 63 7837633 da0 MBR (3.8G) 63 7837633 - free - (3.8G) # gpart add -t mbr da0 gpart: Invalid argument now what? Is mbr the wrong kind of partition type? man gpart indicates the MBR scheme requires the GEOM_PART_MBR kernel option; since the create succeeded, I'm assuming this is present? ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org read this how to http://forums.freebsd.org/showthread.php?t=13780 ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On 09/12/13 17:52, Warren Block wrote: On Thu, 12 Sep 2013, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? Sure, it's possible. For maximum compatibility, I'd suggest creating an MBR layout on it. Some devices expect that. Assuming it is da0 (make sure) and that everything on it has been backed up... # gpart destroy -F da0 # gpart create -s mbr da0 # gpart add -t \!12 da0 # newfs_msdos -F32 /dev/da0s1 That worked, thanks. Where is the magic file type !12 described? I don't see it as one of the possibilities in man gpart. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On Thu, 12 Sep 2013, Gary Aitken wrote: On 09/12/13 17:52, Warren Block wrote: On Thu, 12 Sep 2013, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? Sure, it's possible. For maximum compatibility, I'd suggest creating an MBR layout on it. Some devices expect that. Assuming it is da0 (make sure) and that everything on it has been backed up... # gpart destroy -F da0 # gpart create -s mbr da0 # gpart add -t \!12 da0 # newfs_msdos -F32 /dev/da0s1 That worked, thanks. Where is the magic file type !12 described? I don't see it as one of the possibilities in man gpart. It's one of the many MS-DOS FAT variations: http://en.wikipedia.org/wiki/Partition_type ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org
Re: initialize msdosfs on memory stick?
On 09/12/13 20:58, Warren Block wrote: On Thu, 12 Sep 2013, Gary Aitken wrote: On 09/12/13 17:52, Warren Block wrote: On Thu, 12 Sep 2013, Gary Aitken wrote: I can't seem to find how to do this in the handbook or man pages. I need to initialize a usb memory stick with an msdos file system. Is it possible, or do I have to find a windoze system? Sure, it's possible. For maximum compatibility, I'd suggest creating an MBR layout on it. Some devices expect that. Assuming it is da0 (make sure) and that everything on it has been backed up... # gpart destroy -F da0 # gpart create -s mbr da0 # gpart add -t \!12 da0 # newfs_msdos -F32 /dev/da0s1 That worked, thanks. Where is the magic file type !12 described? I don't see it as one of the possibilities in man gpart. It's one of the many MS-DOS FAT variations: http://en.wikipedia.org/wiki/Partition_type Not fair, that makes it really magic ;-) Thanks ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org