ps: "A different set of processes can be selected for display by using any combination of the
-a, -G, -g, -p, -T, -t, -U, and -uoptions. If more than one of these options are given, then ps will select all processes which are matched by at least one of the given options".
systemdprocess starts during boot time, and remains active until the shutdown. It's the parent process for all other process in the system.
ps jcommands respectively.
kill -lto see the available signals to send to processes, like interrupt, terminate, resume, etc.
killallto operate on multiple processes using their executable name. Use
pkillfor filtering with more options.
pgrepto view process parent/child tree and search for processes by pattern.
uid, and each group is associated with
-aGfor users to replace group or append group, respectively:
changecommand sets the password policy in the system.
su - <username>to switch to the specified user. which will promote for her password. Running the command without username will switch to the root user. To avoid cases where password is not available, use
sudoto switch accounts using current user password only and according to rules in
sudo -ito gain an interactive root shell.
dateto print the current date and time or others in the past and future:
stderrwhere the first is for input stream and the latters for output and error streams.
>). You can explicity redirect to
sshcommand used to connect to servers in secure manner using OpenSSH library using public key cryptography. The configuration and known hosts are kept under
/etc/sshsystem-wide or in
~/.ssh/in current user's home directory. On the other hand
scpis used for secure copy on secure shell fashion.
ssh-keygen: to generate new key pairs.
ssh-copy-id: to copy the public key to the remote machines.
ssh-agent: to simplify working with the private key passphrase if used.
ssh-add: to cache the passphrase in the current session.
chmodcommand and can be using symbols or digits.
abasis for the user, group, others, or all. Whereas, the digits are written for all at once in sequence for user, group, and others. Examples are below for both cases:
chownis used to change the ownership of folder/files to users or groups respectively.
chgrpis a shortcut to group change only. The root or the owner are only people can change ownership and in the latter, she needs to be part of the new target group before the change.
sgid s, and
sticky twhich control executable nature of files to be of owner users, and groups regardless of the current user. The last is to restrict deletion for only the root and owner always.
systemctlis the command used to list, manage, and check background processes or so called
disabledindicate wether a service is lanuched on startup or not. The subcommands
disablecan be used to control this aspect.
statuscommand or its state shortcuts:
reload-or-restartto control daemons.
unmaskcommands can be used to point a deamons config to
dev/nullthen back to normal respectively.
crondis responsible for managing the user's and system's scheduled jobs. Use the command
crontabto manage jobs and their files in the user account or in the system wide
lscputo see the system's CPU in use and other details.
/var/logdirectory. There are two categories of logs: 1. essential system logs via
journald, that are wiped across boots by default (can be configured to persist). 2.
rsysloglogs that persist by default and organized inside
/var/log/folder. Mainly, the logging mechanism in Linux follows the standard
syslogprotocol for the system's messages, events, security incidents, mailing, and jobs logs, while other programs may or may not follow
tailcommands to interactively see or follow the logs.
rsyslogservice and manage it as any daemon:
journalctlto view and follow the system's
journaldlog entries, which resides in
DHCP) configured in
/etc/resolv.confor manually in
pingutiltiy helps for connectivity checking:
aptis the package manager, whereas for Fedora / RHEL,
/devdirectory by the OS, and has letters naming convention such as
/dev/vda, and appended numbers in case of partitions
/dev/sda3. The attachment of the block device into the system is done through mounting it to a directory in the system.
lsofcommand lists all active processes using the block device.
/etc/fstabfile to determine devices to mount on the boot time.
monuntto check and mount filesystem devices, respectively.
mancommand to lookup the manual information on commands or topics in the system.
infocommand is the GNU documentation tool and provide more detailed materials.
man -K <keywordto search across manual).