Taoheedene
Mission Specialist
Mission Specialist
  • 740 Views

Issue Starting nmb Service After Samba Installation

Jump to solution


Good day, everyone.

I’m encountering an issue while trying to set up Samba. I’ve modified the `/etc/samba/smb.conf` file following the instructions below:

```
[global]
workgroup = WORKGROUP
netbios name = centos
security = user
map to guest = bad user
dns proxy = no

[Anonymous]
path = /samba/morepretzels
browsable = yes
writable = yes
guest ok = yes
guest only = yes
read only = no
```

I successfully enabled both `smb` and `nmb` services. While I was able to start the `smb` service without any issues, I’m having trouble with the `nmb` service. When I attempt to start it, I receive the following error:

```
systemctl start nmb
Job for nmb.service failed because a timeout was exceeded.
See “systemctl status nmb.service” and “journalctl -xeu nmb.service” for details.
```

I've reviewed the configuration but can't seem to pinpoint where the issue lies. Could anyone provide some insights or guidance on what might be causing this problem?

Thanks in advance!
3 Solutions

Accepted Solutions
shashi01
Moderator
Moderator
  • 560 Views

@Taoheedene 

nmb.service is failing to start due to a timeout. Please review the following points.

Check Network Connection (Ensure your system is connected to the network.)

ip a OR nmcli device status

Check Port 137 Usage ( Make sure no other service is using port 137)

sudo netstat -tuln | grep 137

Review Samba Configuration (Check for any errors in the [global] section)

sudo nano /etc/samba/smb.conf

Restart and Re-enable NMB Service

Verify Firewall Settings

View solution in original post

0 Kudos
shashi01
Moderator
Moderator
  • 520 Views

@Taoheedene 

I think the main issue here is that the NMB daemon can’t find a valid network interface to which to bind. Ensure your system is properly connected to the network and configured, and double-check your Samba configuration to allow it to bind to the right interfaces. Restart the network and NMB services, and check the firewall settings to make sure nothing is blocking it.

View solution in original post

0 Kudos
Chetan_Tiwary_
Community Manager
Community Manager
  • 603 Views

@Taoheedene if you look at the logs carefully - you should get a hint at what was causing the issue :

Chetan_Tiwary__0-1726662562076.png

so you need to verify the interface setting in the smb.conf : eg.

interfaces = 127.0.0.0/8 exx0  

you need to verify that you have mentioned the correct interface there. 
and then restart nmb service.

Another thing is that , it actually does not need this setting in the smb.conf,
because samba will query the kernel to ask for any available interface.
 Of course unless you have  used these two settings :

Screenshot from 2024-09-18 18-10-56.png

Refer the man page smb.conf

View solution in original post

0 Kudos
11 Replies
Trevor
Starfighter Starfighter
Starfighter
  • 583 Views

Try to start the nmb service again, and then run those 2 commands:

systemctl  status  nmb.service

journalctl  -xeu  nmb.service

 

After running those commands, please provide me the complete output of both of them.
Standing by ...

Trevor "Red Hat Evangelist" Chandler
Taoheedene
Mission Specialist
Mission Specialist
  • 567 Views
Running `systemctl status nmb.service`, I got:

```
nmb.service - Samba NMB Daemon
Loaded: loaded (/usr/lib/systemd/system/nmb.service; enabled; preset: disabled)
Active: failed (Result: timeout)
```

Running `journalctl -xeu nmb.service`, I got:

```
The job identifier is 3335
-
-
Subject: Unit failed
Defined-By: systemd
Support: https://access.redhat.com/support

The unit nmb.service has entered the ‘failed’ state with result ‘timeout’
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: Failed to start Samba NMB Daemon.
```
0 Kudos
shashi01
Moderator
Moderator
  • 561 Views

@Taoheedene 

nmb.service is failing to start due to a timeout. Please review the following points.

Check Network Connection (Ensure your system is connected to the network.)

ip a OR nmcli device status

Check Port 137 Usage ( Make sure no other service is using port 137)

sudo netstat -tuln | grep 137

Review Samba Configuration (Check for any errors in the [global] section)

sudo nano /etc/samba/smb.conf

Restart and Re-enable NMB Service

Verify Firewall Settings

0 Kudos
Trevor
Starfighter Starfighter
Starfighter
  • 545 Views

Looks like you may have cut out some of the output from both of the
commands.  I would like to have ALL of the output from each command!!!!

Trevor "Red Hat Evangelist" Chandler
Taoheedene
Mission Specialist
Mission Specialist
  • 531 Views
Please, is it possible to share pictures here. If so, could someone guide me on the best way to do it?
Taoheedene
Mission Specialist
Mission Specialist
  • 522 Views
root@MyFirstLinuxVM samba]# systemctl start nmb
Job for nmb.service failed because a timeout was exceeded.
See "systemctl status nmb.service" and "journalctl -xeu nmb.service" for details.
[root@MyFirstLinuxVM samba]# systemctl status nmb.service
× nmb.service - Samba NMB Daemon
Loaded: loaded (/usr/lib/systemd/system/nmb.service; enabled; preset: disa>
Active: failed (Result: timeout) since Tue 2024-09-17 18:46:42 EDT; 46s ago
Docs: man:nmbd(8)
man:samba(7)
man:smb.conf(5)
Process: 2801 ExecStart=/usr/sbin/nmbd --foreground --no-process-group $NMB>
Main PID: 2801 (code=killed, signal=TERM)
Status: "nmbd: No local IPv4 non-loopback interfaces available, waiting fo>
CPU: 302ms

Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: [2024/09/17 18:45:12.850232, 0] ../>
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: nmbd version 4.20.2 started.
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: Copyright Andrew Tridgell and the >
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: [2024/09/17 18:45:12.853560, 0] ../>
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: daemon 'nmbd' : No local IPv4 non->
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: [2024/09/17 18:45:12.862724, 0] ../>
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: NOTE: NetBIOS name resolution is n>
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: nmb.service: start operation timed o>
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: nmb.service: Failed with result 'tim>
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: Failed to start Samba NMB Daemon.

[root@MyFirstLinuxVM samba]# ^C
[root@MyFirstLinuxVM samba]# journalctl -xeu nmb.service
░░ The job identifier is 3335.
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: [2024/09/17 18:45:12.850232, 0] ../>
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: nmbd version 4.20.2 started.
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: Copyright Andrew Tridgell and the >
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: [2024/09/17 18:45:12.853560, 0] ../>
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: daemon 'nmbd' : No local IPv4 non->
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: [2024/09/17 18:45:12.862724, 0] ../>
Sep 17 18:45:12 MyFirstLinuxVM nmbd[2801]: NOTE: NetBIOS name resolution is n>
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: nmb.service: start operation timed o>
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: nmb.service: Failed with result 'tim>
░░ Subject: Unit failed
░░ Defined-By: systemd
░░ Support: https://access.redhat.com/support
░░
░░ The unit nmb.service has entered the 'failed' state with result 'timeout'.
Sep 17 18:46:42 MyFirstLinuxVM systemd[1]: Failed to start Samba NMB Daemon.
░░ Subject: A start job for unit nmb.service has failed
░░ Defined-By: systemd
░░ Support: https://access.redhat.com/support
░░
░░ A start job for unit nmb.service has finished with a failure.
░░
░░ The job identifier is 3335 and the job result is failed.
shashi01
Moderator
Moderator
  • 521 Views

@Taoheedene 

I think the main issue here is that the NMB daemon can’t find a valid network interface to which to bind. Ensure your system is properly connected to the network and configured, and double-check your Samba configuration to allow it to bind to the right interfaces. Restart the network and NMB services, and check the firewall settings to make sure nothing is blocking it.

0 Kudos
Taoheedene
Mission Specialist
Mission Specialist
  • 510 Views
Thank you, everyone, for your contributions. I finally found the solution. It turns out I needed to connect to the internet before starting the NMB service.
shashi01
Moderator
Moderator
  • 508 Views

@Taoheedene 

Great to hear that you found the solution! Connecting to the internet makes sense for network services like NMB. Thanks for sharing the update!

0 Kudos
Join the discussion
You must log in to join this conversation.