You are not logged in.

#1 2014-12-13 21:34:17

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Is not possible to change permissions in a file on usb hard disk

Hi, I'm usign my usb portable hard disk: WD My Passport 1TB USB3. The filesystem is ntfs. The mount option that appear is:

/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)
[elrengo@xpsl421x]$ lsblk -f
NAME   FSTYPE LABEL       UUID                                 MOUNTPOINT
sda                                                            
├─sda1 ext4               8623f268-98d1-409b-8fc4-4bb73c4709db /var
├─sda2 ext4               623eb04a-d981-4502-8586-ea41ab7f0eef /tmp
├─sda3 ext4               0d7f98dd-bcdd-4f1e-889a-ce908ef144d7 /home
└─sda4 swap               fe05fa65-d758-4734-a4ae-7d21a728f6cb [SWAP]
sdb                                                            
├─sdb1 vfat               6B94-E09B                            /boot
└─sdb2 ext4               7e22c7fa-4282-4b70-9c6b-5da8185501bb /
sdc                                                            
└─sdc1 ntfs   My Passport 4E1AEA7B1AEA6007                     /run/media/elrengo/My Passport

It's the automount when the disk is connected at the system.

In windows I can not execute the setup.exe, but when I go to file system to change the permission the file can not change the permission.

[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ ls -l
total 1,4M
drwx------ 1 elrengo users 4,0K sep 19 09:01 Access.en-us
-rw------- 1 elrengo users  175 mar 13  2011 autorun.inf
drwx------ 1 elrengo users    0 sep 19 09:01 Catalog
drwx------ 1 elrengo users    0 sep 19 09:01 Excel.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Groove.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 InfoPath.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office32.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 OneNote.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Outlook.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 PowerPoint.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 Proofing.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:03 ProPlusr.WW
drwx------ 1 elrengo users 4,0K sep 19 09:03 Publisher.en-us
-rw------- 1 elrengo users 1,9K jun 18  2010 README.HTM
-rw------- 1 elrengo users 1,4M jun  5  2010 setup.exe
drwx------ 1 elrengo users 4,0K sep 19 09:04 Updates
drwx------ 1 elrengo users    0 sep 19 09:04 Word.en-us
[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ chmod 700 setup.exe 
[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ ls -l
total 1,4M
drwx------ 1 elrengo users 4,0K sep 19 09:01 Access.en-us
-rw------- 1 elrengo users  175 mar 13  2011 autorun.inf
drwx------ 1 elrengo users    0 sep 19 09:01 Catalog
drwx------ 1 elrengo users    0 sep 19 09:01 Excel.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Groove.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 InfoPath.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office32.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 OneNote.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Outlook.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 PowerPoint.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 Proofing.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:03 ProPlusr.WW
drwx------ 1 elrengo users 4,0K sep 19 09:03 Publisher.en-us
-rw------- 1 elrengo users 1,9K jun 18  2010 README.HTM
-rw------- 1 elrengo users 1,4M jun  5  2010 setup.exe
drwx------ 1 elrengo users 4,0K sep 19 09:04 Updates
drwx------ 1 elrengo users    0 sep 19 09:04 Word.en-us
[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ chmod 700 ./setup.exe 
[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ ls -l
total 1,4M
drwx------ 1 elrengo users 4,0K sep 19 09:01 Access.en-us
-rw------- 1 elrengo users  175 mar 13  2011 autorun.inf
drwx------ 1 elrengo users    0 sep 19 09:01 Catalog
drwx------ 1 elrengo users    0 sep 19 09:01 Excel.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Groove.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 InfoPath.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office32.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 OneNote.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Outlook.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 PowerPoint.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 Proofing.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:03 ProPlusr.WW
drwx------ 1 elrengo users 4,0K sep 19 09:03 Publisher.en-us
-rw------- 1 elrengo users 1,9K jun 18  2010 README.HTM
-rw------- 1 elrengo users 1,4M jun  5  2010 setup.exe
drwx------ 1 elrengo users 4,0K sep 19 09:04 Updates
drwx------ 1 elrengo users    0 sep 19 09:04 Word.en-us
[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ chmod +x setup.exe 
[/run/media/elrengo/My Passport/Software/Productos/Microsoft/En Office Pro Plus SP1 2010 x64  y x86/x64]
[elrengo@xpsl421x]$ ls -l
total 1,4M
drwx------ 1 elrengo users 4,0K sep 19 09:01 Access.en-us
-rw------- 1 elrengo users  175 mar 13  2011 autorun.inf
drwx------ 1 elrengo users    0 sep 19 09:01 Catalog
drwx------ 1 elrengo users    0 sep 19 09:01 Excel.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Groove.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 InfoPath.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office32.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Office.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 OneNote.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:01 Outlook.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 PowerPoint.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:02 Proofing.en-us
drwx------ 1 elrengo users 4,0K sep 19 09:03 ProPlusr.WW
drwx------ 1 elrengo users 4,0K sep 19 09:03 Publisher.en-us
-rw------- 1 elrengo users 1,9K jun 18  2010 README.HTM
-rw------- 1 elrengo users 1,4M jun  5  2010 setup.exe
drwx------ 1 elrengo users 4,0K sep 19 09:04 Updates
drwx------ 1 elrengo users    0 sep 19 09:04 Word.en-us

How I can change the permision?
Thanks!

elrengo

Offline

#2 2014-12-13 22:07:37

clfarron4
Member
From: London, UK
Registered: 2013-06-28
Posts: 2,170
Website

Re: Is not possible to change permissions in a file on usb hard disk

NTFS doesn't recognise UNIX permissions.

You'll have to change the permissions in Windows as an administrator user.


Claire is fine.
Problems? I have dysgraphia, so clear and concise please.
My public GPG key for package signing
My x86_64 package repository

Offline

#3 2014-12-13 22:19:51

Head_on_a_Stick
Member
From: The Wirral
Registered: 2014-02-20
Posts: 8,999
Website

Re: Is not possible to change permissions in a file on usb hard disk

ArchWiki wrote:

The build in support of the NTFS file systems by the kernel is read-only even if read-write is activated by an option.

https://wiki.archlinux.org/index.php/Mount#NTFS

Have you seen the NTFS-3G package?
https://wiki.archlinux.org/index.php/Nt … ermissions


Jin, Jîyan, Azadî

Offline

#4 2014-12-13 22:58:35

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

I installed ntfs-3g. I'm reading the links. I after read and try came back!
Thanks!

Offline

#5 2014-12-14 06:27:27

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

I have installed ntfs-3g. The ntfs-3g create the symlink that describe the wiki:

elrengo@xpsl421x]$ ls -l /usr/bin/mount.nt*
lrwxrwxrwx 1 root root 16 feb 25  2014 /usr/bin/mount.ntfs -> /usr/bin/ntfs-3g
lrwxrwxrwx 1 root root 16 feb 25  2014 /usr/bin/mount.ntfs-3g -> /usr/bin/ntfs-3g

and is activated in kernel:

[elrengo@xpsl421x]$ zgrep ^CONFIG_NTFS  /proc/config.gz
CONFIG_NTFS_FS=m
CONFIG_NTFS_RW=y

I installed ntfs-config but allways add a line in /etc/fstab and crash. Do not permit allow write with external. I have not attached the usb disk all time, and in boot is requiered to have the usb disk connected.

Offline

#6 2014-12-14 06:30:59

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: Is not possible to change permissions in a file on usb hard disk

Why are your fstab options in parentheses?


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#7 2014-12-14 12:23:07

rebootl
Member
Registered: 2012-01-10
Posts: 431
Website

Re: Is not possible to change permissions in a file on usb hard disk

I installed ntfs-config but allways add a line in /etc/fstab and crash. Do not permit allow write with external. I have not attached the usb disk all time, and in boot is requiered to have the usb disk connected.

I'm not sure I understand what you mean. But you can use noauto to prevent automatic mounting at boot: https://wiki.archlinux.org/index.php/Nt … 3G_options
Write the fstab entry "by hand" ? There are quite a few examples in the wiki.

Still, I'm not sure if it's even possible to change the permissions, as clfarron4 pointed out...

Why are your fstab options in parentheses?

Because that's the output of 'mount' ?


Personal website: reboot.li
GitHub: github.com/rebootl

Offline

#8 2014-12-14 12:34:23

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,019

Re: Is not possible to change permissions in a file on usb hard disk

Try "mount -o remount,umask=700 /dev/sdc1" (if you're using ntfs-3g; the mount line in your first post suggested that you were using ntfs-3g).

Offline

#9 2014-12-15 09:53:07

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Hi! I'm back after read something, our best friend Arch Wiki and Google, and some test performed.

First, I reamplaced the ntfs-3g packages from official repositories for ntfs3g-fuse from AUR repositories.

archwiki wrote:

Allowing user to mount
By default, ntfs-3g requires root rights to mount the filesystem, even with the "user" option in /etc/fstab, the reason why can be found here.

First, check that you have access to the mount block you want to use.

You also need acces right to the mount point you want to use, since we're going to mount something as user on this mountpoint, we might as well own it:

Second is having a NTFS-3G driver compiled with integrated FUSE support, the ntfs-3g package from the official repositories does not, but there is one ntfs-3g-fuse on AUR.

You should now be able to mount your NTFS partition without root rights.

1. It's OK.
2. I think it's OK. The system auto mount the usb hard disk in "/run/media/user/mntpoint/" where if the device is not connected the path not exist. But when the device is connected the path is created. I can access to device mounted. Thinking in my self I do know if works but to create in that path the path to use for the usb: "/run/media/elrengo/My\ Passport/". If works I need to do this for ever usb device that use ntfs, this is not a easy method for the future.
3. It's OK.

mount output

/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)
[/dev]
[elrengo@xpsl421x]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=4025060k,nr_inodes=1006265,mode=755)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
/dev/sdb2 on / type ext4 (rw,relatime,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=22,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
mqueue on /dev/mqueue type mqueue (rw,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/sdb1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/sda2 on /tmp type ext4 (rw,relatime,data=ordered)
/dev/sda1 on /var type ext4 (rw,relatime,data=ordered)
/dev/sda3 on /home type ext4 (rw,relatime,data=ordered)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=805580k,mode=700,uid=1000,gid=100)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)
/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

About from ntfs-config. In the wiki indicate a package to configure ntfs-3g with GUI. I do not know the packege I think that could be a package can configure properly the ntfs-3g. After see the application,I think it does not is very helpful. Only detect the device that use ntfs and add a line in the fstab. nothing more. When is creating the line in fstab the gui crash but the fstab is modified.

If possible I would like to find a solution without modifiy fstab, because I have a lot of usb memorys and usb hard drives with ntfs. This devices I shared with my wife, she use Windows, and other I use in work workstation where again is used Winodws and I can not installed third party software (licenced or Open Source). sad

lucke wrote:

Try "mount -o remount,umask=700 /dev/sdc1" (if you're using ntfs-3g; the mount line in your first post suggested that you were using ntfs-3g).

/dev]
[elrengo@xpsl421x]$ sudo mount -o remount,umask=700 /dev/sdc1
[sudo] password for elrengo: 
[/dev]
[elrengo@xpsl421x]$ cd /run/media/
[/run/media]
[elrengo@xpsl421x]$ ls -l
total 0
drwxr-x---+ 3 root root 60 dic 15 05:33 elrengo
[/run/media]
[elrengo@xpsl421x]$ cd elrengo/
[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
drwx------ 1 elrengo users 8,0K nov  4 14:51 My Passport
[/run/media/elrengo]
[elrengo@xpsl421x]$ cd My\ Passport/
[/run/media/elrengo/My Passport]
[elrengo@xpsl421x]$ ls -l
total 116M
drwx------ 1 elrengo users 4,0K nov  4 14:52 archlinux
drwx------ 1 elrengo users 4,0K sep 19 20:28 Backup
drwx------ 1 elrengo users 4,0K mar  8  2014 Cursos
drwx------ 1 elrengo users 4,0K dic  1 00:13 Documentos
drwx------ 1 elrengo users 4,0K sep 19 09:28 Extras
drwx------ 1 elrengo users 8,0K sep 19 20:26 Fotografia
drwx------ 1 elrengo users 4,0K oct 22 14:05 Juegos
drwx------ 1 elrengo users  64K sep 19 10:07 Libros
drwx------ 1 elrengo users  40K feb 19  2014 Manuales
-rw------- 1 elrengo users 639K jun  1  2010 MicrosoftFixit50446.msi
drwx------ 1 elrengo users 8,0K dic  1 00:20 Personal
-rw------- 2 elrengo users 111M sep 26 23:35 Pirates of the Caribbean-At World's End - [www.official-soundtracks.com].zip
drwx------ 1 elrengo users 4,0K ene 18  2014 Proyecto Cartas
drwx------ 1 elrengo users 4,0K sep  8 00:29 $RECYCLE.BIN
drwx------ 1 elrengo users 8,0K oct 22 14:03 Software
drwx------ 1 elrengo users 4,0K oct 14 00:21 System Volume Information
drwx------ 1 elrengo users 4,0K sep 19 10:07 thumbgen
drwx------ 1 elrengo users 4,0K jul 26  2012 User Manuals
drwx------ 1 elrengo users 4,0K abr 12  2012 WD Apps for Windows
-rw------- 2 elrengo users 4,1M dic 20  2011 WD Apps Setup.exe

Do not works! sad

Last edited by elrengo (2014-12-15 09:55:14)

Offline

#10 2014-12-15 10:04:13

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

I run the ntfs-config in terminal I can see because crash. Use /media as default to search and mount. Where arch uses /run/media.

[~]
[elrengo@xpsl421x]$ sudo ntfs-config
[sudo] password for elrengo: 
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 152, in on_ok_clicked
    self.disk.apply_now()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 472, in apply_now
    self._apply()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 451, in _apply
    clean_all_path()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Fstab.py", line 551, in clean_all_path
    for path in list_created_path() :
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Fstab.py", line 510, in list_created_path
    created_file = open(CREATED_PATH_FILE, "a+")
IOError: [Errno 2] No such file or directory: '/media/.created_by_python-fstab'
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 154, in on_ok_clicked
    self.disk.savelog()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 522, in savelog
    self._logconf.add_section(name)
  File "/usr/lib/python2.7/ConfigParser.py", line 260, in add_section
    if section.lower() == "default":
AttributeError: 'float' object has no attribute 'lower'
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 154, in on_ok_clicked
    self.disk.savelog()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 522, in savelog
    self._logconf.add_section(name)
  File "/usr/lib/python2.7/ConfigParser.py", line 260, in add_section
    if section.lower() == "default":
AttributeError: 'float' object has no attribute 'lower'
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 159, in on_auto_clicked
    self.auto_configure()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 168, in auto_configure
    self.disk.savelog()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 522, in savelog
    self._logconf.add_section(name)
  File "/usr/lib/python2.7/ConfigParser.py", line 260, in add_section
    if section.lower() == "default":
AttributeError: 'float' object has no attribute 'lower'
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 159, in on_auto_clicked
    self.auto_configure()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/AddWizard.py", line 168, in auto_configure
    self.disk.savelog()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 522, in savelog
    self._logconf.add_section(name)
  File "/usr/lib/python2.7/ConfigParser.py", line 260, in add_section
    if section.lower() == "default":
AttributeError: 'float' object has no attribute 'lower'
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/NtfsConfig/NtfsConfig.py", line 256, in on_writable_toggled
    self.set_internal_ntfs_policy([self.disk[self.tree_store[path][2]]], "rw")
  File "/usr/lib/python2.7/site-packages/NtfsConfig/NtfsConfig.py", line 230, in set_internal_ntfs_policy
    self.disk.set_mode("real")
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 218, in set_mode
    self.apply_now()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 472, in apply_now
    self._apply()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/FstabHandler.py", line 442, in _apply
    if self._mounter.do(mount = to_mount, umount = to_umount)[0] :
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Mounter.py", line 86, in do
    res_mount += self.mount_device(entry)
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Mounter.py", line 109, in mount_device
    ret = entry.mount()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Fstab.py", line 202, in mount
    self.make_path()
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Fstab.py", line 148, in make_path
    list_created_path("add", "/".join(path.split("/")[:i+2]))
  File "/usr/lib/python2.7/site-packages/NtfsConfig/Fstab/Fstab.py", line 510, in list_created_path
    created_file = open(CREATED_PATH_FILE, "a+")
IOError: [Errno 2] No such file or directory: '/media/.created_by_python-fstab'

That is the fstab modified by ntfs-3g:

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>

#Entry for /dev/sdb2 :
UUID=7e22c7fa-4282-4b70-9c6b-5da8185501bb	/	ext4	rw,relatime,data=ordered	0	1
#Entry for /dev/sdb1 :
UUID=6B94-E09B	/boot	vfat	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro	0	2
#Entry for /dev/sda3 :
UUID=0d7f98dd-bcdd-4f1e-889a-ce908ef144d7	/home	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sdc1 :
UUID=4E1AEA7B1AEA6007	/run/media/elrengo/My\040Passport	ntfs-3g	defaults,nodev,nosuid,locale=en_US.UTF-8	0	0
#Entry for /dev/sda2 :
UUID=623eb04a-d981-4502-8586-ea41ab7f0eef	/tmp	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sda1 :
UUID=8623f268-98d1-409b-8fc4-4bb73c4709db	/var	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sda4 :
UUID=fe05fa65-d758-4734-a4ae-7d21a728f6cb	none	swap	defaults	0	0

Last edited by elrengo (2014-12-15 10:06:57)

Offline

#11 2014-12-15 16:35:28

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,019

Re: Is not possible to change permissions in a file on usb hard disk

What if you put "umask=700,uid=elrengo,gid=users" in options in fstab (you can remove "defaults")?

Offline

#12 2014-12-15 18:48:20

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

I'm not in my machine at this time. But I think that I need to add noauto too? That for no mounting at system startup.

But it´s solve only for my passport, the usb storage that I use to test. but I need to add for all the usb stores that I have and when someone share him usb I'm in troubles...

thanks for your repluy

Last edited by elrengo (2014-12-15 18:48:37)

Offline

#13 2014-12-16 03:22:56

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

I try again. When I connect the disk it connect but with no permision for my user:

[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
d---rwxrwx 1 elrengo users 8,0K nov  4 14:51 My Passport

/etc/fstab

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>

#SSD

#Entry for /dev/sdb2 :
UUID=7e22c7fa-4282-4b70-9c6b-5da8185501bb	/	ext4	rw,relatime,data=ordered	0	1
#Entry for /dev/sdb1 :
UUID=6B94-E09B	/boot	vfat	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro	0	2
#Entry for /dev/sda3 :
UUID=0d7f98dd-bcdd-4f1e-889a-ce908ef144d7	/home	ext4	rw,relatime,data=ordered	0	2

#HHD

#Entry for /dev/sda2 :
UUID=623eb04a-d981-4502-8586-ea41ab7f0eef	/tmp	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sda1 :
UUID=8623f268-98d1-409b-8fc4-4bb73c4709db	/var	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sda4 :
UUID=fe05fa65-d758-4734-a4ae-7d21a728f6cb	none	swap	defaults	0	0

#USB

#Entry for /dev/sdc1 :
UUID=4E1AEA7B1AEA6007	/run/media/elrengo/My\040Passport	ntfs-3g	umask=700,uid=elrengo,gid=users,nodev,nosuid,noauto,sync,locale=en_US.UTF-8	0	0

I also try with this line:

#Entry for /dev/sdc1 :
UUID=4E1AEA7B1AEA6007	/run/media/elrengo/My\040Passport	ntfs-3g	umask=700,uid=elrengo,gid=users,nodev,nosuid,noauto,sync,rw,exec,locale=en_US.UTF-8	0	0

I have the same result. sad This issue has broken my head!!! :'(
Thanks in advance to all!! smile

Offline

#14 2014-12-16 09:14:51

dice
Member
From: Germany
Registered: 2014-02-10
Posts: 413

Re: Is not possible to change permissions in a file on usb hard disk

I would like to help but I don't understand what you are trying to do. Do you want to change the permissions for the partition to get write acces from linux or do you try to modify the ntfs permissions so that they are changed when you use the disk with windows?
Or is it even something else?


I put at button on it. Yes. I wish to press it, but I'm not sure what will happen if I do.  (Gune | Titan A.E.)

Offline

#15 2014-12-16 09:24:48

lucke
Member
From: Poland
Registered: 2004-11-30
Posts: 4,019

Re: Is not possible to change permissions in a file on usb hard disk

Sorry, it should be umask=077, not 700.

Offline

#16 2014-12-16 12:37:28

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

dice wrote:

I would like to help but I don't understand what you are trying to do. Do you want to change the permissions for the partition to get write acces from linux or do you try to modify the ntfs permissions so that they are changed when you use the disk with windows?
Or is it even something else?

Hi! I connect a usb hard disk with ntfs filesystem to my ultrabook. At the first moment I only use that hard disk to restore backup, at this moment the usb is only use for read and no have issue.

When I install some software in my Windows VM, I found that the archlinux automount for usb only mount the device to read only and can not exceute files and I can not install software from USB in Windows. How is mounted the device by default I can not change the permission of the files in filesystem, I try but I can not. After that I would like to config the archlinux to mount usb hard drive with ntfs with read write and excute but I can not. Is the objective of the thread.

How my laptop is a ultrabook and have not CD/DVD the only method for share is Internet or USB device. The 70% use ntfs filesystems 20% fat filesystem 10% unix file systems if is used. I would like auto mount for that devices will be auto for read, write and execute. In my Windows VM or in Linux.

Offline

#17 2014-12-16 21:07:18

dice
Member
From: Germany
Registered: 2014-02-10
Posts: 413

Re: Is not possible to change permissions in a file on usb hard disk

Ah, okay! Thanks for the clarification.
When I mount a ntfs partition (using udiskie, or nemos mount function which uses udisks2) my mount options shown by mount command look exactly like the one in your first post. I can write to that partition.
Did you even try to create a simple file from linux on that partition? If that works the problem with windows could be related to the sharing with the virtual machine.
What software do you use for VM? VirtualBox?

So please delete(or comment out) the lines you added to fstab regarding this ntfs partition.  Mount that partition (which tool are you using to mount it?).
Try to create a file on the root of the device (for example /run/media/elrengo/My Passport/test)
Also the output of

ls -l /run/media/elrengo

could give some hints. If it shows that you don't have write permissions try (maybe as root)

chmod +w /run/media/elrengo/My Passport

And just to be sure again the output of

 mount

when mounted without any additional config


I put at button on it. Yes. I wish to press it, but I'm not sure what will happen if I do.  (Gune | Titan A.E.)

Offline

#18 2014-12-17 00:55:53

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Thanks for you reply!! I have good news! smile

At first time I use to run my Windows 7 VM on KVM with QEMU. I was a IBMer, IBM have it's own Linux Distro based on RHEL named OpenClient and exist a Windows VM for KVM optimised that works great for task that is needed run in Windows. I use this Windows VM to do that task because the optimizarion is really good.

Return with the thread, I comment the line in fstab and restart the system. The mount command output is:

[/etc/udev/rules.d]
[elrengo@xpsl421x]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=4025060k,nr_inodes=1006265,mode=755)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
/dev/sdb2 on / type ext4 (rw,relatime,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=22,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/sdb1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/sda1 on /var type ext4 (rw,relatime,data=ordered)
/dev/sda2 on /tmp type ext4 (rw,relatime,data=ordered)
/dev/sda3 on /home type ext4 (rw,relatime,data=ordered)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=805580k,mode=700,uid=1000,gid=100)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)
/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

After that I in Thunar I created a folder and copy other folder with some files then I delete all files and folders with out issues. Works great. The files are in the disk, but if I see the permission in Linux still shows read only.

[/run/media/elrengo]
[elrengo@xpsl421x]$ cd /run/media/
[/run/media]
[elrengo@xpsl421x]$ ls -l
total 0
drwxr-x---+ 3 root root 60 dic 16 20:41 elrengo
[/run/media]
[elrengo@xpsl421x]$ cd elrengo/
[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
drwx------ 1 elrengo users 8,0K dic 16 20:41 My Passport
[/run/media/elrengo]
[elrengo@xpsl421x]$ cd My\ Passport/
[/run/media/elrengo/My Passport]
[elrengo@xpsl421x]$ ls -l
total 116M
drwx------ 1 elrengo users 4,0K nov  4 14:52 archlinux
drwx------ 1 elrengo users 4,0K sep 19 20:28 Backup
drwx------ 1 elrengo users 4,0K mar  8  2014 Cursos
drwx------ 1 elrengo users 4,0K dic  1 00:13 Documentos
drwx------ 1 elrengo users 4,0K sep 19 09:28 Extras
drwx------ 1 elrengo users 8,0K sep 19 20:26 Fotografia
drwx------ 1 elrengo users 4,0K oct 22 14:05 Juegos
drwx------ 1 elrengo users  64K sep 19 10:07 Libros
drwx------ 1 elrengo users  40K feb 19  2014 Manuales
-rw------- 1 elrengo users 639K jun  1  2010 MicrosoftFixit50446.msi
drwx------ 1 elrengo users  144 dic 16 20:41 New Folder
drwx------ 1 elrengo users 8,0K dic  1 00:20 Personal
-rw------- 2 elrengo users 111M sep 26 23:35 Pirates of the Caribbean-At World's End - [www.official-soundtracks.com].zip
drwx------ 1 elrengo users 4,0K ene 18  2014 Proyecto Cartas
drwx------ 1 elrengo users 4,0K sep  8 00:29 $RECYCLE.BIN
drwx------ 1 elrengo users 8,0K oct 22 14:03 Software
drwx------ 1 elrengo users 4,0K oct 14 00:21 System Volume Information
drwx------ 1 elrengo users 4,0K sep 19 10:07 thumbgen
drwx------ 1 elrengo users 4,0K jul 26  2012 User Manuals
drwx------ 1 elrengo users 4,0K abr 12  2012 WD Apps for Windows
-rw------- 2 elrengo users 4,1M dic 20  2011 WD Apps Setup.exe

After that I ran:

chmod +w /run/media/elrengo/My Passport

but not change:

[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
drwx------ 1 elrengo users 8,0K dic 16 20:41 My Passport
[/run/media/elrengo]
[elrengo@xpsl421x]$ chmod +w /run/media/elrengo/My\ Passport/
[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
drwx------ 1 elrengo users 8,0K dic 16 20:41 My Passport
[/run/media/elrengo]
[elrengo@xpsl421x]$ sudo chmod +w /run/media/elrengo/My\ Passport/
[sudo] password for elrengo: 
[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
drwx------ 1 elrengo users 8,0K dic 16 20:41 My Passport

I do not know how but in Linux I can write than if the permission show the opposite. But the Windows can not have access to the device. I have the device shared in samba.

Offline

#19 2014-12-17 01:44:12

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Now I can try using the fstab config:

[/run/media/elrengo/My Passport]
[elrengo@xpsl421x]$ cat /etc/fstab
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>

#SSD

#Entry for /dev/sdb2 :
UUID=7e22c7fa-4282-4b70-9c6b-5da8185501bb	/	ext4	rw,relatime,data=ordered	0	1
#Entry for /dev/sdb1 :
UUID=6B94-E09B	/boot	vfat	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro	0	2
#Entry for /dev/sda3 :
UUID=0d7f98dd-bcdd-4f1e-889a-ce908ef144d7	/home	ext4	rw,relatime,data=ordered	0	2

#HHD

#Entry for /dev/sda2 :
UUID=623eb04a-d981-4502-8586-ea41ab7f0eef	/tmp	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sda1 :
UUID=8623f268-98d1-409b-8fc4-4bb73c4709db	/var	ext4	rw,relatime,data=ordered	0	2
#Entry for /dev/sda4 :
UUID=fe05fa65-d758-4734-a4ae-7d21a728f6cb	none	swap	defaults	0	0

#USB

#Entry for /dev/sdc1 :
UUID=4E1AEA7B1AEA6007	/run/media/elrengo/My\040Passport	ntfs-3g	umask=077,uid=elrengo,gid=users,nodev,nosuid,noauto,sync,locale=en_US.UTF-8	0	0

The mount output

[/run/media/elrengo/My Passport]
[elrengo@xpsl421x]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=4025060k,nr_inodes=1006265,mode=755)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
/dev/sdb2 on / type ext4 (rw,relatime,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=22,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
mqueue on /dev/mqueue type mqueue (rw,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/sdb1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/sda1 on /var type ext4 (rw,relatime,data=ordered)
/dev/sda2 on /tmp type ext4 (rw,relatime,data=ordered)
/dev/sda3 on /home type ext4 (rw,relatime,data=ordered)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=805580k,mode=700,uid=1000,gid=100)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)
/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,sync,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096)

How the system show the permission:

/run/media]
[elrengo@xpsl421x]$ ls -l
total 0
drwxr-xr-x 3 root root 60 dic 16 22:15 elrengo
[/run/media]
[elrengo@xpsl421x]$ cd elrengo/
[/run/media/elrengo]
[elrengo@xpsl421x]$ ls -l
total 8,0K
drwx------ 1 elrengo users 8,0K dic 16 21:53 My Passport
[/run/media/elrengo]
[elrengo@xpsl421x]$ cd My\ Passport/
[/run/media/elrengo/My Passport]
[elrengo@xpsl421x]$ ls -l
total 116M
drwx------ 1 elrengo users 4,0K nov  4 14:52 archlinux
drwx------ 1 elrengo users 4,0K sep 19 20:28 Backup
drwx------ 1 elrengo users 4,0K mar  8  2014 Cursos
drwx------ 1 elrengo users 4,0K dic  1 00:13 Documentos
drwx------ 1 elrengo users 4,0K sep 19 09:28 Extras
drwx------ 1 elrengo users 8,0K sep 19 20:26 Fotografia
drwx------ 1 elrengo users 4,0K oct 22 14:05 Juegos
drwx------ 1 elrengo users  64K sep 19 10:07 Libros
drwx------ 1 elrengo users  40K feb 19  2014 Manuales
-rwx------ 1 elrengo users 639K jun  1  2010 MicrosoftFixit50446.msi
drwx------ 1 elrengo users 8,0K dic  1 00:20 Personal
-rwx------ 2 elrengo users 111M sep 26 23:35 Pirates of the Caribbean-At World's End - [www.official-soundtracks.com].zip
drwx------ 1 elrengo users 4,0K ene 18  2014 Proyecto Cartas
drwx------ 1 elrengo users 4,0K sep  8 00:29 $RECYCLE.BIN
drwx------ 1 elrengo users 8,0K oct 22 14:03 Software
drwx------ 1 elrengo users 4,0K oct 14 00:21 System Volume Information
drwx------ 1 elrengo users 4,0K sep 19 10:07 thumbgen
drwx------ 1 elrengo users 4,0K jul 26  2012 User Manuals
drwx------ 1 elrengo users 4,0K abr 12  2012 WD Apps for Windows
-rwx------ 2 elrengo users 4,1M dic 20  2011 WD Apps Setup.exe

Have not change! And I can create the directory copy other subdirectory and then delete all information copy.

Offline

#20 2014-12-17 07:54:34

dice
Member
From: Germany
Registered: 2014-02-10
Posts: 413

Re: Is not possible to change permissions in a file on usb hard disk

-rwx------ 2 elrengo users 4,1M dic 20  2011 WD Apps Setup.exe

This means your actually have read,write and execute permissions on that file. And the fact that you can create folders and files shows that this is the case too


I put at button on it. Yes. I wish to press it, but I'm not sure what will happen if I do.  (Gune | Titan A.E.)

Offline

#21 2014-12-17 12:53:23

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Yes! But I need the fstab confing. I would like to have this result with out a fstab. The next usb disk I need to edit the fstan and restart the system. sad
I know I have issues with Samba config but It´s other topic.

Offline

#22 2014-12-17 13:19:01

dice
Member
From: Germany
Registered: 2014-02-10
Posts: 413

Re: Is not possible to change permissions in a file on usb hard disk

According to what you wrote in post #18 it worked without a config line in fstab


I put at button on it. Yes. I wish to press it, but I'm not sure what will happen if I do.  (Gune | Titan A.E.)

Offline

#23 2014-12-17 13:34:18

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Yes. I but still generated noise. But I need to try with execute. I try again to night in home. Its Works I mark the thread as solved. smile

PS: Congrats by the World Cup. tongue

Last edited by elrengo (2014-12-17 13:36:41)

Offline

#24 2014-12-22 13:48:43

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Hi!  I would like to know if is possible to change the path where Arch mount the usb sticks, camera, hard disk. "/run/media/user" to for example "/media" or "/home/user/media". I think my issues with Samba will be permission issues.

I friend recommend to use autofs in archwiki I found a udiskie? I simple to rempleace the automount used?

Thanks!

Offline

#25 2014-12-31 13:30:23

elrengo
Member
From: Argentina
Registered: 2014-11-06
Posts: 56

Re: Is not possible to change permissions in a file on usb hard disk

Hi! I solved the most samba issues, but one of then still unresolved. I can not run exe files in Windows when is shared with Samba. It's a permission issues. I know it.

I Linux I have not issues but in Samba continue, but samba conf its ok.

Looking for the isse I see as result of mount command when the usb is automount:

[~]
[elrengo@xpsl421x]$ mount
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=4025060k,nr_inodes=1006265,mode=755)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
/dev/sdb2 on / type ext4 (rw,relatime,data=ordered)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/cpuset type cgroup (rw,nosuid,nodev,noexec,relatime,cpuset)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/net_cls type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=22,pgrp=1,timeout=300,minproto=5,maxproto=5,direct)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
mqueue on /dev/mqueue type mqueue (rw,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,relatime)
configfs on /sys/kernel/config type configfs (rw,relatime)
/dev/sdb1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/sda1 on /var type ext4 (rw,relatime,data=ordered)
/dev/sda2 on /tmp type ext4 (rw,relatime,data=ordered)
/dev/sda3 on /home type ext4 (rw,relatime,data=ordered)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=805580k,mode=700,uid=1000,gid=100)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
gvfsd-fuse on /run/user/1000/gvfs type fuse.gvfsd-fuse (rw,nosuid,nodev,relatime,user_id=1000,group_id=100)
/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

I mark what I need to change for the automount:

/dev/sdc1 on /run/media/elrengo/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

I need to change:

* fuseblk for ntfs-3g
* user_id=0 for user_id=1000
* group_id=0 for group_id=100
* default_permissions

For default_permissions I do not know what options include and is the same that the defaults for ftab.

I try installing and config autofs, but not works. I need to change the config when the arch automount the usb. What file I need to edit to enable the change proposed?

Offline

Board footer

Powered by FluxBB