pwd command in Linux with examples

pwd command in Linux with examples

The pwd command in Linux is short for present working directory. When it comes to Linux commands, this has to be one of the simplest. It’s only function is to print the present working directory of your terminal. It comes in handy when you’re not exactly sure what directory you’re in, or when you need to pass the present working directory inside of a Bash script, for example.

Read more

head command in Linux with examples

head command in Linux with examples

The head command in Linux is one of the most important commands you’ll need when viewing text files. If you’re new to Linux, the head command is a perfect place to start, since it has a simple syntax and straight forward purpose. The head command is the complementary command to the tail command. The head command is used to print the first 10 lines (by default) of one or multiple files.

Read more

mkdir command in Linux with examples

mkdir command in Linux with examples

One of the most common and fundamental commands in Linux is the mkdir command. The most basic way to use this command is to create one or multiple directories. If you’re coming from Windows as a newcomer to Linux, you probably know directories as folders. The mkdir command can do a few other things with directories as well.

Read more

time command in Linux with examples

time command in Linux with examples

The time command in Linux is like a stop watch built directly into your command line terminal. The time command is able to track how much time any command takes to finish executing. All you need to do is preface some command with the time command. Your command will execute as normal, but it will also show the duration of the command.

Read more

tee command in Linux with examples

tee command in Linux with examples

Any Linux user that has spent enough time with the command line will eventually run into a scenario where they would like to redirect standard output and/or standard error to a file (or multiple files) as well as the terminal at the same time. For something so trivial, surely there’s a way to send our output to both places at the same time. And this is exactly what the tee command in Linux is used for.

Read more

tail command in Linux with examples

tail command in Linux with examples

The tail command in Linux is one of the most essential commands you’ll need when viewing text files. If you’re a beginner to using the command line, the tail command is a good one to learn, along with the head command, which is sort of its opposite counterpart. tail is used to print the last 10 lines of multiple files or a specified file. tail, with it’s interesting and convenient functions, can be used to monitor changes that are made to files.

Read more

od command in Linux with examples

od command in Linux with examples

The od command in Linux is used to dump files in octal and other formats, including hexadecimal, decimal, and ASCII. This can be handy when you need to view files that aren’t ordinarily human readable, such as a binary file that’s already been compiled. But it can also prove useful in a slew of other, admittedly niche, scenarios.

Read more

tar command in Linux with examples

tar command in Linux with examples

The tar command creates the tar file type is used to combine multiple files into a single archive. Tar actually means “tape archive,” because tar’s original purpose was to be used on tape backups – that should tell you how old this format is. Linux systems still use the tar format, and it continues to enjoy widespread use to this day.

Read more

ssh command in Linux with examples

ssh command in Linux with examples

The ssh command in Linux is used to manage remote systems. Ordinarily, this would be another Linux system, but it could also be a firewall, router, or even a different operating system entirely. Using the ssh command to remotely log into another system will give you a command line terminal that you can fully access as if you were physically in front of the machine.

Read more

rm command in Linux with examples

rm command in Linux with examples

The rm command is one of the most common and basic commands in Linux. Even if you have a limited amount of experience with Linux, you’ve most likely heard of it. The main purpose of this command is to remove files and directories. Using this command to remove files and directories cannot be undone.

Read more