mouting CentOS8 server folder via sshfs - where is package sshfs fuse?

Issues related to applications and software problems and general support
Post Reply
User avatar
canoodler
Posts: 4
Joined: 2021/02/17 19:14:42

mouting CentOS8 server folder via sshfs - where is package sshfs fuse?

Post by canoodler » 2021/02/17 20:11:18

Greetings,

CentOS has proven to be a pretty good server OS (using it as a storage server running 2x RAID1 (ext4))

so far so good

one fine day wanted to mount via sshfs fuse but to no avail

imho sshfs fuse does not need to be installed on server right? (unable to find it sshfs fuse on CentOS8)

Code: Select all

192.168.0.222 = client (GNU Debian 10, sshfs installed)

sshfs --version
SSHFS version 2.10.0
FUSE library version: 2.9.9
fusermount version: 2.9.9
using FUSE kernel interface version 7.19

192.168.0.205 = server
hostnamectl
   Static hostname: storagepc.centos
         Icon name: computer-desktop
  Operating System: CentOS Linux 8
       CPE OS Name: cpe:/o:centos:centos:8
            Kernel: Linux 4.18.0-240.10.1.el8_3.x86_64
      Architecture: x86-64

dnf search sshfs;  # in what repo do thou hide?
Last metadata expiration check: 1:40:24 ago on Wed 17 Feb 2021 01:17:56 PM EST.
No matches found

# sounds like a SELinux config problem?

... ok figured it out

# this works
sshfs -o allow_other,default_permissions root@ip.of.server.ssh:/mount/this/folder /media/user/sshfs

# can mount as root an non-root, is there any difference? :)

# this not so much
sshfs user@ip.of.server.ssh:/mount/this/folder/ /media/user/sshfs/ -o allow_other -o idmap=user -o uid=1000 -o gid=1000

# produced this error
==> /var/log/audit/audit.log <==
type=CRYPTO_KEY_USER msg=audit(1613591662.109:157): pid=16040 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:fe:1a:0a:ea:ff:52:29:e6:26:5e:0c:5e:de:93:db:e8:9d:5d:67:cc:25:65:27:21:c8:2f:16:11:d3:4d:44:86 direction=? spid=16040 suid=0  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="root"
type=CRYPTO_KEY_USER msg=audit(1613591662.109:158): pid=16040 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:59:4a:cd:9f:29:da:f3:60:6b:a6:d3:f5:12:98:89:a3:7c:c5:81:00:c8:3e:2c:0a:8a:13:3f:6e:d2:a5:b7:7d direction=? spid=16040 suid=0  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="root"
type=CRYPTO_KEY_USER msg=audit(1613591662.109:159): pid=16040 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:86:95:54:c7:a9:50:4b:f8:40:16:bb:61:c1:35:41:bc:95:d3:31:fb:9e:01:b7:90:b0:9a:f8:69:8c:79:10:57 direction=? spid=16040 suid=0  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="root"
type=CRYPTO_SESSION msg=audit(1613591662.110:160): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=start direction=from-server cipher=chacha20-poly1305@openssh.com ksize=512 mac=<implicit> pfs=curve25519-sha256 spid=16040 suid=74 rport=46822 laddr=192.168.0.205 lport=22  exe="/usr/sbin/sshd" hostname=? addr=192.168.0.222 terminal=? res=success'UID="root" AUID="unset" SUID="sshd"
type=CRYPTO_SESSION msg=audit(1613591662.110:161): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=start direction=from-client cipher=chacha20-poly1305@openssh.com ksize=512 mac=<implicit> pfs=curve25519-sha256 spid=16040 suid=74 rport=46822 laddr=192.168.0.205 lport=22  exe="/usr/sbin/sshd" hostname=? addr=192.168.0.222 terminal=? res=success'UID="root" AUID="unset" SUID="sshd"
type=CRYPTO_KEY_USER msg=audit(1613591662.126:162): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=session fp=? direction=both spid=16040 suid=74 rport=46822 laddr=192.168.0.205 lport=22  exe="/usr/sbin/sshd" hostname=? addr=192.168.0.222 terminal=? res=success'UID="root" AUID="unset" SUID="sshd"
type=CRYPTO_KEY_USER msg=audit(1613591662.126:163): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:86:95:54:c7:a9:50:4b:f8:40:16:bb:61:c1:35:41:bc:95:d3:31:fb:9e:01:b7:90:b0:9a:f8:69:8c:79:10:57 direction=? spid=16040 suid=74  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="sshd"
type=CRYPTO_KEY_USER msg=audit(1613591662.126:164): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:fe:1a:0a:ea:ff:52:29:e6:26:5e:0c:5e:de:93:db:e8:9d:5d:67:cc:25:65:27:21:c8:2f:16:11:d3:4d:44:86 direction=? spid=16039 suid=0  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="root"
type=CRYPTO_KEY_USER msg=audit(1613591662.126:165): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:59:4a:cd:9f:29:da:f3:60:6b:a6:d3:f5:12:98:89:a3:7c:c5:81:00:c8:3e:2c:0a:8a:13:3f:6e:d2:a5:b7:7d direction=? spid=16039 suid=0  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="root"
type=CRYPTO_KEY_USER msg=audit(1613591662.126:166): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=destroy kind=server fp=SHA256:86:95:54:c7:a9:50:4b:f8:40:16:bb:61:c1:35:41:bc:95:d3:31:fb:9e:01:b7:90:b0:9a:f8:69:8c:79:10:57 direction=? spid=16039 suid=0  exe="/usr/sbin/sshd" hostname=? addr=? terminal=? res=success'UID="root" AUID="unset" SUID="root"
type=USER_LOGIN msg=audit(1613591662.126:167): pid=16039 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:sshd_t:s0-s0:c0.c1023 msg='op=login acct="(unknown)" exe="/usr/sbin/sshd" hostname=? addr=192.168.0.222 terminal=ssh res=failed'UID="root" AUID="unset"

==> /var/log/secure <==
Feb 17 14:54:22 storagepc sshd[16039]: Connection closed by 192.168.0.222 port 46822 [preauth]

scottro
Forum Moderator
Posts: 2481
Joined: 2007/09/03 21:18:09
Location: NYC
Contact:

Re: mouting CentOS8 server folder via sshfs - where is package sshfs fuse?

Post by scottro » 2021/02/17 21:35:37

It seems to be in the base system. (That doesn't mean it's installed, depending upon what you chose, just that the base repo has it, as opposed to adding epel and so on.)

It's called fuse-sshfs. Not sure if you searched for it, (maybe not if you expected it to be there) :), but if you do dnf search fuse|grep ssh it pops right up. But you don't have to search now that we know it's name.

Code: Select all

dnf install fuse-sshfs
New users should check the FAQ and Read Me First pages

User avatar
TrevorH
Forum Moderator
Posts: 30344
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: mouting CentOS8 server folder via sshfs - where is package sshfs fuse?

Post by TrevorH » 2021/02/18 13:24:33

Both yum and its replacement dnf are rubbish at searching. You get far better results most of the time by using list, e.g.:

dnf list \*sshfs\*

The package you're looking for is in the powertools repo which is disabled by default.

As far as I know, sshfs has no requirements other than that ssh be installed on the target system (the one whose filesystem you want access to remotely). You will get access to whatever the user has access to that you use to connect to the other system. If that user doesn't have access then you won't be able to get at the file(s) remotely.
CentOS 6 died in November 2020 - migrate to a new version!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

User avatar
canoodler
Posts: 4
Joined: 2021/02/17 19:14:42

Re: mouting CentOS8 server folder via sshfs - where is package sshfs fuse?

Post by canoodler » 2021/02/21 21:38:50

thanks for your support :)

have a good time :)

User avatar
canoodler
Posts: 4
Joined: 2021/02/17 19:14:42

Re: mouting CentOS8 server folder via sshfs - where is package sshfs fuse?

Post by canoodler » 2021/02/24 17:48:15

Code: Select all

# edit this config
vim /etc/yum.repos.d/CentOS-Linux-PowerTools.repo
enabled=0 -> 1

# write & quit

# perform package def update
yum update

# there it is :)
dnf list \*sshfs\*
Last metadata expiration check: 0:00:13 ago on Wed 24 Feb 2021 12:46:49 PM EST.
Available Packages
fuse-sshfs.x86_64                                                   2.8-5.el8                                                    powertools
thanks all involved :)

Post Reply

Return to “CentOS 8 - General Support”