mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-04-29 23:24:55 +02:00
pdbedit, smbpassword: add page & improve comments (#7545)
This commit is contained in:
parent
9e94d88d31
commit
34f822e792
2 changed files with 29 additions and 7 deletions
21
pages/linux/pdbedit.md
Normal file
21
pages/linux/pdbedit.md
Normal file
|
@ -0,0 +1,21 @@
|
|||
# pdbedit
|
||||
|
||||
> Edit the Samba user database.
|
||||
> For simple user add/remove/password, you can also use `smbpasswd`.
|
||||
> More information: <https://manned.org/pdbedit>.
|
||||
|
||||
- List all Samba users (use verbose flag to show their settings):
|
||||
|
||||
`sudo pdbedit --list --verbose`
|
||||
|
||||
- Add an existing Unix user to Samba (will prompt for password):
|
||||
|
||||
`sudo pdbedit --user {{username}} --create`
|
||||
|
||||
- Remove a Samba user:
|
||||
|
||||
`sudo pdbedit --user {{username}} --delete`
|
||||
|
||||
- Reset a Samba user's failed password counter:
|
||||
|
||||
`sudo pdbedit --user {{username}} --bad-password-count-reset`
|
|
@ -1,20 +1,21 @@
|
|||
# smbpasswd
|
||||
|
||||
> Change a user's SMB password.
|
||||
> Samba users must also have a local Unix account.
|
||||
> Add/remove a Samba user or change its password.
|
||||
> Samba users must have an existing local Unix account.
|
||||
> More information: <https://manned.org/smbpasswd.8>.
|
||||
|
||||
- Change the current user's SMB password:
|
||||
|
||||
`smbpasswd`
|
||||
|
||||
- Add a specified user to Samba and set password(user should already exist in system):
|
||||
- Add a specified user to Samba and set password (user should already exist in system):
|
||||
|
||||
`smbpasswd -a {{username}}`
|
||||
`sudo smbpasswd -a {{username}}`
|
||||
|
||||
- Modify an existing Samba user's password:
|
||||
|
||||
`smbpasswd {{username}}`
|
||||
`sudo smbpasswd {{username}}`
|
||||
|
||||
- Delete a Samba user:
|
||||
- Delete a Samba user (use `pdbedit` instead if the Unix account has been deleted):
|
||||
|
||||
`smbpasswd -x {{username}}`
|
||||
`sudo smbpasswd -x {{username}}`
|
||||
|
|
Loading…
Add table
Reference in a new issue