You are not logged in.

#1 2022-04-18 23:26:30

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 271
Website

SOLVED NFS in place of Samba

I am wondering if anyone else is using NFS instead of Samba on their home network. I have it up and running but it can be very slow to connect. I used NFS many years ago when I supported a Linux product and it was very fast. I can't say the same for my current setup which is running OpenZFS and the zfs-share service.

If you know how to get NFS running nicely on an OpenZFS system please share.

Last edited by lenhuppe (2022-04-22 14:07:52)


Why do we drive on the parkway and then park in the driveway?

Offline

#2 2022-04-19 06:26:36

seth
Member
Registered: 2012-09-03
Posts: 49,983

Re: SOLVED NFS in place of Samba

Are other exports (eg. from some tmpfs) fast?
If not, post the exports config of the server and the "mount | grep nfs" on the client.

Online

#3 2022-04-20 11:44:05

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 271
Website

Re: SOLVED NFS in place of Samba

seth wrote:

Are other exports (eg. from some tmpfs) fast?
If not, post the exports config of the server and the "mount | grep nfs" on the client.

I have no other shares and I am using the zfs-share service in place of the exports and fstab files. With this configuration I can use nautilus to mount the server and see my files so long as I give the client and server systems a minute or so to "find" each other. From what I can see there are no issues with tmpfs on either the client or server.

zfs get sharenfs (server)

NAME                PROPERTY  VALUE              SOURCE
zroot               sharenfs  off                default
zroot/DATA          sharenfs  off                default
zroot/DATA/archive  sharenfs  rw=192.168.1.0/24  local
zroot/DATA/home     sharenfs  off                default
zroot/DATA/root     sharenfs  off                default
zroot/DATA/tunes    sharenfs  off                default
zroot/ROOT          sharenfs  off                default
zroot/ROOT/default  sharenfs  off                default

cat /etc/exports (server)

# /etc/exports - exports(5) - directories exported to NFS clients
#
# Example for NFSv3:
#  /srv/home        hostname1(rw,sync) hostname2(ro,sync)
# Example for NFSv4:
#  /srv/nfs4	    hostname1(rw,sync,fsid=0)
#  /srv/nfs4/home   hostname1(rw,sync,nohide)
# Using Kerberos and integrity checking:
#  /srv/nfs4        *(rw,sync,sec=krb5i,fsid=0)
#  /srv/nfs4/home   *(rw,sync,sec=krb5i,nohide)
#
# Use `exportfs -arv` to reload.

cat /etc/fstab (server)

# Static information about the filesystems.
# See fstab(5) for details.

# <file system> <dir> <type> <options> <dump> <pass>
# zroot/ROOT/default
#zroot/ROOT/default  	/         	zfs       	rw,nodev,noatime,xattr,posixacl	0 0

# zroot/DATA/root
#zroot/DATA/root     	/root     	zfs       	rw,nodev,noatime,xattr,posixacl	0 0

# zroot/DATA/tunes
#zroot/DATA/tunes    	/tunes    	zfs       	rw,nodev,noatime,xattr,posixacl	0 0

# zroot/DATA/home
#zroot/DATA/home     	/home     	zfs       	rw,nodev,noatime,xattr,posixacl	0 0

# zroot/DATA/archive
#zroot/DATA/archive  	/archive  	zfs       	rw,nodev,noatime,xattr,posixacl	0 0

# /dev/nvme0n1p1 LABEL=EFI
UUID=8ECD-A513      	/boot     	vfat      	rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro	0 2

mount | grep nfs (client)

nfsd on /proc/fs/nfsd type nfsd (rw,relatime)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw,relatime)

Last edited by lenhuppe (2022-04-20 12:42:55)


Why do we drive on the parkway and then park in the driveway?

Offline

#4 2022-04-20 14:35:52

-thc
Member
Registered: 2017-03-15
Posts: 485

Re: SOLVED NFS in place of Samba

lenhuppe wrote:

I can use nautilus to mount the server and see my files so long as I give the client and server systems a minute or so to "find" each other.

How do you exactly achieve access to the NFS shares on your client? Normal NFS mount? NFS automount? GIO mount via gvfs-nfs? None of these?

Offline

#5 2022-04-20 17:46:59

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 271
Website

Re: SOLVED NFS in place of Samba

-thc wrote:
lenhuppe wrote:

I can use nautilus to mount the server and see my files so long as I give the client and server systems a minute or so to "find" each other.

How do you exactly achieve access to the NFS shares on your client? Normal NFS mount? NFS automount? GIO mount via gvfs-nfs? None of these?

I use the file manager nautilus which is called "Files" in Gnome Shell because it integrates well with my Dropbox account. It has a feature to add locations where I can enter nfs://host_name/share_name and it connects. However I sometimes have to wait or retry and I don't know the reason why. In addition to nautilus I also use ssh to connect. I wanted Samba/NFS to transfer files quickly and easily between my home systems and my Dropbox account.

Last edited by lenhuppe (2022-04-20 17:49:03)


Why do we drive on the parkway and then park in the driveway?

Offline

#6 2022-04-20 20:00:43

-thc
Member
Registered: 2017-03-15
Posts: 485

Re: SOLVED NFS in place of Samba

O.K. - this is a gio/gvfs mount. You can also initiate this kind of connection from the command line:

gio mount nfs://host_name/share_name

Next time please try the NFS servers IP address instead of the host name:

gio mount nfs://host_ip_address/share_name

Last edited by -thc (2022-04-20 20:01:25)

Offline

#7 2022-04-20 22:14:10

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 271
Website

Re: SOLVED NFS in place of Samba

-thc wrote:

O.K. - this is a gio/gvfs mount. You can also initiate this kind of connection from the command line:

gio mount nfs://host_name/share_name

Next time please try the NFS servers IP address instead of the host name:

gio mount nfs://host_ip_address/share_name

That was it. I guess its time to learn how to setup DNS at home. My simple mDNS setup will need to be reconfigured.

Much appreciated

Last edited by lenhuppe (2022-04-21 02:13:08)


Why do we drive on the parkway and then park in the driveway?

Offline

#8 2022-04-22 14:08:12

lenhuppe
Member
From: New Hampshire USA
Registered: 2018-12-10
Posts: 271
Website

Re: SOLVED NFS in place of Samba

Solution:

The issue is related to mounting the share for the first time. If you look above -thc provided the answer. I tried to do that in a setup script but never got it to work well.

Once the client is installed, I mount the share from a terminal using the server address.

Last edited by lenhuppe (2022-05-14 01:12:42)


Why do we drive on the parkway and then park in the driveway?

Offline

Board footer

Powered by FluxBB