LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   sudo write denied to remote file system mounted with sshfs ubuntu 13.04 (https://www.linuxquestions.org/questions/linux-general-1/sudo-write-denied-to-remote-file-system-mounted-with-sshfs-ubuntu-13-04-a-4175464539/)

franjo124 06-03-2013 04:58 AM

sudo write denied to remote file system mounted with sshfs ubuntu 13.04
 
Hi
I'm using Ubuntu 13.04 (raring ringtail) and wish to make backup of my system using Simple Backup. For backup target I desided to use My Book Live Duo (Western Digital).
Mounting disk system is success using

sshfs root@xxx.xxx.xxx.xxx:/DataVolume/shares/MyUser /var/backup

Problem :
As user I can read and write the mont point.
touch /var/backup/xxx - OK
but
sudo touch /var/backup/xxx == PERMISSION DENIED

Simple Backup software uses this command to start :
gksu --description /usr/share/applications/sbackup-config-su.desktop /usr/bin/sbackup-config-gtk
and returns some strange errors
"Unable to create directory for testing purpose: Directory already exists." ==> /var/backup is mount point or soft link to /mnt/backup
or
"The specified target directory /var/backup was not found" if I remove soft link or do umount /var/backup.
It works fine with phisical directory /var/backup

Thanks

michaelk 06-03-2013 09:37 AM

By default only the user has read/write permissions. You can use the options allow_other or allow_root to allow others access along with the option default_permissions which will enable permission checking by the kernel.

franjo124 06-04-2013 02:14 AM

Quote:

Originally Posted by michaelk (Post 4964605)
By default only the user has read/write permissions. You can use the options allow_other or allow_root to allow others access along with the option default_permissions which will enable permission checking by the kernel.

I'm not working with SELinux (I read somewhere that MBL works on SELinux Debian) - never had to - I'm familiar with old fashion permissions with chmod. So I would appreciate more descriptiveness ...

Thanks

michaelk 06-04-2013 08:47 AM

In a nutshell sshfs creates a virtual file system that works via the SSH sftp protocol.

I also forgot to mention that you need to add user_allow_other to the /etc/fuse.conf file if not already included. The command to allow others to access the filesystem use the following:

sshfs -o allow_other,default_permissions user@server /mount_point

However from the FAQs. "Generally it's not possible to use an sshfs mount as a "real" filesystem shared between multiple users. Some of this functionality can be enabled with the -o allow_other and -o default_permissions options, but files will not be created with the correct ownership, etc... "

http://sourceforge.net/apps/mediawik...title=SshfsFaq

Also see options for sshfs
http://linux.die.net/man/1/sshfs

franjo124 06-12-2013 01:27 AM

Michaelk

You are very kind and I'm grateful for your help. I can use MyBookLive as backup target. Thanks again!

Regards and all good on this world to you

Franjo124


All times are GMT -5. The time now is 02:29 PM.