[Samba] smbd version 3.5.4-62.fc13 can NOT bind to IPv4 endpoint( 0.0.0.0:445 ), but it bind to IPv6 endpoint ( :::445 )

zhengfish zhengfish at gmail.com
Fri Aug 20 00:19:56 MDT 2010


# smbd -Fi -d 2
smbd version 3.5.4-62.fc13 started.
Copyright Andrew Tridgell and the Samba Team 1992-2010
uid=0 gid=0 euid=0 egid=0
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
Registered MSG_REQ_POOL_USAGE
Registered MSG_REQ_DMALLOC_MARK and LOG_CHANGED
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
Processing section "[homes]"
Processing section "[printers]"
cups_async_callback: failed to read a new printer list
cups_async_callback: failed to read a new printer list
added interface eth0 ip=2001:2:3::208 bcast=2001:2:3:0:ffff:ffff:ffff:ffff
netmask=ffff:ffff:ffff:ffff::
added interface eth0 ip=fe80::213:72ff:fe8d:d674%eth0
bcast=fe80::ffff:ffff:ffff:ffff%eth0 netmask=ffff:ffff:ffff:ffff::
added interface eth0 ip=192.168.15.208 bcast=192.168.15.255
netmask=255.255.255.0
bind failed on port 445 socket_addr = 0.0.0.0.
Error = Address already in use
smbd_open_once_socket: open_socket_in: Address already in use
bind failed on port 139 socket_addr = 0.0.0.0.
Error = Address already in use
smbd_open_once_socket: open_socket_in: Address already in use
waiting for connections
^C


but I found after I turn on the bindv6only kernel var, then I can bind both
IPv4 and IPv6 port. like this:
# echo 1 > /proc/sys/net/ipv6/bindv6only

then It works as follows:

# smbd -Fi -d 2
smbd version 3.5.4-62.fc13 started.
Copyright Andrew Tridgell and the Samba Team 1992-2010
uid=0 gid=0 euid=0 egid=0
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
Registered MSG_REQ_POOL_USAGE
Registered MSG_REQ_DMALLOC_MARK and LOG_CHANGED
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
Processing section "[homes]"
Processing section "[printers]"
cups_async_callback: failed to read a new printer list
cups_async_callback: failed to read a new printer list
added interface eth0 ip=2001:2:3::208 bcast=2001:2:3:0:ffff:ffff:ffff:ffff
netmask=ffff:ffff:ffff:ffff::
added interface eth0 ip=fe80::213:72ff:fe8d:d674%eth0
bcast=fe80::ffff:ffff:ffff:ffff%eth0 netmask=ffff:ffff:ffff:ffff::
added interface eth0 ip=192.168.15.208 bcast=192.168.15.255
netmask=255.255.255.0
waiting for connections


I guess it use or get the contrary value of net.ipv6.bindv6only, maybe. :)


That's all.
Thanks a lot


__END__


More information about the samba mailing list