1

my chmod doesn't work properly.

I just reinstalled my manjaro distro (formated only the root, non the /home).

This folder resides on a ntfs partition (I already have ntfs-3g installed), I only need to set my user as proprietary of this folder:

~/backup ❯ ls -al
totale 4
drwxr-xr-x 1 root users    0 13 ago 10.08 .
drwxr-xr-x 1 root users 4096 13 ago 11.32 ..

Then I change permissions inside

~/backup ❯ sudo chown -R $USER .

But this is the result again:

~/backup ❯ ls -al
totale 4
drwxr-xr-x 1 root users    0 13 ago 10.08 .
drwxr-xr-x 1 root users 4096 13 ago 11.32 ..
~/backup ❯

Do you guys have any idea?

0
3

Windows and Linux have a very different user and permissions model that is incompatible. For either chmod or chown to work, the file system needs to support users and permissions in a Linux-like way. NTFS is a Windows file system and so these commands can't possibly work.

One thing you can do is to mount the NTFS partition specifying a different user and mode for all of the files / directories:

mount -o uid=userid,gid=groupid,dmask=022,fmask=133 /path/to/disk /mnt 

This will mount with specified user and group giving directories mode 755 and files mode 644.

1
  • Thanks, I solved mounting the disk on fstab with this options: UUID=XXXXXXX /mnt/shared ntfs-3g defaults,noatime,uid=1000,gid=users,dmask=022,fmask=133 0 0
    – Santiago
    Aug 17 '20 at 8:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.