Skip to content

Instantly share code, notes, and snippets.

@pictolearn
Created May 16, 2019 15:29
Show Gist options
  • Save pictolearn/4da4abdbf7b2e09ca2629b7fa23a8810 to your computer and use it in GitHub Desktop.
Save pictolearn/4da4abdbf7b2e09ca2629b7fa23a8810 to your computer and use it in GitHub Desktop.
UNIX_HELPER_COMMANDS
# Find out what is running on what port in linux
# Lists all ports
netstat -l
# Specify a port and find out which process is using it
netstat -ltnp | grep -w ':80'
# Look for what process is running on the unix box
ps -ef | grep <app-name>
Ex: ps -eg | grep nginx
#Notes on the curl command
# -k is required if you are using https, remove it if that is not the case
# -v is
curl <url> -v -k
Ex: curl localhost:80 -v (Gives you the webserver running locally on your machine)
curl <ip-addr>:<port> -v (Gives you the output of any response received from server)
Note: This is as good as trying to run it from the browser.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment