[Samba] Samba fails to open an UDP loopback socket on FreeBSD 5.x
scali at scali.eu.org
Wed Mar 17 18:04:37 GMT 2004
Machine Arch: x86 (Pentium) Machine OS: FreeBSD OS Version: 5.2.1 Kernel: FreeBSD 5.2.1 generic (unaltered binary)
Compiler: gcc 3.3.3 Libc Version: (Default libc for FreeBSD 5.2.1)
Samba Version: 2.2.8a
Network Layout (description): Simple 8-machine 100 mbit ethernet LAN with Windows clients and one FreeBSD machine hosting Samba shares on a simple workgroup.
What else is on machine (services, etc): Apache, mysql, sendmail, proftpd, bind.
After installing FreeBSD 5.1, and again FreeBSD 5.2.1, Samba failed to run...
After some debugging, I noticed that the problem was that Samba tries to open an UDP socket to 127.0.0.1, even if it is configured specifically only to use the LAN interface, not lo0.
The problem is that FreeBSD 5.x apparently doesn't configure lo0 by default, and therefore there is no loopback device, and the creation of the socket fails. I am not sure if it is a bug that FreeBSD does not set up lo0 properly, or if this is done for a reason (I sent a message to the FreeBSD team aswell, on this issue).
But it did strike me that all services behaved properly, except for Samba...
My suspicion is that the UDP socket is opened for interprocess-communication inside Samba itself. In that case it is not a bug, however it might be useful if the IPC would be altered so that it would not rely on network interfaces that may not be available for some reason, in order to improve compatibility.
Alternatively, it would be nice to point out the problem to FreeBSD-users.
I just wanted to point out that the problem exists, so that you can address it in whatever way you see fit.
More information about the samba