Table of Contents
What does the ps command do in Linux?
Linux provides us a utility called ps for viewing information related with the processes on a system which stands as abbreviation for “Process Status”. ps command is used to list the currently running processes and their PIDs along with some other information depends on different options.
What do the options a x e l f do when used with the command ps?
The options A and e provide summarized overview of running processes. To print the detailed overview, use the options f (full format) and F (extra full format) with these options. To view the same output in BSD Unix style, use the options “aux”.
What is ps output?
ps displays status information about processes, and optionally, the threads running under each process. By default, for each process associated with the user’s terminal, ps displays the process ID (PID), TTY, processor time used (TIME), and name of the command (COMM).
What is TTY on Linux?
Type. Command. In computing, tty is a command in Unix and Unix-like operating systems to print the file name of the terminal connected to standard input. tty stands for TeleTYpewriter.
How do you grep a pipe?
grep is very often used as a “filter” with other commands. It allows you to filter out useless information from the output of commands. To use grep as a filter, you must pipe the output of the command through grep . The symbol for pipe is ” | “.
What is this in Linux?
~ means the home directory of the logged on user whereas ~/ means the path to the beginning of a directory. From here: The tilde (~) is a Linux “shortcut” to denote a user’s home directory. Thus tilde slash (~/) is the beginning of a path to a file or directory below the user’s home directory.
What is PTS and tty in Linux?
A tty is a regular terminal device (the console on your server, for example). A pts is a psuedo terminal slave (an xterm or an ssh connection).
How to use the diff command in Linux system?
Linux system offers two different ways to view the diff command output i.e. context mode and unified mode. -c (context) : To view differences in context mode, use the -c option. Lets try to understand this with example, we have two files file1.txt and file2.txt:
Are all the lines in two files the same in Unix?
All the other lines in the two files are the same. In the comm output, we also see the content of both files in columns, but the key is the indentation. The rightmost column displays the content that is the same in both files — up to a point.
What are the SSH protocol options in the command line?
SSH Command Line Options SSH Option -1 Instructs ssh to use protocol version 1 -2 Instructs ssh to use protocol version 2. -4 Permits only IPv4 addresses. -6 Permits only IPv6 addresses.
What does the first line of the diff output contain?
The first line of the diff output will contain: Line numbers corresponding to the second file. Like in our case, 0a1 which means after lines 0 (at the very beginning of file) you have to add Tamil Nadu to match the second file line number 1. It then tells us what those lines are in each file preceeded by the symbol: