USB stick is set to read-only, how to change it? (Solved)

Using applications, configuring, problems
Message
Author
totolanio
Posts: 202
Joined: Sun 04 Jan 2015, 02:19

USB stick is set to read-only, how to change it? (Solved)

#1 Post by totolanio »

Hello,

Everytime I use my USB stick on puppy, it's read only.
It wasn't the case months ago.

Very annoying.

What can I do ?
Main puppy used : LxPup tahr.
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=97623]Multiple package installer/remover.[/url]

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#2 Post by MochiMoppel »

File system is FAT32? Happened to me twice.

You could try to repair the corrupt fs with Puppy (I tried with command fsck /dev/sdb1, but never succeeded), or you could try to use the stick on a Windows machine. I think in XP it was Right-click - Properties - Tools -Scan for bad sectors. This did the trick for me. After all MS should know best how to repair its own creation :wink:

totolanio
Posts: 202
Joined: Sun 04 Jan 2015, 02:19

#3 Post by totolanio »

Yes its fat32 (i thought it was ntfs but no).

I also read on this forum that I can simply move all files and reformat it. Would it happen with NTFS ?
Main puppy used : LxPup tahr.
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=97623]Multiple package installer/remover.[/url]

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#4 Post by MochiMoppel »

totolanio wrote:I also read on this forum that I can simply move all files and reformat it.
Haven't tried it, but should work.
Would it happen with NTFS ?
Would what happen? Bad sectors? Yes.

totolanio
Posts: 202
Joined: Sun 04 Jan 2015, 02:19

#5 Post by totolanio »

is ntfs more prone to corruption than fat32 or less?
Main puppy used : LxPup tahr.
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=97623]Multiple package installer/remover.[/url]

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#6 Post by drunkjedi »

NTFS being a journaling FS is better than fat32.
But if you use that usb stick to connect to music system or TV etc, then they will not probably recognize NTFS.
So better keep it Fat32.

I think fsck also has options to detect and repair bad sectors.
Got to search...

User avatar
drunkjedi
Posts: 882
Joined: Mon 25 May 2015, 02:50

#7 Post by drunkjedi »

http://ubuntuforums.org/showthread.php?t=1203357
http://askubuntu.com/questions/147228/h ... ile-system
So we need fsck.vfat command for fat32 fs.
Or testdisk is also recommended.

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#8 Post by Burn_IT »

It depends very much on your use and requirements.
If you are transferring a lot of data to none known devices - then FAT32 or FATExt are better since they are more widely read - though this is less a problem nowadays.
If you are repeatedly writing to the USB Fat32 and FATExt will use up the write cycles more slowly since each NTFS write uses extra cycles for the journal as well.
If You are writing seldom, but reading a lot then NTFS is the way to go especially with many small files.
Of course none of this explains why it has suddenly become read only, though there IS a bit (flag) than can be set to make it do this. on some sticks.
"Just think of it as leaving early to avoid the rush" - T Pratchett

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#9 Post by Flash »

I had some kind of problem with a couple of FAT-32 flash drives, I can't remember if Puppy said they were "read-only" or what, but Gparted found that the boot flag was set, which I didn't need, and the problem went away after removing the boot flag with Gparted.

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#10 Post by Burn_IT »

The boot flag/bit and the read/write bit are different bits - though they may well exist within the same byte so if either is set using the wrong technique, the other could easily be affected.
"Just think of it as leaving early to avoid the rush" - T Pratchett

User avatar
nic007
Posts: 3408
Joined: Sun 13 Nov 2011, 12:31
Location: Cradle of Humankind

#11 Post by nic007 »

I have an mmc card stuck in read only. Also FAT32, not even Windows can fix it. Even tried some "registry trick" I found on the internet, zilts, nothing works.

User avatar
nic007
Posts: 3408
Joined: Sun 13 Nov 2011, 12:31
Location: Cradle of Humankind

#12 Post by nic007 »

Flash wrote:I had some kind of problem with a couple of FAT-32 flash drives, I can't remember if Puppy said they were "read-only" or what, but Gparted found that the boot flag was set, which I didn't need, and the problem went away after removing the boot flag with Gparted.
Gparted can't fix a read-only drive. It won't even access it and will search until doomsday
.

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#13 Post by Burn_IT »

