Shell Commands and Examples - ilya-khadykin/notes-outdated GitHub Wiki
Useful shell commands and exaples
lsb_release -a # Ubuntu specific version information
uname -a
curl -OL example.com/code.zip
# -O -> save file using the same name as on the server
# -L -> follow redirects
netstat -tlpn | grep mysql
Copy the process id from ps -e
command and then run the following:
ps x | grep <process-id>
ps -ef | grep mysql
grep port /etc/mysql/my.cnf
grep -riI ssmtp /var/log # finds ssmtp logs
date
cal
df
free
pwd
cd
ls