Différences
Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision | Révision précédente | ||
elearning:workbooks:redhat:rh124:l102 [2024/09/25 07:56] – created admin | elearning:workbooks:redhat:rh124:l102 [2024/09/25 12:40] (Version actuelle) – admin | ||
---|---|---|---|
Ligne 5: | Ligne 5: | ||
Dernière mise-à-jour : ~~LASTMOD~~ | Dernière mise-à-jour : ~~LASTMOD~~ | ||
- | ======LCF403 | + | ======RH12403 |
=====Contenu du Module===== | =====Contenu du Module===== | ||
- | * **LCF403 | + | * **RH12403 |
* Contenu du Module | * Contenu du Module | ||
* LAB #1 - Aide des Commandes | * LAB #1 - Aide des Commandes | ||
Ligne 26: | Ligne 26: | ||
< | < | ||
- | [root@centos8 | + | [trainee@redhat9 ~]$ su - |
+ | Password: fenestros | ||
+ | [root@redhat9 | ||
ifconfig is / | ifconfig is / | ||
</ | </ | ||
Ligne 33: | Ligne 35: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
Usage: | Usage: | ||
ifconfig [-a] [-v] [-s] < | ifconfig [-a] [-v] [-s] < | ||
Ligne 73: | Ligne 75: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
type is a shell builtin | type is a shell builtin | ||
</ | </ | ||
Ligne 80: | Ligne 82: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
- | GNU bash, version | + | GNU bash, version |
These shell commands are defined internally. | These shell commands are defined internally. | ||
Type `help name' to find out more about the function `name' | Type `help name' to find out more about the function `name' | ||
Ligne 89: | Ligne 91: | ||
A star (*) next to a name means that the command is disabled. | A star (*) next to a name means that the command is disabled. | ||
- | | + | |
- | (( expression )) | + | (( expression )) if COMMANDS; then COMMANDS; [ elif COMMANDS;> |
- | . filename [arguments] | + | . filename [arguments] |
- | : | + | : |
- | [ arg... ] | + | [ arg... ] let arg [arg ...] |
- | [[ expression ]] | + | [[ expression ]] local [option] name[=value] ... |
- | alias [-p] [name[=value] ... ] | + | alias [-p] [name[=value] ... ] logout [n] |
- | bg [job_spec ...] mapfile [-d delim] [-n count] [-O origin] [-s count] [-t] [-u fd] [-C callback] [-c quantum] | + | bg [job_spec ...] |
- | bind [-lpsvPSVX] [-m keymap] [-f filename] [-q name] [-u name] [-r keyseq] [-x keyseq: | + | bind [-lpsvPSVX] [-m keymap] [-f filename] [-> |
- | break [n] printf [-v var] format [arguments] | + | break [n] |
- | | + | |
- | | + | |
- | case WORD in [PATTERN [| PATTERN]...) | + | case WORD in [PATTERN [| PATTERN]...) |
- | cd [-L|[-P [-e]] [-@]] [dir] | + | cd [-L|[-P [-e]] [-@]] [dir] readarray |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | dirs [-clpv] [+N] [-N] | + | dirs [-clpv] [+N] [-N] suspend [-f] |
- | | + | |
- | echo [-neE] [arg ...] time [-p] pipeline | + | echo [-neE] [arg ...] |
- | | + | |
- | eval [arg ...] | + | eval [arg ...] trap [-lp] [[arg] signal_spec ...] |
- | exec [-cl] [-a name] [command [arguments | + | exec [-cl] [-a name] [command [argument |
- | exit [n] | + | exit [n] type [-afptP] name [name ...] |
- | | + | |
- | | + | |
- | fc [-e ename] [-lnr] [first] [last] or fc -s [pat=rep] [command] | + | fc [-e ename] [-lnr] [first] [last] or fc -s > |
- | fg [job_spec] | + | fg [job_spec] |
- | for NAME [in WORDS ... ] ; do COMMANDS; done | + | for NAME [in WORDS ... ] ; do COMMANDS; done unset [-f] [-v] [-n] [name ...] |
- | for (( exp1; exp2; exp3 )); do COMMANDS; | + | for (( exp1; exp2; exp3 )); do COMMANDS; |
- | | + | |
- | | + | |
- | hash [-lr] [-p pathname] [-dt] [name ...] while COMMANDS; do COMMANDS; done | + | hash [-lr] [-p pathname] [-dt] [name ...] |
- | help [-dms] [pattern ...] { COMMANDS ; } | + | help [-dms] [pattern ...] |
</ | </ | ||
Ligne 132: | Ligne 134: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
type: type [-afptP] name [name ...] | type: type [-afptP] name [name ...] | ||
Display information about command type. | Display information about command type. | ||
Ligne 166: | Ligne 168: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
- | BASH_BUILTINS(1) General Commands Manual | + | PASSWD(1) User utilities |
NAME | NAME | ||
- | bash, :, ., [, alias, bg, bind, break, builtin, caller, cd, command, compgen, complete, compopt, continue, declare, dirs, disown, echo, enable, eval, exec, exit, export, false, fc, | + | passwd |
- | fg, getopts, hash, help, history, jobs, kill, let, local, logout, mapfile, popd, printf, pushd, pwd, read, readonly, return, set, shift, shopt, source, suspend, | + | |
- | true, type, typeset, ulimit, umask, unalias, unset, wait - bash built-in commands, see bash(1) | + | |
- | BASH BUILTIN COMMANDS | + | SYNOPSIS |
- | Unless otherwise noted, each builtin command documented in this section as accepting options preceded by - accepts | + | passwd [-k] [-l] [-u [-f]] [-d] [-e] [-n mindays] [-x maxdays] [-w warndays] [-i inactivedays] [-S] [--stdin] [-?] [--usage] [username] |
- | | + | |
- | | + | |
- | this interpretation. | + | |
- | : | + | |
- | No effect; the command does nothing beyond expanding arguments and performing any specified redirections. | + | |
- | . filename [arguments] | + | DESCRIPTION |
- | source filename [arguments] | + | The passwd utility is used to update user's authentication token(s). |
- | Read and execute commands from filename in the current shell environment | + | |
- | | + | |
- | | + | cate and then update a user's password. |
- | | + | |
- | | + | A simple entry in the global Linux-PAM configuration |
- | | + | |
- | if no commands are executed), and false if filename | + | # |
+ | # passwd service entry that does strength checking of | ||
+ | # a proposed password before updating it. | ||
+ | # | ||
+ | passwd password requisite pam_cracklib.so retry=3 | ||
+ | passwd password required pam_unix.so use_authtok | ||
+ | # | ||
+ | |||
+ | Note, other module types are not required for this application to function correctly. | ||
+ | |||
+ | OPTIONS | ||
+ | -k, --keep-tokens | ||
+ | | ||
+ | |||
+ | -l, --lock | ||
+ | This option | ||
+ | | ||
+ | chage -E 0 user command instead for full account locking. | ||
+ | |||
+ | | ||
+ | | ||
+ | |||
+ | -u, --unlock | ||
+ | | ||
+ | wordless account (it will not unlock an account that has only " | ||
+ | |||
+ | -d, --delete | ||
+ | This is a quick way to delete a password for an account. It will set the named account passwordless. Available to root only. | ||
+ | |||
+ | | ||
+ | |||
+ | -e, --expire | ||
+ | This is a quick way to expire a password for an account. The user will be forced to change the password during the next login attempt. | ||
- | alias [-p] [name[=value] ...] | + | -f, --force |
- | Alias with no arguments or with the -p option prints the list of aliases in the form alias name=value on standard output. | + | |
- | | + | |
- | list for which no value is supplied, the name and value of the alias is printed. | + | |
- | bg [jobspec ...] | + | -n, --minimum DAYS |
- | | + | |
- | returns 0 unless run when job control is disabled or, when run with job control enabled, any specified jobspec was not found or was started without job control. | + | |
- | bind [-m keymap] [-lpsvPSVX] | + | -x, --maximum DAYS |
- | bind [-m keymap] [-q function] [-u function] [-r keyseq] | + | |
- | bind [-m keymap] -f filename | + | |
- | bind [-m keymap] | + | |
- | bind [-m keymap] keyseq: | + | |
- | bind [-m keymap] keyseq: | + | |
- | | + | |
- | it would appear | + | |
- | | + | |
</ | </ | ||
Ligne 256: | Ligne 274: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
- | passwd: / | + | passwd: / |
</ | </ | ||
Ligne 263: | Ligne 281: | ||
| | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
- | PASSWD(5) Linux Programmer' | + | passwd(5) File Formats |
NAME | NAME | ||
Ligne 270: | Ligne 288: | ||
DESCRIPTION | DESCRIPTION | ||
- | The /etc/passwd file is a text file that describes user login accounts for the system. | + | |
- | user IDs to usernames), but write access only for the superuser. | + | usernames), but write access only for the superuser. |
- | In the good old days there was no great problem with this general read permission. | + | In the good old days there was no great problem with this general read permission. |
- | password, and moreover the basic assumption used to be that of a friendly user-community. | + | moreover |
- | an ' | + | password field, and the encrypted passwords are in / |
- | If the encrypted password, whether in /etc/passwd or in / | + | If the encrypted password, whether in /etc/passwd or in / |
- | intentionally disabled | + | abled in applications, |
If the encrypted password in /etc/passwd is " | If the encrypted password in /etc/passwd is " | ||
- | | + | |
- | or herself | + | password. |
If you create a new login, first put an asterisk (*) in the password field, then use passwd(1) to set it. | If you create a new login, first put an asterisk (*) in the password field, then use passwd(1) to set it. | ||
Ligne 301: | Ligne 319: | ||
| | ||
- | | + | |
- | ple, finger(1)) display information from this field. | + | display information from this field. |
- | | + | |
- | reported: " | + | " |
+ | |||
+ | | ||
+ | |||
+ | | ||
+ | set the SHELL environment variable. | ||
+ | |||
+ | FILES | ||
+ | / | ||
+ | |||
+ | NOTES | ||
+ | If you want to create user groups, there must be an entry in /etc/group, or no group will exist. | ||
+ | |||
+ | | ||
+ | | ||
+ | |||
+ | SEE ALSO | ||
| | ||
</ | </ | ||
Ligne 318: | Ligne 352: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
+ | Purging old database entries in / | ||
Processing manual pages under / | Processing manual pages under / | ||
- | Updating index cache for path `/ | + | Purging old database entries in / |
- | Checking for stray cats under / | + | Processing manual pages under /usr/share/man... |
- | Checking for stray cats under /var/cache/man/overrides... | + | Purging old database entries in / |
- | ... | + | Processing manual pages under / |
+ | Purging old database entries in / | ||
+ | Processing manual pages under /usr/share/man/ru... | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
Processing manual pages under / | Processing manual pages under / | ||
+ | Purging old database entries in / | ||
+ | Processing manual pages under / | ||
Purging old database entries in / | Purging old database entries in / | ||
Processing manual pages under / | Processing manual pages under / | ||
Ligne 330: | Ligne 410: | ||
0 manual pages were added. | 0 manual pages were added. | ||
0 stray cats were added. | 0 stray cats were added. | ||
- | 17 old database entries were purged. | + | 24 old database entries were purged. |
</ | </ | ||
Ligne 336: | Ligne 416: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
- | openssl-passwd (1ssl) - compute password hashes | + | |
- | passwd (1) - update user's authentication tokens | + | |
passwd (5) - password file | passwd (5) - password file | ||
+ | passwd (1) - update user's authentication tokens | ||
+ | passwd (1ossl) | ||
</ | </ | ||
Ligne 347: | Ligne 427: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
chgpasswd (8) - update group passwords in batch mode | chgpasswd (8) - update group passwords in batch mode | ||
chpasswd (8) - update passwords in batch mode | chpasswd (8) - update passwords in batch mode | ||
Ligne 353: | Ligne 433: | ||
getpwent_r (3) - get passwd file entry reentrantly | getpwent_r (3) - get passwd file entry reentrantly | ||
gpasswd (1) - administer /etc/group and / | gpasswd (1) - administer /etc/group and / | ||
- | grub2-mkpasswd-pbkdf2 (1) - Generate a PBKDF2 | + | grub2-mkpasswd-pbkdf2 (1) - generate hashed |
lpasswd (1) - Change group or user password | lpasswd (1) - Change group or user password | ||
- | openssl-passwd (1ssl) - compute password hashes | + | openssl-passwd (1ossl) - compute password hashes |
pam_localuser (8) - require users to be listed in /etc/passwd | pam_localuser (8) - require users to be listed in /etc/passwd | ||
passwd (1) - update user's authentication tokens | passwd (1) - update user's authentication tokens | ||
+ | passwd (1ossl) | ||
passwd (5) - password file | passwd (5) - password file | ||
passwd2des (3) - RFS password encryption | passwd2des (3) - RFS password encryption | ||
pwhistory_helper (8) - Helper binary that transfers password hashes from passwd or shadow to opasswd | pwhistory_helper (8) - Helper binary that transfers password hashes from passwd or shadow to opasswd | ||
smbpasswd (5) - The Samba encrypted password file | smbpasswd (5) - The Samba encrypted password file | ||
- | sslpasswd (1ssl) | ||
</ | </ | ||
Ligne 394: | Ligne 474: | ||
< | < | ||
- | [root@centos8 | + | [root@redhat9 |
- | ... | + | |
File: dir, Node: Top, This is the top of the INFO tree. | File: dir, Node: Top, This is the top of the INFO tree. | ||
Ligne 421: | Ligne 500: | ||
Access modes. | Access modes. | ||
* Finding files: (find). | * Finding files: (find). | ||
- | * time: (time). | + | * Time: (time). |
Compression | Compression | ||
- | -----Info: (dir)Top, | + | * Gzip: (gzip). |
- | Welcome to Info version 6.5. Type H for help, h for tutorial. | + | |
+ | Editors | ||
+ | * nano: (nano). | ||
+ | |||
+ | Encryption | ||
+ | * Nettle: (nettle). | ||
+ | |||
+ | GNU Gettext Utilities | ||
+ | * autopoint: (gettext)autopoint Invocation. | ||
+ | Copy gettext infrastructure. | ||
+ | * envsubst: (gettext)envsubst Invocation. | ||
+ | Expand environment variables. | ||
+ | * gettextize: (gettext)gettextize Invocation. | ||
+ | Prepare a package for gettext. | ||
+ | * gettext: (gettext). | ||
+ | * ISO3166: (gettext)Country Codes. | ||
+ | ISO 3166 country codes. | ||
+ | * ISO639: (gettext)Language Codes. | ||
+ | ISO 639 language codes. | ||
+ | * msgattrib: (gettext)msgattrib Invocation. | ||
+ | Select part of a PO file. | ||
+ | * msgcat: (gettext)msgcat Invocation. | ||
+ | Combine several PO files. | ||
+ | * msgcmp: (gettext)msgcmp Invocation. | ||
+ | Compare a PO file and template. | ||
+ | * msgcomm: (gettext)msgcomm Invocation. | ||
+ | Match two PO files. | ||
+ | * msgconv: (gettext)msgconv Invocation. | ||
+ | -----Info: (dir)Top, | ||
+ | Welcome to Info version 6.7. Type H for help, h for tutorial. | ||
</ | </ | ||
----- | ----- | ||
Copyright © 2024 Hugh Norris. | Copyright © 2024 Hugh Norris. |