LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 01-15-2012, 11:27 AM   #1
jjonas
Member
 
Registered: Jul 2005
Location: Finland
Distribution: Arch Linux
Posts: 80

Rep: Reputation: 15
USB pen drive format


Hi,

I have a USB pen drive, of which Nautilus says when it tries to mount it:

Error mounting: mount: wrong fs type, bad option, bad superblock on /dev/sdc1,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so

Dmesg in turn says:

[38224.159693] sd 9:0:0:0: [sdc] Asking for cache data failed
[38224.159704] sd 9:0:0:0: [sdc] Assuming drive cache: write through
[38224.163780] sd 9:0:0:0: [sdc] Asking for cache data failed
[38224.163793] sd 9:0:0:0: [sdc] Assuming drive cache: write through
[38224.431331] sdc: sdc1
[38224.434886] sd 9:0:0:0: [sdc] Asking for cache data failed
[38224.434897] sd 9:0:0:0: [sdc] Assuming drive cache: write through
[38224.434906] sd 9:0:0:0: [sdc] Attached SCSI removable disk
[38224.997304] FAT-fs (sdc1): bogus number of reserved sectors
[38224.997313] FAT-fs (sdc1): Can't find a valid FAT filesystem

It turned out this way after - for reasons that are unclear - the drive became read-only with part of its contents corrupted and unreadable. So I thought trying formatting it (based on instructions I can't find on the net anymore, sorry), but the above is the end result.

Is the something that can be done? I guess it's possible the drive's just gone bad to begin with, with the corrupted unreadable data there already before I started messing around with it.
 
Old 01-15-2012, 11:41 AM   #2
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,399
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
It is simple enough to put a new filesystem on any block device. First:
Code:
man mkfs
then
Code:
mkfs -t <filesystemtype> /dev/devicePartition
In your case that probably should be
Code:
mkfs -t vfat /dev/sdc1
Note that there is nothing to say that USB flash drives must be formatted with DOS filesystems, nor that they must have one giant partition. Most, if not all USB flash drives are factory formatted that way for compatibility with Windows. If the device is actually broken, you have nothing to lose by trying to reformat it.

--- rod.

Last edited by theNbomr; 01-15-2012 at 12:41 PM.
 
1 members found this post helpful.
Old 01-15-2012, 12:37 PM   #3
otoomet
Member
 
Registered: Oct 2004
Location: Tartu, Århus,Nürnberg, Europe
Distribution: Debian, Ubuntu, Puppy
Posts: 619

Rep: Reputation: 45
You may also try to remove the existing partition and create a new (using fdisk or something like gparted).
 
Old 01-15-2012, 01:25 PM   #4
jjonas
Member
 
Registered: Jul 2005
Location: Finland
Distribution: Arch Linux
Posts: 80

Original Poster
Rep: Reputation: 15
Thanks, that solved the problem!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to make sure that no body could format my pen drive or Harddisk dirve in any OS tarunchawla Linux - Security 5 12-17-2011 05:34 PM
Best filesystem to format USB pen drive with to be usable from Windows, Mac, Linux? veeruk101 Linux - Newbie 1 11-04-2011 02:39 PM
[SOLVED] Trying to format Pen drive to ext 3 Tony_photoplus Linux - General 3 01-24-2011 06:39 AM
pen drive problem..format chessonly Linux - General 3 05-04-2009 08:54 AM
USB flash drive (Pen drive) mounts read only prabhatsoni Linux - Hardware 24 07-02-2007 01:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:56 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration