Author Topic: Samba issue  (Read 6293 times)

brononius

  • Guru
  • ****
  • Posts: 454
  • Trying to keep it simple and centralized...
    • View Profile
    • OnIrIa - linuxMCE blog
Samba issue
« on: June 27, 2014, 07:06:39 am »
Hey,

Last days, I played around with the users and the group they belong to. And did also some apt-get udpates. And now I can't login anymore with samba protocol. Apparantly the user don't exist anymore?

The clientPC = Windows 7 & Linux Mint 17
The user = brientje

Quote from: grep brientje log.ClientPC
  check_ntlm_password:  Authentication for user [Brientje] -> [pluto_brientje] FAILED with error NT_STATUS_NO_SUCH_USER
  check_ntlm_password:  Authentication for user [Brientje] -> [pluto_brientje] FAILED with error NT_STATUS_NO_SUCH_USER
  check_ntlm_password:  Authentication for user [Brientje] -> [pluto_brientje] FAILED with error NT_STATUS_NO_SUCH_USER
  check_ntlm_password:  Authentication for user [Brientje] -> [pluto_brientje] FAILED with error NT_STATUS_NO_SUCH_US..........

Quote from: grep brientje /etc/samba/usermap.txt
pluto_brientje = brientje

Quote from: grep brientje /etc/samba/smbpasswd
pluto_brientje:10001:DD4D27348EDCBEBA93E28745B8BF4BA6:3D83FDBC71EF25E316C6BADA8AFF8D19:[U          ]:LCT-00000001:,,,


Quote from: grep brientje /etc/passwd
brientje:x:1001:1003:Brientje User,,,:/home/brientje:/bin/bash
pluto_brientje:x:10001:10001:,,,:/home/user_2:/bin/false

Quote from: id -a brientje
uid=1001(brientje) gid=1003(brientje) groups=1003(brientje),1001(public)

Quote from: id -a pluto_brientje
uid=10001(pluto_brientje) gid=10001(pluto_brientje) groups=10001(pluto_brientje),1001(public),1003(brientje)


Any idea / suggestion?
Version: linuxMCE 1404, running virtual on ESXi

Orbiters: ASUS eeePAD, Nexus 5, Huwai, web
Automation: EIB technology, KNX IP ROUTER 750
Phones: Cisco 7912-7940-7960
Camera's: Foscam POE

brononius

  • Guru
  • ****
  • Posts: 454
  • Trying to keep it simple and centralized...
    • View Profile
    • OnIrIa - linuxMCE blog
Re: Samba issue
« Reply #1 on: June 27, 2014, 09:13:32 am »
After raising the log level, this is a bit more information:

Quote from: more log.clientPC
[2014/06/27 09:06:42,  3] smbd/map_username.c:188(map_username)
  Mapped user Brientje to pluto_brientje
[2014/06/27 09:06:42,  3] auth/auth.c:222(check_ntlm_password)
  check_ntlm_password:  Checking password for unmapped user [clientPC]\[Brientje]@[clientPC] with the new password interface
[2014/06/27 09:06:42,  3] auth/auth.c:225(check_ntlm_password)
  check_ntlm_password:  mapped user is: [CORIUS]\[pluto_brientje]@[clientPC]
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:210(push_sec_ctx)
  push_sec_ctx(0, 0) : sec_ctx_stack_ndx = 1
[2014/06/27 09:06:42,  3] smbd/uid.c:428(push_conn_ctx)
  push_conn_ctx(0) : conn_ctx_stack_ndx = 0
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 1
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:418(pop_sec_ctx)
  pop_sec_ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:42,  3] auth/auth_sam.c:282(check_sam_security)
  check_sam_security: Couldn't find user 'pluto_brientje' in passdb.
[2014/06/27 09:06:42,  2] auth/auth.c:320(check_ntlm_password)
  check_ntlm_password:  Authentication for user [Brientje] -> [pluto_brientje] FAILED with error NT_STATUS_NO_SUCH_USER
[2014/06/27 09:06:42,  3] smbd/error.c:60(error_packet_set)
  error packet at smbd/sesssetup.c(122) cmd=115 (SMBsesssetupX) NT_STATUS_LOGON_FAILURE
[2014/06/27 09:06:42,  3] smbd/process.c:1459(process_smb)
  Transaction 3 of length 142 (0 toread)
[2014/06/27 09:06:42,  3] smbd/process.c:1273(switch_message)
  switch message SMBsesssetupX (pid 20548) conn 0x0
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:1404(reply_sesssetup_and_X)
  wct=12 flg2=0xc807
[2014/06/27 09:06:42,  2] smbd/sesssetup.c:1360(setup_new_vc_session)
  setup_new_vc_session: New VC == 0, if NT4.x compatible we would close all old resources.
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:1160(reply_sesssetup_and_X_spnego)
  Doing spnego session setup
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:1202(reply_sesssetup_and_X_spnego)
  NativeOS=[] NativeLanMan=[] PrimaryDomain=[]
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:786(reply_spnego_negotiate)
  reply_spnego_negotiate: Got secblob of size 40
[2014/06/27 09:06:42,  3] libsmb/ntlmssp.c:62(debug_ntlmssp_flags)
  Got NTLMSSP neg_flags=0xe2088297
[2014/06/27 09:06:42,  3] smbd/process.c:1459(process_smb)
  Transaction 4 of length 474 (0 toread)
[2014/06/27 09:06:42,  3] smbd/process.c:1273(switch_message)
  switch message SMBsesssetupX (pid 20548) conn 0x0
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:1404(reply_sesssetup_and_X)
  wct=12 flg2=0xc807
[2014/06/27 09:06:42,  2] smbd/sesssetup.c:1360(setup_new_vc_session)
  setup_new_vc_session: New VC == 0, if NT4.x compatible we would close all old resources.
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:1160(reply_sesssetup_and_X_spnego)
  Doing spnego session setup
[2014/06/27 09:06:42,  3] smbd/sesssetup.c:1202(reply_sesssetup_and_X_spnego)
  NativeOS=[] NativeLanMan=[] PrimaryDomain=[]
[2014/06/27 09:06:42,  3] libsmb/ntlmssp.c:745(ntlmssp_server_auth)
  Got user=[Brientje] domain=[clientPC] workstation=[clientPC] len1=24 len2=222
[2014/06/27 09:06:42,  3] smbd/map_username.c:188(map_username)
  Mapped user Brientje to pluto_brientje
[2014/06/27 09:06:42,  3] auth/auth.c:222(check_ntlm_password)
  check_ntlm_password:  Checking password for unmapped user [clientPC]\[Brientje]@[clientPC] with the new password interface
[2014/06/27 09:06:42,  3] auth/auth.c:225(check_ntlm_password)
  check_ntlm_password:  mapped user is: [CORIUS]\[pluto_brientje]@[clientPC]
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:210(push_sec_ctx)
  push_sec_ctx(0, 0) : sec_ctx_stack_ndx = 1
[2014/06/27 09:06:42,  3] smbd/uid.c:428(push_conn_ctx)
  push_conn_ctx(0) : conn_ctx_stack_ndx = 0
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 1
[2014/06/27 09:06:42,  3] smbd/sec_ctx.c:418(pop_sec_ctx)
  pop_sec_ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:42,  3] auth/auth_sam.c:282(check_sam_security)
  check_sam_security: Couldn't find user 'pluto_brientje' in passdb.
[2014/06/27 09:06:42,  2] auth/auth.c:320(check_ntlm_password)
  check_ntlm_password:  Authentication for user [Brientje] -> [pluto_brientje] FAILED with error NT_STATUS_NO_SUCH_USER
[2014/06/27 09:06:42,  3] smbd/error.c:60(error_packet_set)
  error packet at smbd/sesssetup.c(122) cmd=115 (SMBsesssetupX) NT_STATUS_LOGON_FAILURE
[2014/06/27 09:06:48,  3] smbd/process.c:1459(process_smb)
  Transaction 5 of length 142 (0 toread)
[2014/06/27 09:06:48,  3] smbd/process.c:1273(switch_message)
  switch message SMBsesssetupX (pid 20548) conn 0x0
[2014/06/27 09:06:48,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:1404(reply_sesssetup_and_X)
  wct=12 flg2=0xc807
[2014/06/27 09:06:48,  2] smbd/sesssetup.c:1360(setup_new_vc_session)
  setup_new_vc_session: New VC == 0, if NT4.x compatible we would close all old resources.
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:1160(reply_sesssetup_and_X_spnego)
  Doing spnego session setup
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:1202(reply_sesssetup_and_X_spnego)
  NativeOS=[] NativeLanMan=[] PrimaryDomain=[]
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:786(reply_spnego_negotiate)
  reply_spnego_negotiate: Got secblob of size 40
[2014/06/27 09:06:48,  3] libsmb/ntlmssp.c:62(debug_ntlmssp_flags)
  Got NTLMSSP neg_flags=0xe2088297
[2014/06/27 09:06:48,  3] smbd/process.c:1459(process_smb)
  Transaction 6 of length 474 (0 toread)
[2014/06/27 09:06:48,  3] smbd/process.c:1273(switch_message)
  switch message SMBsesssetupX (pid 20548) conn 0x0
[2014/06/27 09:06:48,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:1404(reply_sesssetup_and_X)
  wct=12 flg2=0xc807
[2014/06/27 09:06:48,  2] smbd/sesssetup.c:1360(setup_new_vc_session)
  setup_new_vc_session: New VC == 0, if NT4.x compatible we would close all old resources.
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:1160(reply_sesssetup_and_X_spnego)
  Doing spnego session setup
[2014/06/27 09:06:48,  3] smbd/sesssetup.c:1202(reply_sesssetup_and_X_spnego)
  NativeOS=[] NativeLanMan=[] PrimaryDomain=[]
[2014/06/27 09:06:48,  3] libsmb/ntlmssp.c:745(ntlmssp_server_auth)
  Got user=[brientje] domain=[clientPC] workstation=[clientPC] len1=24 len2=222
[2014/06/27 09:06:48,  3] smbd/map_username.c:188(map_username)
  Mapped user brientje to pluto_brientje
[2014/06/27 09:06:48,  3] auth/auth.c:222(check_ntlm_password)
  check_ntlm_password:  Checking password for unmapped user [clientPC]\[brientje]@[clientPC] with the new password interface
[2014/06/27 09:06:48,  3] auth/auth.c:225(check_ntlm_password)
  check_ntlm_password:  mapped user is: [CORIUS]\[pluto_brientje]@[clientPC]
[2014/06/27 09:06:48,  3] smbd/sec_ctx.c:210(push_sec_ctx)
  push_sec_ctx(0, 0) : sec_ctx_stack_ndx = 1
[2014/06/27 09:06:48,  3] smbd/uid.c:428(push_conn_ctx)
  push_conn_ctx(0) : conn_ctx_stack_ndx = 0
[2014/06/27 09:06:48,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 1
[2014/06/27 09:06:48,  3] smbd/sec_ctx.c:418(pop_sec_ctx)
  pop_sec_ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:06:48,  3] auth/auth_sam.c:282(check_sam_security)
  check_sam_security: Couldn't find user 'pluto_brientje' in passdb.
[2014/06/27 09:06:48,  2] auth/auth.c:320(check_ntlm_password)
  check_ntlm_password:  Authentication for user [brientje] -> [pluto_brientje] FAILED with erro
r NT_STATUS_NO_SUCH_USER
[2014/06/27 09:06:48,  3] smbd/error.c:60(error_packet_set)
  error packet at smbd/sesssetup.c(122) cmd=115 (SMBsesssetupX) NT_STATUS_LOGON_FAILURE
[2014/06/27 09:07:04,  0] lib/util_sock.c:539(read_fd_with_timeout)
[2014/06/27 09:07:04,  0] lib/util_sock.c:1498(get_peer_addr_internal)
  getpeername failed. Error was Transport endpoint is not connected
  read_fd_with_timeout: client 0.0.0.0 read error = Connection reset by peer.
[2014/06/27 09:07:04,  3] smbd/sec_ctx.c:310(set_sec_ctx)
  setting sec ctx (0, 0) - sec_ctx_stack_ndx = 0
[2014/06/27 09:07:04,  3] smbd/connection.c:31(yield_connection)
  Yielding connection to
[2014/06/27 09:07:04,  3] smbd/server.c:849(exit_server_common)
  Server exit (failed to receive smb request)
Version: linuxMCE 1404, running virtual on ESXi

Orbiters: ASUS eeePAD, Nexus 5, Huwai, web
Automation: EIB technology, KNX IP ROUTER 750
Phones: Cisco 7912-7940-7960
Camera's: Foscam POE

brononius

  • Guru
  • ****
  • Posts: 454
  • Trying to keep it simple and centralized...
    • View Profile
    • OnIrIa - linuxMCE blog
Re: Samba issue
« Reply #2 on: June 27, 2014, 10:02:35 am »
Not sure if this is the solution, but it seems to help to run 'smbpasswd -a'

Quote
smbpasswd -a pluto_brientje
   password:
   Retype new SMB password:
Added user pluto_brientje.



Afterwards, i'm able to login with the samba clients.
Version: linuxMCE 1404, running virtual on ESXi

Orbiters: ASUS eeePAD, Nexus 5, Huwai, web
Automation: EIB technology, KNX IP ROUTER 750
Phones: Cisco 7912-7940-7960
Camera's: Foscam POE

Marie.O

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 3675
  • Wastes Life On LinuxMCE Since 2007
    • View Profile
    • My Home
Re: Samba issue
« Reply #3 on: June 27, 2014, 11:55:58 am »
looks like you've updated the samba server to a version using a different passwd database/ passwd storage.

brononius

  • Guru
  • ****
  • Posts: 454
  • Trying to keep it simple and centralized...
    • View Profile
    • OnIrIa - linuxMCE blog
Re: Samba issue
« Reply #4 on: June 27, 2014, 12:27:19 pm »
you've updated the samba server

I can't recall that I've done it specially for something. Just some apt-get updates, and I'm playing around with backuppc.

For me, it's working now, and I don't have so many users, so it's a quick solution.
But if I can do/test anything, let me know...
Version: linuxMCE 1404, running virtual on ESXi

Orbiters: ASUS eeePAD, Nexus 5, Huwai, web
Automation: EIB technology, KNX IP ROUTER 750
Phones: Cisco 7912-7940-7960
Camera's: Foscam POE