[Samba] smbpasswd port 139

Jeff Sadowski jeff.sadowski at gmail.com
Mon Mar 13 21:04:18 UTC 2017


I have a network where the domain controllers do not connect on port 139

Is there a way to have smbpasswd change the password without this?

I am able to change the password using an ldap method in php

ldap_connect
ldap_bind
ldap_modify_batch

full source code here
http://forums.fedoraforum.org/showthread.php?t=313554

however this does not allow the password to be set if it has expired.
smbpasswd works on 2 of my 3 networks.

I was hoping there might be some way to get it working without port 139

(echo -e 'oldpasswd\nnewpasswd\nnewpasswd')|smbpasswd -r otherdomain -U
user -D 10

INFO: Current debug levels:
  all: 10
  tdb: 10
  printdrivers: 10
  lanman: 10
  smb: 10
  rpc_parse: 10
  rpc_srv: 10
  rpc_cli: 10
  passdb: 10
  sam: 10
  auth: 10
  winbind: 10
  vfs: 10
  idmap: 10
  quota: 10
  acls: 10
  locking: 10
  msdfs: 10
  dmapi: 10
  registry: 10
  scavenger: 10
  dns: 10
  ldb: 10
  tevent: 10
lp_load_ex: refreshing parameters
Initialising global parameters
rlimit_max: increasing rlimit_max (1024) to minimum Windows limit (16384)
INFO: Current debug levels:
  all: 10
  tdb: 10
  printdrivers: 10
  lanman: 10
  smb: 10
  rpc_parse: 10
  rpc_srv: 10
  rpc_cli: 10
  passdb: 10
  sam: 10
  auth: 10
  winbind: 10
  vfs: 10
  idmap: 10
  quota: 10
  acls: 10
  locking: 10
  msdfs: 10
  dmapi: 10
  registry: 10
  scavenger: 10
  dns: 10
  ldb: 10
  tevent: 10
Processing section "[global]"
doing parameter security = ads
...
pm_process() returned Yes
lp_servicenumber: couldn't find homes
Netbios name list:-
...
Old SMB password:
New SMB password:
Retype new SMB password:
Opening cache file at /var/cache/samba/gencache.tdb
tdb(/var/cache/samba/gencache.tdb): tdb_open_ex: could not open file
/var/cache/samba/gencache.tdb: Permission denied
gencache_init: Opening cache file /var/cache/samba/gencache.tdb read-only.
Opening cache file at /var/run/samba/gencache_notrans.tdb
...
internal_resolve_name: returning 1 addresses: <ip of otherdomain dc>
Connecting to <ip of otherdomain dc> at port 445
E2BIG: convert_string(UTF-8,CP850): srclen=22 destlen=16 - '<name of
otherdomain dc>'
Connecting to <ip of otherdomain dc> at port 139
Unable to connect to SMB server on machine <name of otherdomain dc> Error
was : NT_STATUS_CONNECTION_REFUSED.



echo "hello" | telnet <ip of otherdomain dc> 139

Trying <ip of otherdomain dc>...
telnet: Unable to connect to remote host: Connection refused


More information about the samba mailing list