Quite likely!!
"Just think of it as leaving early to avoid the rush" - T Pratchett

User avatar
Mike Walsh
Posts: 6351
Joined: Sat 28 Jun 2014, 12:42
Location: King's Lynn, UK.

#14 Post by Mike Walsh »

Hi, totolanio.

May have nothing at all to do with this, but.....your 'stick' isn't a SanDisk Cruzer 'Blade', by any chance?

The reason I ask is because SanDisk had a major manufacturing upset with the 'Blades' a couple or three years ago.....and their advice was that 'there is no 'fix'.' Send it back to them, and get a replacement.

It turned out they'd purchased a huge 'duff' batch of flash controller chips from Hynix, who refused to take them back.....especially since the problem only appeared totally at random. Once the chips went into 'read-only' mode, that was it. There was no solution. The SanDisk forums, at the time, were snowed under with complaints from people with exactly this problem; the outcome being, of course, that there are still hundreds of thousands of these sticks floating around out there in the marketplace.

It seemed to specifically concern the 16 GB models.....although there were reports of some 8 GB models being affected, too.


Mike. :wink:

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#15 Post by Flash »

nic007 wrote:Gparted can't fix a read-only drive. It won't even access it and will search until doomsday.
Then Puppy must not have said the drive was read-only, though I can't imagine what else the problem could have been. All I can remember for sure is that the problem was gone after the boot flag was removed.

User avatar
nic007
Posts: 3408
Joined: Sun 13 Nov 2011, 12:31
Location: Cradle of Humankind

#16 Post by nic007 »

Flash wrote:
nic007 wrote:Gparted can't fix a read-only drive. It won't even access it and will search until doomsday.
Then Puppy must not have said the drive was read-only, though I can't imagine what else the problem could have been. All I can remember for sure is that the problem was gone after the boot flag was removed.
Gparted can't access a read-only drive so you can't change the flag options with it.

totolanio
Posts: 202
Joined: Sun 04 Jan 2015, 02:19

#17 Post by totolanio »

Guys, I tried to reformat this usb stick so I unmount it and open gparted and it never detects anything, it keeps hanging at "searching partitions in /dev/sdb". I also tried to mount the USB stick, open Gparted, unmount in gparted and it did the same exact thing.

I tried it on ubuntu 14.04 and on puppylinux tahr.

So I can't reformat the USB stick o_0, what can I do please ?
Main puppy used : LxPup tahr.
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=97623]Multiple package installer/remover.[/url]

User avatar
Burn_IT
Posts: 3650
Joined: Sat 12 Aug 2006, 19:25
Location: Tamworth UK

#18 Post by Burn_IT »

You HAVE to remove the read only before you can change it in ANY way.
The way to do this will depend on the make and model of the stick (if it is at all possible)
Some preloaded sticks cannot be changed.
"Just think of it as leaving early to avoid the rush" - T Pratchett

totolanio
Posts: 202
Joined: Sun 04 Jan 2015, 02:19

#19 Post by totolanio »

So I must do this first :
File system is FAT32? Happened to me twice.

You could try to repair the corrupt fs with Puppy (I tried with command fsck /dev/sdb1, but never succeeded), or you could try to use the stick on a Windows machine. I think in XP it was Right-click - Properties - Tools -Scan for bad sectors. This did the trick for me. After all MS should know best how to repair its own creation Wink
??
Main puppy used : LxPup tahr.
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=97623]Multiple package installer/remover.[/url]

Peterm321
Posts: 411
Joined: Thu 29 Jan 2009, 14:09
Location: UK

#20 Post by Peterm321 »

Sometimes it may be worth checking the output of dmesg as sometimes a failure of the system to mount a filesystem read-write gets reported:

Code: Select all

 cat  /var/log/messages   |  grep -i mount 
In my past experience I have had one instance of a 128MB usb drive that went read only and not even a low level reformat was possible. In a couple of other cases read only was a result of filesystem write failures which required a reformat. Nowdays, its easier to get USB 3.0 compatible usb drives at low cost and so far (for me anyway) have worked without issue.

Post Reply