Re: mounting NFS directory with read write access

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Reindl Harald wrote:


Am 27.02.2013 22:01, schrieb Ranjan Maitra:
On Wed, 27 Feb 2013 16:17:56 -0430 Patrick O'Callaghan
<pocallaghan@xxxxxxxxx> wrote:

On Wed, 2013-02-27 at 21:30 +0100, Reindl Harald wrote:

Am 27.02.2013 21:24, schrieb Patrick O'Callaghan:
As a user:
    man sshfs

AFAIK sshfs is not installed by default, so "yum install fuse-sshfs"
would be a prerequisite.

Also, the NFS server need not necessarily support ssh, and even if it
does the user would need to have a login account. Some dedicated NFS
servers have restricted access in that sense

the user does NOT need a login-session for sshfs/scp/sftp
100% for sure his does not, my boss has "/sbin/nologin" as
shell and sftp access with WinSCP like any other sftp/scp client

I didn't say he needed a login session. I said he needed a login
*account*, i.e. a passwd entry that assigns him a UID. Unless of course
the server allows unauthenticated connections, but nothing in the OP's
description implies that (or even that the server is running sshd at
all).

Hi,

I do have login access as an user, and the server does allow ssh in. I
just wanted to be able to mount the directory

yum install fuse-sshfs

/etc/fstab (ONE LINE! example, mount-point needs to be created before)
sshfs#harry@testserver:/www-servers  /mnt/testserver  fuse  noauto,user,rw,noexec,nosuid,nodev,uid=harry,gid=users
su -
mkdir /mnt/testserver
chown harry /mnt/testserver
exit

"mount /mnt/testserver" as user NOT as root
only you are able to see the moint-points content, even not root
and if you are using ssh-keys they are also used here

There are many ways to approach this if the server admin is clever (and we all are, right? ;-) )

There is a command=xxx feature in the authorized-keys file, which allows chroot, or just chdir depending on what you are doing. The command passed to the connect is available in the command as ${SSH_ORIGINAL_COMMAND} and best of all there is no need for a login account, user connects to a single id using a key which can be removed at any time, server has 100% control without creating logins. I use that for backups, client can use any backup program, encrypted if they wish, it gets saved in a file named at the server's choosing, and the filename is returned when the backup is complete. Also allows limiting the file size if you wish.

As noted sshd supports chroot as well, if you like that better.

--
Bill Davidsen <davidsen@xxxxxxx>
  "We have more to fear from the bungling of the incompetent than from
the machinations of the wicked."  - from Slashdot
--
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
Have a question? Ask away: http://ask.fedoraproject.org


[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux