[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 296
  • Last Modified:

Samba nmbd problems

My samba server will only respond to 'localhost' and not its dns name.  I have run many diagnostic tests and I believe that the broadcast is incorrect.  It is broadcasting to x.y.255.255 and I believe that it should be broadcasting to x.y.z.255.  nmbd is also giving me broadcast errors in the logs.  My ethernet setting are configured through DHCP.  How can I change the broadcast address or change this???
0
mh149
Asked:
mh149
1 Solution
 
owldCommented:
Please give to us output from

#ifconfig

command.
0
 
mh149Author Commented:
Here is the output of ifconfig:

eth0      Link encap:Ethernet  HWaddr 00:10:5A:11:06:54  
          inet addr:128.61.99.149  Bcast:128.61.99.191  Mask:255.255.255.192
          UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:35073 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1468 errors:0 dropped:0 overruns:0 carrier:3
          collisions:18 txqueuelen:100
          Interrupt:10 Base address:0xe800

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:3924  Metric:1
          RX packets:50 errors:0 dropped:0 overruns:0 frame:0
          TX packets:50 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0


Here is the output of samba client:
[root@ks21 /root]# smbclient -L ks21
Added interface ip=128.61.99.0 bcast=128.61.255.255 nmask=255.255.0.0
0
 
jlevieCommented:
If nmdb is broadcasting on x.x.255.255, it's because it thinks the system is on Class B network. This can come about from a misconfigured network interface, or from nmbd starting before DHCP has fully set up the system (or a bogus DHCP server).

In general you'd prefer for any sort of server (sendmail, nfs, samba, etc) to have a static IP assignment. It is possible to use DHCP, but the IP should be a reserved IP (i.e., that server gets the same IP every time because the DHCP server has been programed to give the system's MAC address that IP). Even with this you have to be very careful to keep any server functions from starting before the DHCP process completes.
0
NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

 
mh149Author Commented:
So how fo I change the broadcast address, or get nmbd to work?  I am a little locked into using DHCP to work but I could try and get around it if necessary.
0
 
jlevieCommented:
Almost forgot. Check the broadcast address by looking at the output of "ifconfig -a". If it looks okay there, stop the Samba services and then restart them. If it works then, you'll have to arrainge to make sure that Samba only starts after the DHCP set up is complete. If it still isn't broadcasting properly, then you've got a different problem.
0
 
mh149Author Commented:
Sorry for my inxexperience, but could you walk me through changing the boot order of those guys?  Thanks
0
 
jlevieCommented:
Before futzing with the init script order at boot you need to see if Samba will work with the DHCP config the system gets. Have you tried to stop & restart Samba with the system fully up?

Waiting for words...
0
 
y2ktuxCommented:
If you are using Red Hat 6.1 the Samba that comes with that ditribution is full of bugs.  Make sure you download the latest stable samba, in rpm format if you are using Red Hat and you may find that things magically begin to work just fine for you.
0
 
mh149Author Commented:
I am actually using the lastest version - I fixed it and would give you the points but jlevie really pointed me to the answer.  Sorry.  But jlevie if you propose an answer.  I will give it to you.  Thanks everyone.
0
 
jlevieCommented:
I'm not certain which piece was the answer, but ...

Samba must only be started after the DHCP process is complete and the system IP & netmask are correctly set up.

0
 
mh149Author Commented:
Samba was starting before dhcpcd in a couple of the rc#.d directories.  I put its order after dhcpcd and it works great now.  Thanks
0
 
jlevieCommented:
Cool...
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now