You are not logged in.

#1 2018-06-24 19:08:58

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

NFS share won't auto mount [SOLVED]

Ok so I've been dealing with a nfs share not auto mounting the entire time I've had arch. mount -t works fine. I'm on KDE using it's networkmanager

I've tried using the default mounting options and systemd in my fstab but I don't think that's the issue.

After searching quite a bit I realized that it was probably trying to mount before I have an internet connection. I found this post https://bbs.archlinux.org/viewtopic.php?id=228685 and followed everything that was talked about.

My issue is that when I run these commands everything seems working

#sudo systemctl start NetworkManager-wait-online.service
#sudo systemctl enable NetworkManager-wait-online.service
systemctl status NetworkManager-wait-online.service
● NetworkManager-wait-online.service - Network Manager Wait Online
   Loaded: loaded (/usr/lib/systemd/system/NetworkManager-wait-online.service; enabled; vendor preset: disabled)
   Active: active (exited) since Sun 2018-06-24 11:17:51 PDT; 24min ago
     Docs: man:nm-online(1)
  Process: 2316 ExecStart=/usr/bin/nm-online -s -q --timeout=30 (code=exited, status=0/SUCCESS)
 Main PID: 2316 (code=exited, status=0/SUCCESS)

Jun 24 11:17:51 ninjapepper systemd[1]: Starting Network Manager Wait Online...
Jun 24 11:17:51 ninjapepper systemd[1]: Started Network Manager Wait Online.

However when I restart It's not running in my systemctl services

systemctl status NetworkManager-wait-online.service
● NetworkManager-wait-online.service - Network Manager Wait Online
   Loaded: loaded (/usr/lib/systemd/system/NetworkManager-wait-online.service; enabled; vendor preset: disabled)
   Active: inactive (dead)
     Docs: man:nm-online(1)

There are no entries with "journalctl -b --unit=NetworkManager-wait-online.service" and 0 loaded units listed using "systemctl --state=failed"
I also have the file in "/etc/systemd/system/network-online.target.wants/NetworkManager-wait-online.service"

So for some unknown reason it's not enabling on boot It's really got me stumped. I'm using a VPN but I don't think that would have anything to do with it. It's probably something simple I'm missing. Hoping someone can help me out thanks!

Last edited by ninjapepper (2018-06-25 15:24:55)

Offline

#2 2018-06-24 19:16:49

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

What is the status of NetworkManager.service on the boot when NetworkManager-wait-online.service is inactive?
Edit:
Oh and welcome to the arch linux forums ninjapepper.

Last edited by loqs (2018-06-24 19:17:37)

Offline

#3 2018-06-24 19:32:01

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

Thanks! would I find that out with "journalctl -b --unit=NetworkManager.service"? Everything looked good as far as I can tell and my network starts right up and automatically connects

Could it have something to do with my on board wireless card? It's disabled in the bios now but was on when I first installed

Last edited by ninjapepper (2018-06-24 19:35:00)

Offline

#4 2018-06-24 19:34:47

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

`journalctl -b --unit=NetworkManager.service` will be whats recorded for the current boot so it should indicate the current status you can get the status directly with

systemctl status NetworkManager.service

The same as you did you NetworkManager-wait-online.service
Edit:
fixed command referencing wrong service

Last edited by loqs (2018-06-24 19:35:42)

Offline

#5 2018-06-24 19:36:58

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

Ok heres the readout

ystemctl status NetworkManager-wait-online.service
● NetworkManager-wait-online.service - Network Manager Wait Online
   Loaded: loaded (/usr/lib/systemd/system/NetworkManager-wait-online.service; enabled; vendor preset: disabled)
   Active: inactive (dead)
     Docs: man:nm-online(1)
