LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 959|回复: 1

[已解决]samba账户密码如何重置?

[复制链接]
发表于 2008-11-10 15:21:49 | 显示全部楼层 |阅读模式
按wiki默认配置samba后,由于windows重装,把密码忘了,现在网上邻居访问看到却进不去了,请问如何重设密码?

解决方法:在root下删除原来的账户,再重新加入即可。感谢楼下回帖。:Coffee:

  1. smbpasswd -help
  2. When run by root:
  3.     smbpasswd [options] [username]
  4. otherwise:
  5.     smbpasswd [options]

  6. options:
  7.   -L                   local mode (must be first option)
  8.   -h                   print this usage message
  9.   -s                   use stdin for password prompt
  10.   -c smb.conf file     Use the given path to the smb.conf file
  11.   -D LEVEL             debug level
  12.   -r MACHINE           remote machine
  13.   -U USER              remote username
  14. extra options when run by root or in local mode:
  15.   -a                   add user
  16.   -d                   disable user
  17.   -e                   enable user
  18.   -i                   interdomain trust account
  19.   -m                   machine trust account
  20.   -n                   set no password
  21.   -W                   use stdin ldap admin password
  22.   -w PASSWORD          ldap admin password
  23.   -x                   delete user
  24.   -R ORDER             name resolve order
复制代码


先使用[color="Red"]sudo smbpasswd -x [username]
再使用[color="Red"]sudo smbpasswd -a [username]
发表于 2008-11-10 17:19:01 | 显示全部楼层
smbpasswd
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表