linuxmint / nemo

File browser for Cinnamon
GNU General Public License v2.0
1.21k stars 300 forks source link

Nemo finds that my USB drive is read only, but it is clearly writable #1205

Closed surenenfiajyan closed 6 years ago

surenenfiajyan commented 8 years ago

After formatting my USB stick (with Mint's USB stick formatter) to FAT32 (before that it was a read-only ISOFS live USB made by Mint's USB image writer) I mounted it again (just opened with Nemo, without re-pluging) and I couldn't write any files to it, as Nemo was still finding it read-only. After restarting Nemo the problem disappeared. This bug is very old and is quite annoying.

pgmer6809 commented 8 years ago

Nemo has this problem with all USB sticks, under all conditions on my Mint17.3 system. Version 2.6.7 When automounting, or mouting by clicking on the Icon under the Devices section. But only for USB sticks. Other partitions on the hard drive will work fine when you click on them to mount. If I mount (or pmount) the USB sticks manually from the cmd line they work OK in Nemo. NAUTILUS (under Cinnamon) does not have this problem. It handles USB sticks OK. i.e. I can click on the icon and mount them R/W.

sinxwal commented 8 years ago

I have this too. Only Nemo says "The destination is read-only." It`s really crazy issue.

pgmer6809 commented 8 years ago

Nautilus however works fine. I think Caja still has the problem. So both Caja (the MATE File browser) and Nemo (The Cinnamon file browser) which were derived from Nautilus have the problem, but the original (Gnome) application does not. Greg

On Sat, Aug 6, 2016 at 1:23 PM, Sergey notifications@github.com wrote:

I have this too. Only Nemo says "The destination is read-only." It`s really crazy issue.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/linuxmint/nemo/issues/1205#issuecomment-238046997, or mute the thread https://github.com/notifications/unsubscribe-auth/ADUzJx9_50smNeM2w-b-Kheu_Pe4w44aks5qdO1cgaJpZM4I2sy2 .

xenopeek commented 8 years ago

Edit: I can reproduce this on Linux Mint 18 with Nemo 3.0.6.

surenenfiajyan commented 8 years ago

@xenopeek What exactly you did to reproduce this?

xenopeek commented 8 years ago

My mistake @surenenfiajyan, I can reproduce it on Linux Mint 18 with Nemo 3.0.6.

Steps to reproduce:

samgclarke commented 8 years ago

Can confirm this is the case on 17.3. Nemo reports over 90% of my external drives as Read-Only. Nautilus works fine.

wunderlich commented 8 years ago

I've got the same problem using Linux Mint 18 and Nemo 3.0.6. It's really frustating. I need to copy files to my USB-Drive every day. At the moment, I have to use the terminal ...

xenopeek commented 8 years ago

@wunderlich then you must be talking about a different issue I think. After formatting a USB thumb drive, mounting it afterwards keeps it read-only for some reason. Unmounting it and then mounting it once more fixes that state and is a workaround for this issue. There is no need to copy through the terminal.

leigh123linux commented 8 years ago

post the output for

udisksctl dump
KevinNadaud commented 7 years ago

Hi, I have the same bug on Linux Mint 18. When I insert a USB drive, Nemo says the USB drive is Read only. Using thunar, it works I can copy files. On a fresh install on another laptop, the problem is not present, I can copy files using Nemo. Does it can come from an bad update ?

yarinlicht commented 7 years ago

This bug affects me as well, Cinnamon 3.2.7, Nemo 3.2.2.

Both as exFAT on GPT

/dev/sdd1 on /media/<snip> type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

and FAT32 on MBR

/dev/sdd1 on /media/<snip> type vfat (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,showexec,utf8,flush,errors=remount-ro,uhelper=udisks2)

@xenopeek's workaround doesn't work for me.

udisksctl's output: https://www.zerobin.net/?0a3fa854e91a4da8#Tg2mCRCzXGN3Kmzvqar2E5uDzlX1NVT7ksl4Abx2eeU=

