Skip to content

List of useful commands

Daniel Speichert edited this page Dec 27, 2015 · 3 revisions
  • start <unit> (eg. start tfs) - start service (as a user)
  • stop <unit> (eg. stop tfs) - stop service (as a user)
  • restart <unit> (eg. restart tfs) - restart service (as a user)
  • status <unit> (eg. status tfs) - show status for a service (as a user)
  • serverip (otsmanager bash alias) - show server IP
  • duedate (otsmanager bash alias) - show server expiration date
  • mc - midnight commander
  • nano - another file editor
  • df -h - show disk usage
  • du -hs /home - count disk usage for directory /home
  • netstat -lntp - list ports and programs that are listening for TCP connections
  • crontab -e - edit cron jobs
  • sudo <command> - execute as root
  • sudo reboot - reboot whole server
  • sudo systemctl restart nginx - restart nginx webserver
  • sudo systemctl restart mysql - restart MySQL server
  • sudo aptitude - manage system packages
  • sudo aptitude update && sudo aptitude -y full-upgrade - do full system update
Clone this wiki locally