[ryan@ninjapepper ~]$ systemctl status NetworkManager.service
● NetworkManager.service - Network Manager
   Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; enabled; vendor preset: disabled)
  Drop-In: /usr/lib/systemd/system/NetworkManager.service.d
           └─NetworkManager-ovs.conf
   Active: active (running) since Sun 2018-06-24 11:49:07 PDT; 47min ago
     Docs: man:NetworkManager(8)
 Main PID: 873 (NetworkManager)
    Tasks: 7 (limit: 19660)
   Memory: 23.8M
   CGroup: /system.slice/NetworkManager.service
           ├─ 873 /usr/bin/NetworkManager --no-daemon
           ├─1030 /usr/lib/nm-openvpn-service --bus-name org.freedesktop.NetworkManager.openvpn.Connection_2
           └─1036 /usr/sbin/openvpn --remote us-siliconvalley.privateinternetaccess.com 1198 udp --comp-lzo yes --nobind --dev tun --cipher>

Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5628] device (tun0): Activation: starting connection 'tun0' (af53ab56->
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5634] device (tun0): state change: disconnected -> prepare (reason 'no>
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5637] device (tun0): state change: prepare -> config (reason 'none', s>
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5638] device (tun0): state change: config -> ip-config (reason 'none',>
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5639] device (tun0): state change: ip-config -> ip-check (reason 'none>
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5642] device (tun0): state change: ip-check -> secondaries (reason 'no>
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5644] device (tun0): state change: secondaries -> activated (reason 'n>
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5699] device (tun0): Activation: successful, device activated.
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5702] manager: startup complete
Jun 24 11:49:13 ninjapepper NetworkManager[873]: <info>  [1529866153.5694] manager: NetworkManager state is now CONNECTED_GLOBAL

Offline

#6 2018-06-24 19:42:08

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

It also had this that didn't paste  below that. I'm not sure what device tun0 is that my vpn? My ethernet is enp3s0

un 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5628] device (tun0): Activation: starting connection 'tun0' (af53ab56-2270-4ab7-9576-11fbaae61f33)
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5634] device (tun0): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'external')
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5637] device (tun0): state change: prepare -> config (reason 'none', sys-iface-state: 'external')
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5638] device (tun0): state change: config -> ip-config (reason 'none', sys-iface-state: 'external')
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5639] device (tun0): state change: ip-config -> ip-check (reason 'none', sys-iface-state: 'external')
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5642] device (tun0): state change: ip-check -> secondaries (reason 'none', sys-iface-state: 'external')
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5644] device (tun0): state change: secondaries -> activated (reason 'none', sys-iface-state: 'external')
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5699] device (tun0): Activation: successful, device activated.
Jun 24 11:49:12 ninjapepper NetworkManager[873]: <info>  [1529866152.5702] manager: startup complete
Jun 24 11:49:13 ninjapepper NetworkManager[873]: <info>  [1529866153.5694] manager: NetworkManager state is now CONNECTED_GLOBAL

Offline

#7 2018-06-24 19:49:13

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

systemctl status network-online.target

Offline

#8 2018-06-24 19:54:02

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

● network-online.target - Network is Online
   Loaded: loaded (/usr/lib/systemd/system/network-online.target; static; vendor preset: disabled)
   Active: inactive (dead)
     Docs: man:systemd.special(7)
           https://www.freedesktop.org/wiki/Software/systemd/NetworkTarget

I really appreciate the help!

Offline

#9 2018-06-24 20:02:11

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

I believe the service is not started because network-online.target is never reached.

systemctl list-dependencies --reverse network-online.target
systemctl list-dependencies  network-online.target

Offline

#10 2018-06-24 20:09:42

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

Ok I ran those commands rebootedd and "systemctl status network-online.target" is showing the same thing and NetworkManager-wait-online.service
still hasn't loaded

Offline

#11 2018-06-24 20:11:54

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

Both the commands from #9 had no output?

Offline

#12 2018-06-24 20:14:40

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

Oh sorry

systemctl list-dependencies --reverse network-online.target
network-online.target
systemctl list-dependencies  network-online.target
network-online.target
● └─NetworkManager-wait-online.service

Offline

#13 2018-06-24 20:20:23

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

What is the fstab entry for the nfs mount?

Offline

#14 2018-06-24 20:25:11

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

# 192.168.0.xxx:/mnt/drives/   /mnt   nfs  nfs x-systemd.requires=network.target,noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,x-systemd.idle-timeout=1min  0 0

I've also tried this and quite a few others

