The tcpdump utility allows you to capture packets that flow within your network to assist in network troubleshooting. The following are several examples of using tcpdump with different options. Traffic is captured based on a specified filter. A variety of options exist, including: Options Description -D Print a list of network interfaces. -i Specify an […]
Archives for December 2017
How to use netstat command under Linux (Examples included)
The netstat command displays current TCP/IP network connections, routing tables, interface statistics, masquerade connections, and multicast memberships. The ss command provides dump socket statistics but also shows information similar to netstat. A number of command-line options and arguments exist, but netstat by itself displays a list of open sockets. Sockets are the interface between the […]
What are Symbolic Links (Soft Links) and how to create them under Linux
What is a Soft Link – Symbolic links link files and directories located across different file systems. – A symbolic link is a pointer that contains the path name to another file or directory. – The link makes the file or directory easier to access if it has a long path name. – A symbolic […]
Creating and Removing Files and Directories Under Linux
Here is an absolute beginner post on creating and removing Files and Directories under Linux. Creating Files The touch command creates a new empty file. $ touch filename You can create multiple files with the same command. If the file name or directory name already exists, the touch command updates the modification time and access […]
Understanding Variables in Bash Shell Under Linux
What are Variables? A variable is a temporary storage area in memory that is either set by the user, shell, system, or any program that loads another program. There are two categories of variables: The environment variables are valid for the duration of the session. The shell variables apply only to the current instance of […]
How to use command redirection under Linux
Shell metacharacters Shell metacharacters are specific characters, generally symbols, that have special meaning within the shell. The metacharacters supported in bash are listed as follows: | : Sends the output of the command to the left as the input to the command on the right of the symbol & : Runs the process in the […]
How to use shell expansions for generating shell tokens under Linux
Shell Expansions While working in a shell, sets or ranges of information are often repeated. Shell expansion helps generate a large number of shell tokens using compact syntaxes. The expansion is performed on the command line after the command is split into tokens. Of the many expansions available, the path name, file name, and brace […]
Beginners guide to vi editor (command line reference)
The vi editor is a command-line, interactive editor that you can use to create and modify text files. The vi editor is also the only text editor that you can use to edit certain system files without changing the permissions of the files. The Vim editor is an enhanced version of the vi editor. Accessing […]
How to use FTP under Linux to transfer files
Introduction to FTP FTP is a network protocol used for exchanging files over a TCP/IP network. FTP implements user-based password authentication. FTP also allows anonymous user access, where the password is usually a valid email address. You can access a remote system for exchanging files using the ftp command. # ftp hostname/IP address If you […]
How to use compress, zip, gzip commands under Linux
File Compression With the enormous amount of enterprise data that is created and stored, there is a pressing need to conserve disk space and optimize data transfer time. There are various tools, utilities, and commands that are used for file compression. Some of the commonly used commands are: – The compress command – The gzip […]