1u commented 7 years ago

I can write to SD-card with nautilus but not with nemo. But ls shows me, that owner is root:root. the file-managers are not running as root.

ls -ahl shows:

drwxr-xr-x  1 root root 128K Mar 10 15:17 .
drwxr-x---+ 3 root root 4,0K Mar 10 14:54 ..
drwxr-xr-x  1 root root 128K Fev 15 21:28 Linux

Remounting in shell or UI doesn't change behavior.

... Maybe this helps. System is old though:

LinuxMint 15 Cinnamon v.1.8.8  kernel 3.8.0-19-generic i686
nemo 1.8.3
nautilus 3.6.3

here is some more information: https://forums.linuxmint.com/viewtopic.php?f=208&t=176546 https://bugs.launchpad.net/linuxmint/+bug/1218076

Thanks to all the nemo-contributors!

surenenfiajyan commented 7 years ago

If I remember correctly, this bug was occurring only when the formatted USB drive's previous FS was read-only and was opened/mounted by Nemo. For example it won't occur if you format FAT to NTFS. I suspect that Nemo is somehow caching (probably storing in some variable or structure) the permissions. And after formatting it retrieves the permission from the cache instead of checking the actual permission.

Arnaudv6 commented 7 years ago

Indeed @surenenfiajyan: thanks for the tip. Clearing .local/share/gvfs-metadata/ did the trick here.

Piiit commented 7 years ago

I had this problem now on LM18.1 with nemo 3.2.2....

The workaround of @Arnaudv6 worked for me...

