分页: 1 / 1

更换ip地址后无法连接samba

发表于 : 2015-10-01 11:48
vickycq
重现步骤

1. 连接有线,ip 为 192.168.1.100,Thunar 中打开 smb://192.168.1.103,正常
2. Thunar 中 umount smb://192.168.1.103
3. 断开有线,连接无线,ip 更换为 192.168.1.101
4. Thunar 中无法打开 smb://192.168.1.103

日志:

代码: 全选

Oct 01 11:45:04 debian org.gtk.vfs.Daemon[1307]: ### SMB-BROWSE: update_cache - updating...
Oct 01 11:45:04 debian org.gtk.vfs.Daemon[1307]: parsed path: fname='smb://192.168.1.103/' server='192.168.1.103' share='' path='' options=''
Oct 01 11:45:04 debian org.gtk.vfs.Daemon[1307]: SMBC_check_options(): server='192.168.1.103' share='' path='' options=''
Oct 01 11:45:04 debian org.gtk.vfs.Daemon[1307]: ### SMB-BROWSE: looking up cached server '192.168.1.103'\'IPC$', user 'WORKGROUP';'blah'
Oct 01 11:45:04 debian org.gtk.vfs.Daemon[1307]: ### SMB-BROWSE:   returning 0x7fcbfc011bb0
Oct 01 11:45:24 debian org.gtk.vfs.Daemon[1307]: net_share_enum_rpc pipe open fail!
Oct 01 11:45:44 debian org.gtk.vfs.Daemon[1307]: NetShareEnum failed

Re: 更换ip地址后无法连接samba

发表于 : 2015-10-01 17:24
vickycq
http://serverfault.com/questions/369608 ... nux-server

代码: 全选

mount -t cifs -o username=user,password=pass\!word //192.168.XX.XX/someshare /mnt/localdir
After this procedure, on my machine the cache was cleared, so I could make umount and mount via the fstab.

Alternatively, the cache is active until server restart, and after the new credentials will be applied via fstab configuration.