Last active
September 20, 2018 10:49
-
-
Save delameko/95008f295b5779bf6c7e2d7f11ff129d to your computer and use it in GitHub Desktop.
Shell command cheatsheet
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
############# | |
# Processes # | |
############# | |
# Finding a running process | |
ps aux | grep <processname> | |
pgrep <processname> | |
# Killing processes | |
# | |
# Signal Name | Signal Value | Behaviour | |
# ------------ -------------- ---------- | |
# SIGHUP | 1 | Hangup | |
# SIGKILL | 9 | Kill Signal | |
# SIGTERM | 15 | Terminate | |
# | |
kill -9 <pid> | |
kill -SIGTERM <pid> | |
pkill <processname> | |
killall <processname> | |
############ | |
# Services # | |
############ | |
# systemd | |
systemctl status service-name | |
systemctl --user status service-name | |
# see log for service | |
journalctl -u service-name.service | |
# only see current boot messages | |
journalctl -u service-name.service -b | |
################# | |
# Miscellaneous # | |
################# | |
# Print hardware with the drivers in use | |
sudo lspci -v |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment