Sunday, June 14, 2020

10 Useful Unix Commands - Must for Debugging


Useful Unix Commands for Debugging with Examples


This is my list of commands, found useful while debugging issues in logs, servers process, etc., With regard to the list, will share the commands which I use in the real world scenarios..

  • lsof - Used to get the list of "open files" in linux and all the processes that opened them. I find them useful to search / find the processes that are listening on a given Port.          
            lsof -i tcp:8443

This will give the Process ID, service name which listens on the port (8443) and much more.. Particularly useful to debug different services running on the same server. 

  • netstat
  • find
  • grep
  • sed
  • curl
  • cut
  • xargs
  • for 
  • ssh/scp - Quickly copy an artifact or a log file from one node to another, without downloading to your host system?
    scp <file_name> <username>@<destination-host>:<destination-folder>


What's your list..? comment them..

No comments:

Post a Comment

feedback?

Root password of a Docker container

Root User Privileges in a Docker Container Often we will come across situations where the default user setting in docker container will be n...