Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
systemd not starting nmbd on boot
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
darkphader
Veteran
Veteran


Joined: 09 May 2002
Posts: 1225
Location: Motown

PostPosted: Sun Jun 29, 2014 5:38 pm    Post subject: systemd not starting nmbd on boot Reply with quote

Note that I filed Bug #515684 but thought maybe someone here on the forum would have some ideas.

Basically systemd is no longer starting nmbd on boot and therefore samba is not fully functional.

The installed nmbd.service file has these contents:
Code:
# cat /usr/lib64/systemd/system/nmbd.service
[Unit]
Description=Samba NetBIOS name server
After=network.target

[Service]
Type=forking
PIDFile=/var/run/samba/nmbd.pid
ExecStart=/usr/sbin/nmbd -D
ExecReload=/bin/kill -HUP $MAINPID

[Install]
WantedBy=multi-user.target

In an attempt to solve this after reading http://www.freedesktop.org/wiki/Software/systemd/NetworkTarget/ I changed the nmbd.service file to:
Code:
# cat /etc/systemd/system/nmbd.service
[Unit]
Description=Samba NetBIOS name server
After=network-online.target
Wants=network-online.target

[Service]
Type=forking
PIDFile=/var/run/samba/nmbd.pid
ExecStart=/usr/sbin/nmbd -D
ExecReload=/bin/kill -HUP $MAINPID

[Install]
WantedBy=multi-user.target

And enabled systemd-networkd-wait-online.service:
Code:
# systemctl status systemd-networkd
● systemd-networkd.service - Network Service
   Loaded: loaded (/usr/lib64/systemd/system/systemd-networkd.service; enabled)
   Active: active (running) since Sun 2014-06-29 12:47:26 EDT; 16min ago
     Docs: man:systemd-networkd.service(8)
 Main PID: 469 (systemd-network)
   Status: "Processing requests..."
   CGroup: /system.slice/systemd-networkd.service
           └─469 /usr/lib/systemd/systemd-networkd

Jun 29 12:47:26 sartre systemd[1]: Started Network Service.


# systemctl status systemd-networkd-wait-online.service
● systemd-networkd-wait-online.service - Wait for Network to be Configured
   Loaded: loaded (/usr/lib64/systemd/system/systemd-networkd-wait-online.service; enabled)
   Active: active (exited) since Sun 2014-06-29 12:47:29 EDT; 16min ago
     Docs: man:systemd-networkd-wait-online.service(8)
  Process: 476 ExecStart=/usr/lib/systemd/systemd-networkd-wait-online (code=exited, status=0/SUCCESS)
 Main PID: 476 (code=exited, status=0/SUCCESS)
   CGroup: /system.slice/systemd-networkd-wait-online.service

Although none of this was necessary until recently (not sure if it was the upgrade to systemd-214 or not).

The results are still not pretty:
Code:
Jun 29 12:47:29 sartre systemd[1]: Starting Network is Online.
Jun 29 12:47:29 sartre systemd[1]: Reached target Network is Online.
Jun 29 12:47:29 sartre systemd[1]: Starting Samba NetBIOS name server...
Jun 29 12:47:29 sartre systemd[1]: Starting Vsftpd ftp daemon...
Jun 29 12:47:29 sartre dhcpcd[460]: DUID 00:01:00:01:0f:2c:94:65:00:16:76:aa:bf:70
Jun 29 12:47:29 sartre dhcpcd[460]: eno1: IAID 00:e3:63:00
Jun 29 12:47:29 sartre libvirtd[512]: 2014-06-29 16:47:29.736+0000: 512: info : libvirt version: 1.2.5
Jun 29 12:47:29 sartre libvirtd[512]: 2014-06-29 16:47:29.736+0000: 512: warning : virGetHostname:654 : getaddrinfo failed
Jun 29 12:47:29 sartre systemd[1]: Started OpenSSH server daemon.
Jun 29 12:47:29 sartre systemd[1]: Started Samba NetBIOS name server.
Jun 29 12:47:29 sartre systemd[1]: Starting Samba SMB/CIFS server...
Jun 29 12:47:29 sartre sshd[544]: Server listening on 0.0.0.0 port 22.
Jun 29 12:47:29 sartre sshd[544]: Server listening on :: port 22.
Jun 29 12:47:29 sartre systemd[1]: nmbd.service: main process exited, code=exited, status=1/FAILURE
Jun 29 12:47:29 sartre systemd[1]: Unit nmbd.service entered failed state.
Jun 29 12:47:29 sartre systemd[1]: Started Virtualization daemon.
Jun 29 12:47:29 sartre dhcpcd[460]: eno1: rebinding lease of 172.27.12.66
Jun 29 12:47:29 sartre systemd[1]: Started Samba SMB/CIFS server.

Even though we "Reached target Network is Online." the network doesn't have IP address until after the nmbd failure.
_________________
WYSIWYG - What You See Is What You Grep
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum