Dark Hacker World–
In this guide, we have made a list of the best Linux Ubuntu commands for beginners. Without Ubuntu commands, you cannot operate the terminal of Ubuntu. To use the Ubuntu terminal like a pro, you must read these Ubuntu commands.
But before getting into the Ubuntu command. I want you to know about the Ubuntu terminal and the uses of Ubuntu terminal commands.
We all know that Ubuntu is a widely used open-source operating system for the Linux platform. And its command-line interface or a Terminal is a necessary part of the Ubuntu operating system.
Using Ubuntu commands in Terminal is an efficient way to get the actual power of a computer that is better and faster than a graphical interface.
You can use the Ubuntu terminal to run various programs, execute several files, navigate to folders, and many more.
To take benefit of the Ubuntu terminal, You must know some basic Ubuntu commands. These Ubuntu commands can be useful for any beginner. Here we have made a list of basic commands that can be used in Ubuntu Terminal.
Ubuntu commands list and cheats sheet
- ls show you a list of files and directories;
- ls -l long list format with extended information;
- ls -a show you hidden files and folders;
- ls -h shows a list along with the size of files and directories.
- cd ~ leads you to the home directory;
- cd / leads you to the root directory;
- cd .. leads you up one directory level;
- cd – leads you to the previous directory;
cp ABC /root/Downloads/
- rm <filename> remove a file;
- rm -r <directory name> remove directories and their contents recursively;
- rm -rf < directory name> remove directories and their contents forcefully;
- rm -rf * remove everything forcefully present inside the directory.
- cat <filename> To view the content of the file;
- cat >Ubuntu It will create a file named Ubuntu.
15. Uname -a
- uname -a prints all information about the system;
- uname -s Prints kernel name on the terminal screen;
- uname -n shows the hostname of your computer;
- uname -m shows the hardware architecture of your computer;
- uname -o shows the name of your operating system;
- uname -v shows the version information.
- apt-get update. This command is used to update the system repository. You always have to use this command before performing an upgrade or dist upgrade.
- apt-get upgrade. Use this command to upgrade the packages that are currently installed in your system. The packages that are present in sources.list repository will be upgraded. You must always use the update command before upgrading your system. The update command will get the latest version of packages and the upgrade command will upgrade those packages.
- apt-get dist-upgrade. Use this command to upgrade your packages. This command also handles dependencies with new versions of packages. Running this command may remove some old packages.
- apt-get install [package name]. This command is used to install or upgrade the packages.
apt-get install [package name]
- apt-get remove [package name]. Use this Ubuntu command to to remove the packages. It does not remove any files that is created by a package.
apt-get remove [package name]
- apt-get purge [package name]. The use of this command is to remove the packages along with the configuration files associated with the packages.
apt-get purge [package name]
Syntax: whatis [package name]
zip ubuntu.zip ubuntu.txt
The above command will compress ubuntu.txt into ubuntu.zip.