# 192.168.0.xxx:/mnt/drives/   /mnt    nfs   defaults,soft,rsize=32768,wsize=32768,timeo=900,retrans=5,_netdev	0 0

Oh and it's a freenas box with an nfs share

Last edited by ninjapepper (2018-06-24 20:53:28)

Offline

#15 2018-06-24 21:19:51

seth
Member
Registered: 2012-09-03
Posts: 51,064

Re: NFS share won't auto mount [SOLVED]

Try "x-systemd.requires=network-online.target"

Offline

#16 2018-06-24 21:30:03

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

Yeah still didn't work

Offline

#17 2018-06-24 21:40:30

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

systemctl cat mnt.mount

What is the journal output when from the share will not auto mount?

Offline

#18 2018-06-24 22:04:18

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

I'm not quite sure what you mean would it be in journalctl?

systemctl cat mnt.mount
No files found for mnt.mount. 

Offline

#19 2018-06-24 23:00:57

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

The following should list systemd generated mounts.

ls /run/systemd/generator/*.mount

Offline

#20 2018-06-24 23:06:43

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

ls /run/systemd/generator/*.mount
/run/systemd/generator/boot.mount  /run/systemd/generator/home.mount  /run/systemd/generator/home-ryan-hd-ssd1.mount  /run/systemd/generator/-.mount

Honestly I  may just switch the server to CIFS and see if I have more luck auto mounting that as this has been such a hassle and I don't wanna waste anymore of your time but I'll keep playing around with it

Offline

#21 2018-06-24 23:16:40

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

This was with the fstab entry for /mnt being valid and not commented out and after a reboot?  Also then please look in the journal ( yes journalctl ) see if there is any output referring to nfs or /mnt.

Offline

#22 2018-06-24 23:27:16

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

yeah I did a fresh reboot with it in fstab for it the ryan-hd-ssd1 is a ssd drive I got. Ok here's what I think I'm looking for in journalctl

Mar 28 07:40:51 ninjapepper systemd[1]: Mounting /mnt...
Mar 28 07:40:51 ninjapepper mount[835]: mount.nfs: Network is unreachable
Mar 28 07:40:51 ninjapepper systemd[1]: mnt.mount: Mount process exited, code=exited status=32
Mar 28 07:40:51 ninjapepper systemd[1]: mnt.mount: Failed with result 'exit-code'.
Mar 28 07:40:51 ninjapepper systemd[1]: Failed to mount /mnt.
Mar 30 02:47:27 ninjapepper systemd[1]: Unmounting /mnt...
Mar 30 02:47:28 ninjapepper systemd[1]: mnt.mount: Failed with result 'exit-code'.
Mar 30 02:47:28 ninjapepper systemd[1]: Unmounted /mnt.

So basically it's not able to reach the network could that be like my original thinking that it's starting before I have a network connection?

Offline

#23 2018-06-24 23:38:52

loqs
Member
Registered: 2014-03-06
Posts: 17,327

Re: NFS share won't auto mount [SOLVED]

What was the fstab entry for /mnt that produced that and the output of the following at boot

systemctl status network-online.target
systemctl status NetworkManager-wait-online.service

Please also post the full journal for that boot so I can see the relationship between NetworkManager startup and the mounts failure.

Offline

#24 2018-06-24 23:52:45

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

# 192.168.0.xxx:/mnt/drives/   /mnt   nfs x-systemd.requires=network-online.target,noauto,x-systemd.automount,x-systemd.device-timeout=10,timeo=14,x-systemd.idle-timeout=1min  0 0

Last edited by ninjapepper (2018-06-25 01:00:05)

Offline

#25 2018-06-25 00:04:11

ninjapepper
Member
Registered: 2018-06-24
Posts: 27

Re: NFS share won't auto mount [SOLVED]

Whoops I'm super sorry I'm still pretty new for that last log I used journalctl --unit=/mnt I forgot to add the -b which is the last boot. I just did "journalctl -b --unit=/mnt" and it had no entries that one must have been from a while ago  my bad

Do you still want my whole journalctl -b?

Last edited by ninjapepper (2018-06-25 00:15:11)

Offline

Board footer

Powered by FluxBB