Impossible edit file because permission changed

I have almost all my documents in a ntfs partition. Suddenly all these files are “read only” and I can’t modify or overwrite.
Permission shows owner is root.
Same problem if I open files using Linux Mint. Then it seems permission changed during an huge update I made yesterday. Is there any “bug” included in update?
How can I recover?

What kernel are you running? Please post uname -r
Is that partition mentioned in /etc/fstab (if so can you post the relevant line in /etc/fstab?) or is it mounted by user like an external usb drive?

I would also have a look at how it’s mounted - show the output of mount [device] so we can see how it’s actually mounted (you’ll need the partition name from /etc/fstab for this command).

As I recall, there was an update to the kernel’s ntfs support that added features; I want to say that one of the added features was support for ntfs permissions.

:~> uname -r
7.0.11-1-default

Not clear what I can put in place of [device].
This is what I find in /etc/fstab regarding partition with permission changed:

LABEL=DATI                      /mnt        ntfs    nofail     0 0 

What is the output of the mount command? Omitting the device parameter will show everything; I was just hoping to only have you share the one partition rather than everything.

Here is the output of mount command

/dev/nvme0n1p5 on / type btrfs (rw,relatime,ssd,discard=async,space_cache=v2,subvolid=256,subvol=/@)
devtmpfs on /dev type devtmpfs (rw,nosuid,size=7753240k,nr_inodes=1938310,mode=755,inode64)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev,inode64,usrquota)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=600,ptmxmode=000)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate,memory_recursiveprot,memory_hugetlb_accounting)
none on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run type tmpfs (rw,nosuid,nodev,size=3139840k,nr_inodes=819200,mode=755,inode64)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=40,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=9062)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,nosuid,nodev,relatime,pagesize=2M)
none on /run/credentials/systemd-journald.service type tmpfs (ro,nosuid,nodev,noexec,relatime,nosymfollow,size=1024k,nr_inodes=1024,mode=700,inode64,noswap)
/dev/nvme0n1p1 on /boot/efi type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro)
/var/lib/snapd/snaps/gtk-common-themes_1535.snap on /snap/gtk-common-themes/1535 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/gnome-46-2404_153.snap on /snap/gnome-46-2404/153 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/mesa-2404_1165.snap on /snap/mesa-2404/1165 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/mesa-2404_912.snap on /snap/mesa-2404/912 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/signal-desktop_909.snap on /snap/signal-desktop/909 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/signal-desktop_907.snap on /snap/signal-desktop/907 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/snapd_26865.snap on /snap/snapd/26865 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/snapd_26382.snap on /snap/snapd/26382 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/weasis_238.snap on /snap/weasis/238 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/gnome-42-2204_247.snap on /snap/gnome-42-2204/247 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/core24_1587.snap on /snap/core24/1587 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/core24_1643.snap on /snap/core24/1643 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
/var/lib/snapd/snaps/weasis_258.snap on /snap/weasis/258 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,nr_inodes=1048576,inode64,usrquota)
/var/lib/snapd/snaps/gnome-42-2204_226.snap on /snap/gnome-42-2204/226 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/core22_2411.snap on /snap/core22/2411 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/gnome-46-2404_145.snap on /snap/gnome-46-2404/145 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/core22_2339.snap on /snap/core22/2339 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/var/lib/snapd/snaps/bare_5.snap on /snap/bare/5 type squashfs (ro,nodev,relatime,errors=continue,threads=single,x-gdu.hide,x-gvfs-hide)
/dev/nvme0n1p6 on /home type xfs (rw,relatime,inode64,logbufs=8,logbsize=32k,noquota)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
none on /run/credentials/getty@tty1.service type tmpfs (ro,nosuid,nodev,noexec,relatime,nosymfollow,size=1024k,nr_inodes=1024,mode=700,inode64,noswap)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=1569916k,nr_inodes=392479,mode=700,uid=1000,gid=1000,inode64)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
tracefs on /sys/kernel/debug/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)

Kernel 7.0.11 has no meaningful change to the ntfs filesystem.
If you mount the partition via /etc/fstab that way, the default permissions for the ntfs3 module apply, that is owner is root:root and permissions are drwxrwxrwx unless you changed something else, so any user should be able to read and write files there.
Check ll /mnt/some_directory/ for anything suspicious.

[EDIT] but from your last post that partition does not appear to be mounted on /mnt??

Sorry, the information above might not be entirely correct (missed the edit window).
Apparently the ntfs3 module is blacklisted by default and ntfs filesystems should be mounted via fuseblk nevertheless but I cannot check for sure at the moment.

Yeah, I’m a little puzzled that the mount command isn’t showing it. But you’re right, the changes in the ntfs filesystem driver aren’t in 7.0, they’re coming in 7.1 - my mistake on that.

@Giorgio_os - how are you mounting the partition?

I did some tests with an external USB disk, so the following might not strictly apply to an internal or nvme disk.
With a line similar to the OP in fstab:

LABEL=Backup_W                             /mnt       ntfs  nofail        0  0

the mount result is:

/dev/sdb1 on /mnt type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)

and permissions on files are -rwxrwxrwx so they are world-writable even if owned by root:root, so everything as expected.
That is on a stock 7.0.11 Tumbleweed kernel, where the obsolete ntfs module is not even built and the old but still available ntfs3 module is blacklisted.

Then I went out of my way trying to use the ntfs3 module nonetheless, manually loading it via modprobe and using an fstab line like:

LABEL=Backup_W                             /mnt       ntfs3 nofail        0  0

(please note the 3 in ntfs3)
which yielded a mount line like:

/dev/sdb1 on /mnt type ntfs3 (rw,relatime,uid=0,gid=0,acl,iocharset=utf8,prealloc)

and permissions on files were -rwxr-xr-x so no write permission for users other than root, like in the OP.
But, I repeat, I went out of my way to use the ntfs3 module and ntfs3 filesystem mounting type.

I had manually unmounted it.

That partition is “automatically” mounted at boot.

First unmount partition then tried command using one of the directories of the partition

:~> ll /mnt/Musica/
ls: cannot access '/mnt/Musica/': No such file or directory

Of course, if you unmount it!
Please issue mount -a so all partitions in fstab are (re-)mounted, then show mount |grep mnt and ll /mnt/Musica/ again.

That is a bit strange. When the file system isn’t there you can get no information from it of course. It must be mounted to get anything useful from the ll command

It didn’t show in the mounted partitions list because it wasn’t mounted. We need to see that output when it is mounted to see (for example) if it is mounted read-only for some reason.

We can’t see that if it isn’t mounted. :wink:

Check the mount options for ntfs / ntfs-3g. It’s been a while, but to do anything useful with FAT / VFAT / NTFS, I recall using the uid, gid and umask mount options.

See also man mount.ntfs-3g.

Maybe this is also useful:

Sorry for misunderstanding your request. I reboot (partition is mounted at boot) and here’s what you asked for:

:~> mount |grep mnt
/dev/nvme1n1p2 on /mnt type fuseblk (ro,nosuid,nodev,relatime,user_id=0,group_id=0,allow_other,blksize=4096)
nsfs on /run/snapd/ns/signal-desktop.mnt type nsfs (rw)

and this is a directory with only one text file that LibreOffice opens as read only

:~> ll /mnt/LINUX_win/testi/
totale 44
-rwxrwxrwx 1 root root 44294 25 mag 12.43 imbuca.odt

Thanks for suggestion but it seems ntfs-3g isn’t used see see message 9