[Pkg-samba-maint] Bug#614697: Acknowledgement (smbclient fails with NT_STATUS_BAD_NETWORK_NAME when using ip address)

Sebastian Kricner sebastian.kricner at web.de
Wed Feb 23 01:05:01 UTC 2011


Just after some investigation, but seems not to be the cause:

In source3/client/client.c:

The popt Arguments are specified like this:

{ "ip-address", 'I', POPT_ARG_STRING, NULL, 'I', "Use this IP to
connect to", "IP" },

According to http://developer.gnome.org/doc/GGAD/z77.html the NULL
value issued here should be a address of an buffer to hold the
information gathered on the command line. This is set to NULL.

But ok, the argument seems to be taken from:

if (!interpret_string_addr(&dest_ss,
poptGetOptArg(pc), 0)) { exit(1);
}    


After this also seems now useless, i post the output:

smbclient -L NAME -I IP  -UGuest
Enter nobody's password: 
Connection to NAME failed (Error NT_STATUS_BAD_NETWORK_NAME)

I have also verified using nmblookup -A ip address the name is ok.
If i set the Hostname+IP in /etc/hosts all works ok. But in older
versions/bugfree versions of smbclient it worked straight without any
entry in the /etc/hosts file.

Debugging:

INFO: Current debug levels:
  all: True/10
  tdb: False/0
  printdrivers: False/0
  lanman: False/0
  smb: False/0
  rpc_parse: False/0
  rpc_srv: False/0
  rpc_cli: False/0
  passdb: False/0
  sam: False/0
  auth: False/0
  winbind: False/0
  vfs: False/0
  idmap: False/0
  quota: False/0
  acls: False/0
  locking: False/0
  msdfs: False/0
  dmapi: False/0
  registry: False/0
lp_load_ex: refreshing parameters
Initialising global parameters
rlimit_max: rlimit_max (1024) below minimum Windows limit (16384)
params.c:pm_process() - Processing configuration file
"/etc/samba/smb.conf"
Processing section "[global]"
doing parameter netbios name = FOOBAR
handle_netbios_name: set global_myname to: FOOBAR
doing parameter netbios aliases = FOO
doing parameter workgroup = WORKGROUP
pm_process() returned Yes
lp_servicenumber: couldn't find homes
set_server_role: role = ROLE_STANDALONE
Attempting to register new charset UCS-2LE
Registered charset UCS-2LE
Attempting to register new charset UTF-16LE
Registered charset UTF-16LE
Attempting to register new charset UCS-2BE
Registered charset UCS-2BE
Attempting to register new charset UTF-16BE
Registered charset UTF-16BE
Attempting to register new charset UTF8
Registered charset UTF8
Attempting to register new charset UTF-8
Registered charset UTF-8
Attempting to register new charset ASCII
Registered charset ASCII
Attempting to register new charset 646
Registered charset 646
Attempting to register new charset ISO-8859-1
Registered charset ISO-8859-1
Attempting to register new charset UCS2-HEX
Registered charset UCS2-HEX
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
Substituting charset 'UTF-8' for LOCALE
added interface eth1 ip=2001:6f8:1378::2
bcast=2001:6f8:1378:0:ffff:ffff:ffff:ffff netmask=ffff:ffff:ffff:ffff::
added interface eth1 ip=2001:6f8:1378:0:200:cbff:fe68:58bd
bcast=2001:6f8:1378:0:ffff:ffff:ffff:ffff netmask=ffff:ffff:ffff:ffff::
added interface eth1 ip=fe80::200:cbff:fe68:58bd%eth1
bcast=fe80::ffff:ffff:ffff:ffff%eth1 netmask=ffff:ffff:ffff:ffff::
added interface eth1 ip=192.168.0.2 bcast=192.168.0.255
netmask=255.255.255.0
Netbios name list:-
my_netbios_names[0]="FOOBAR"
my_netbios_names[1]="FOO"
Client started (version 3.5.6).
Enter nobody's password: 
Opening cache file at /var/run/samba/gencache.tdb
tdb(unnamed): tdb_open_ex: could not open
file /var/run/samba/gencache.tdb: Keine Berechtigung
tdb(unnamed): tdb_open_ex: could not open
file /var/run/samba/gencache.tdb: Datei oder Verzeichnis nicht gefunden
Attempt to open gencache.tdb has failed.
sitename_fetch: No stored sitename for 
internal_resolve_name: looking up NAME#20 (sitename (null))
Opening cache file at /var/run/samba/gencache.tdb
tdb(unnamed): tdb_open_ex: could not open
file /var/run/samba/gencache.tdb: Keine Berechtigung
tdb(unnamed): tdb_open_ex: could not open
file /var/run/samba/gencache.tdb: Datei oder Verzeichnis nicht gefunden
Attempt to open gencache.tdb has failed.
no entry for NAME#20 found.
resolve_lmhosts: Attempting lmhosts lookup for name NAME<0x20>
resolve_wins: Attempting wins lookup for name NAME<0x20>
resolve_wins: WINS server resolution selected and no WINS servers
listed.
resolve_hosts: Attempting host lookup for name NAME<0x20>
resolve_hosts: getaddrinfo failed for name NAME [Der Name oder
der Dienst ist nicht bekannt]
name_resolve_bcast: Attempting broadcast lookup for name
NAME<0x20>
bind succeeded on port 0
Socket options:
	SO_KEEPALIVE = 0
	SO_REUSEADDR = 1
	SO_BROADCAST = 1
	Could not test socket option TCP_NODELAY.
	Could not test socket option TCP_KEEPCNT.
	Could not test socket option TCP_KEEPIDLE.
	Could not test socket option TCP_KEEPINTVL.
	IPTOS_LOWDELAY = 0
	IPTOS_THROUGHPUT = 0
	SO_SNDBUF = 110592
	SO_RCVBUF = 110592
	SO_SNDLOWAT = 1
	SO_RCVLOWAT = 1
	SO_SNDTIMEO = 0
	SO_RCVTIMEO = 0
	Could not test socket option TCP_QUICKACK.
Sending a packet of len 50 to (192.168.0.255) on port 137
Sending a packet of len 50 to (192.168.0.255) on port 137
Sending a packet of len 50 to (192.168.0.255) on port 137
lang_tdb_init: /usr/share/samba/de_DE.UTF-8.msg: Datei oder Verzeichnis
nicht gefunden
Connection to NAME failed (Error NT_STATUS_BAD_NETWORK_NAME)






More information about the Pkg-samba-maint mailing list