rm ~/.local/share/gvfs-metadata/*
killall nemo

ps. other workarounds mentioned above did not work.

Piiit commented 7 years ago

Related bug report: https://bugs.launchpad.net/ubuntu/+source/nautilus/+bug/1021375

mtwebster commented 7 years ago

Should be fixed by https://github.com/linuxmint/nemo/commit/df9118a3aff19b2bb097bc6bbc6e04126a04b07c

boorac commented 7 years ago

I am still having this issue on:

Mounting and unmounting does not solve the issue for me, killall nemo works for now.

vranki commented 7 years ago

Me too. This is not fixed.

juan88 commented 6 years ago

Still happening on:

eladhen commented 6 years ago

Why is this bug closed? I just had it in Linux Mint 18.3. This worked in fixing it:


rm ~/.local/share/gvfs-metadata/*
killall nemo
mtwebster commented 6 years ago

Because it was fixed at one point. It seems to have sprung up again, but I cannot reliably produce it like I was able to before.

Can anyone provide current steps to reproduce (feel free to be ridiculously over-detailed, you never can tell what matters sometimes) on nemo 3.6.x?

surenenfiajyan commented 6 years ago

@mtwebster My steps are a bit costly. I would be glad if someone found a cheaper way, but anyways, I'm for maximum reproducibility.

The following I did:

  1. Prepared some live USB with Mint's live USB creator in order to make a read-only FS.
  2. Inserted/re-plugged it and browsed with Nemo (also made sure that it was read-only).
  3. Formatted to a writable FS (FAT/NTFS etc) with Mint's USB stick formatter.
  4. Opened/mounted with Nemo (without re-plugging), tried to write something and Nemo gave an error: "The destination is read-only".

Note that this didn't occur when I skipped step 1 and the initial FS was writable.

I hope this helps you.

mtwebster commented 6 years ago

Thanks, reproduced this once more.

immortel32 commented 6 years ago

Nemo version 3.6.5 with Mint 18.3 and I'm having this issue too.

jontis commented 6 years ago

It's been like this for years. It's something when you use the mint live usb formatting that changes something on the USB to something that NEMO perceives as read only and that persists through normal formats.

jontis commented 6 years ago

I don't think this is a problem with Nemo, but more of the formatting utility. Copy from the solution I found that works: https://forums.linuxmint.com/viewtopic.php?t=180080

You can't write to an ISO9660 file system on any device because that file system does not support modification. A 64-bit Mint distribution ISO is especially confusing to disk utilities; it appears to be an MBR hard disk, a GPT hard disk and a bootable ISO file system, all at the same time. Any method that results in the store accepting new data means the hardware still working and you are wrestling with software. Normally clearing the first MiB of a store is sufficient to wipe all the control sectors left over from previous file systems...

sudo shred -s $((2048*512)) -vzn0 /dev/sdX

...followed by a ''quick'' format to super-floppy FAT to make it mountable and writable again...

sudo mkdosfs -I /dev/sdX

mtwebster commented 6 years ago

I have a fix for this for 3.8 that I haven’t pushed yet, still working on it.

jontis commented 6 years ago

Fantastic, but isn't the core problem in the formatting utilities that doesn't fix the strange image to a standard one? It's good that Nemo will be able to work around it like other utilities, but maybe it could indicate what the real problem is?

mtwebster commented 6 years ago

It was my understanding the issue was in (mostly) in Gio: https://bugzilla.gnome.org/show_bug.cgi?id=703179

In the current git master nemo with a recent glib version, simply reloading usb drive's directory or navigating away and back to it will resolve the read-only issue. The problem I'm still trying to work out with nemo is that it's missing the attribute changes as they happen, and only picks them up once the 'view' is reloaded on an already-mounted location.

TheRuleOfMike commented 6 years ago

@mtwebster So how is the push going? Linux 19 Tara here experiencing the same problem... again.

mtwebster commented 6 years ago

This should be fixed by the commit noted above. If you are still experiencing it, please detail exact steps to reproduce it. I cannot currently reproduce the issue on multiple machines.

PavelNiedoba commented 5 years ago

still persist in mint 18

NikoKrause commented 5 years ago

Which nemo version?

PavelNiedoba commented 5 years ago

3.6.5 Linux 4.15.0-34-generic #37~16.04.1-Ubuntu SMP Tue Aug 28 10:44:06 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

image

image

NikoKrause commented 5 years ago

This issue should to be fixed in https://github.com/linuxmint/nemo/commit/5b7419894edadfedf4cbccb30d670fd331abf11b, i.e. Nemo 3.8.3

Try to upgrade nemo

mapron commented 3 years ago

Nemo 4.6.5 - still mounts everything as readonly. Workarounds above do not help.

pgmer6809 commented 3 years ago

I have two USB ports on the front of my desktop case that I use for inserting USB stix. The dev names always seem to come out as /dev/sdc1 and /dev/sdd1 SO... In Nemo 4.6.5 (and Mint 19.x) I did the following: 1) create the directories /media/my_username/usb_c1, and /media/my_username/usb_d1 2) change the ownership of these directories to: mygroup,myusername with sudo chown -R mygroup,my_username /media/my_username 3) add these lines to the end of the /etc/fstab file:

/dev/sdc1 /media/my_username/usb_c1 vfat user,noauto,nofail,owner,noatime,nodiratime,norelatime,nosuid,nodev,exec,uid=1000,gid=1000,showexec 0 0

/dev/sdd1 /media/my_username/usb_d1 vfat user,noauto,nofail,owner,noatime,nodiratime,norelatime,nosuid,nodev,exec,uid=1000,gid=1000,showexec 0 0

above is a hack because my_username cant manually mount -t vfat, and

then root ends up owning the stick. (The numbers 1000 in the above are the numerical values for mygroup and my_username. may be different on your system but probably not.)

On Sat, Mar 13, 2021 at 5:52 AM Smirnov Vladimir @.***> wrote:

Nemo 4.6.5 - still mounts everything as readonly. Workarounds above do not help.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/linuxmint/nemo/issues/1205#issuecomment-798410818, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA2TGJYZ2HVB2MLWI2ZPMLDTDNUZJANCNFSM4CG2ZS3A .