You are not logged in.

#1 2019-08-31 18:49:08

rootpeer
Member
Registered: 2019-04-07
Posts: 41

[Solved] Slow boot with cifs mounts in fstab

Hello, my boot times are extremely slow at ~2min when I have my cifs mounts enabled in fstab compared to without at ~15sec.

I have two mounts from the same server. I tried with options: noauto,x-systemd.automount,x-systemd.device-timeout=30,_netdev  as per the wiki but what happens is that I log in the desktop and I just see the desktop background for 2 minutes instead. That means that the 2 minute wait is transfered to the desktop where I cannot do anything instead of the kernel message boot screen or whatever it is called.

What can I do to remedy this?

P.S.: I also have other services that wait for the network to come online, mainly one to set MACs on SR-IOV vfs of my NIC. These do not seem to cause delays but, when I enable the cifs mounts I can see on the kernel message boot screen:

Waiting for ixgbevfmac.service, waiting for networkManager-wait-online.service.

Last edited by rootpeer (2019-09-01 12:38:28)

Offline

#2 2019-08-31 19:16:20

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

Offline

#3 2019-08-31 19:50:51

rootpeer
Member
Registered: 2019-04-07
Posts: 41

Re: [Solved] Slow boot with cifs mounts in fstab

How does this have anything to do with my problem?

I know what Haveged is, I am running it on my laptop. My problem has to do with the whole system waiting to mount the cifs shares.

Offline

#4 2019-08-31 19:58:33

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

Re: [Solved] Slow boot with cifs mounts in fstab

You said if you avoid a direct mount, the desktop simply stalls instead? (Unless of course your session implcitily accesses the cifs mount, what you did not indicate)
Also cifs will rely on a sufficient entropy pool (as does a bunch of other stuff), and it's a major cause for this kind of delay.

Post the complete output of "sudo journalctl -b", you can use https://wiki.archlinux.org/index.php/Pastebin

Offline

#5 2019-09-01 10:07:43

rootpeer
Member
Registered: 2019-04-07
Posts: 41

Re: [Solved] Slow boot with cifs mounts in fstab

I did enable haveged, still the problem persists. My entropy after boot is ~3000 regardless of haveged being enabled or not.

When using   noauto,x-systemd.automount,x-systemd.device-timeout=30,_netdev   I get to the desktop in ~15sec and I can use yakuake but e.g. lattedock takes 2 minutes to launch. It feels like the network takes ages to initialize or that is what the system thinks. I failed to mention that I use KDE.

I also get "Link is Up, Link is Down" messages in dmesg, at a higher frequency at boot and then it sort of settles, since I got this card. I have seen other users reporting this behavior with the 82599ES NIC and I have also reported it here without any response: https://bbs.archlinux.org/viewtopic.php?id=246307
I am just mentioning it because it might be playing a role, although I see the messages regardless of the cifs mounts.

I am mounting the shares with caching enabled.

Edit: Here is the paste: http://ix.io/1TXV

Last edited by rootpeer (2019-09-01 10:08:01)

Offline

#6 2019-09-01 11:05:50

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

Re: [Solved] Slow boot with cifs mounts in fstab

You've at least two network manaaging services (NM & systemd-networkd) enabled, output of

systemctl list-unit-files --state=enabled

PIck *one* network service and ditch all others. They enter a race and knock each other out.

Sth. in your session will indeed try to access the cifs mount or maybe "lattedock" just relies on some other network feature.

Offline

#7 2019-09-01 11:38:08

rootpeer
Member
Registered: 2019-04-07
Posts: 41

Re: [Solved] Slow boot with cifs mounts in fstab

Wow that absolutely did it! Just disabled networkd and it is finally fixed. I thought systemd-networkd-wait-online.service was necessary for starting services after the network is up and as such I enabled it at some point in conjunction with NetworkManager-wait-online.service.

lattedock seems to rely on some network feature, I have had it crash multiple times with WiFi disconnects on my laptop.

I really cannot thank you enough seth!

Offline

#8 2019-09-01 12:08:09

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

Re: [Solved] Slow boot with cifs mounts in fstab

Cool.

Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

Offline

Board footer

Powered by FluxBB