Did you know that you can transform your Android device into a mini Linux machine with the help of the Termux application? Well yes, Termux is a command-line application that can run almost all Linux tools and packages on Android devices.
Today in this post, I am going to share a basic Termux command list that can help you learn and use Termux more easily.
Table of Contents
What is Termux
Every beginner who is interested in cyber security and ethical hacking thinks that Termux is a hacking machine. Is Termux a really hacking machine? Well, the answer is no. Termux is specifically designed for learning cybersecurity and penetration testing, but some developers have developed hacking tools that run in Termux.
Termux is actually an Android terminal application that provides a Linux-like environment, allowing users to run various command-line tools and packages.
Termux provides a safe and secure platform within Android devices where users can do Linux work’s like programming, scripting, remote SSH server, penetration testing, and more.
Now let’s dive into some basic Termux commands you need to know before using Termux.
Basic Termux Commands List
Below is a basic Termux command list, ranging from package management commands to additional commands that will help a beginner to use Termux easily and efficiently.
1. Termux Packages Management Commands
Termux comes with APT and PKG package managers to install, uninstall, update, and manage packages. Here are some basic Termux commands for package management:
- $ apt update : Updates the Termux installed packages to their latest version.
- $ apt upgrade : Upgrade the installed packages to their latest version.
- $ pkg install (package_name) : Simply install additional packages like Python, git, ect.
- $ pkg uninstall (package_name) : Uninstall/remove a package from Termux.
- $ pkg list-installed : Displays a list of all installed packages.
2. Termux File Management Commands
File management commands will help you navigate, manage, and manipulate files in Termux. Here are some of the basic Termux file management commands:
- $ ls : Show you all files present in the current location.
- $ cat (filename) : Shows all contents of file.
- $ mv (old_name) (new_name) : Use to rename a file.
- $ touch (filename) : Creates a new empty file.
- $ rm (filename) : To delete a specific file.
3. Termux Directory Management Commands
Folders are called directories in Termux. With the help of directory management commands, you can efficiently navigate, create, move, and delete directories within Termux. Here is the basic Termux command list for directory management:
- $ ls : Show you all directories present in the current location.
- $ cd directory_name : Changes the current directory to another directory.
- $ mkdir (directory_name) : Use to create a new directory.
- $ rm -rf (directory_name) : To delete a directory.
- $ pwd : Use to see the current working directory path.
- $ mv (old_name) (new_name) : Rename a directory.
4. Termux File Editing Commands
Termux comes with Nano and Vim text editors, which are sufficient for editing files in Termux. Here are some of the basic Termux commands for file editing:
- $ cat (filename) : To see the contents of a file.
- $ nano (file_name) : To edit a file in nano text editor.
- $ pkg install vim : To install the vim advanced text editor.
- $ vim (file_name) : Edit a file in vim text editor.
5. Termux Networking Commands
Termux allows users to do many types of network-related work by installing various networking tools. Some of its basic networking commands are
- $ pkg install nmap : Installs the network scanner tool Nmap.
- $ nmap (ip_address) : Perform a basic scan on a network.
- $ ifconfig : Displays your network informations.
- $ wget (url) : Downloads a file from a specific URL.
- $ curl (url) :Displays the contents of a URL.
6. Termux System Management Commands
Termux system management involves maintaining, monitoring, and controlling the Termux environment with commands. Here are some basic system management Termux commands:
- $ date : To see the current date and time in Termux.
- $ df -h : Shows the disk usage of the file system.
- $ uname -a : Displays information about your system, like the kernel version, architecture, and more.
- $ uptime : Shows the system running time and average load.
- $ free -h : Shows the free and used memory of the system.
- $ history : Displays the history of commands entered in the current session.
- $ whoami : Displays your current login username.
7. Termux Process Management Commands
You can control, monitor, and manage running processes on Termux with the help of the Termux process management commands. Some of its basic commands are
- $ top : Shows current information about the running process, CPU, and memory usage.
- $ ps aux : Shows all running processes with process IDs.
- $ kill (PID) : To kill a process with process ID.
- $ killall (process_name) : To terminate all processes of a specific process name.
- $ pkill (process_name) : To kill a specific process with a process name.
8. Some Additional Commands
Some additional commands that you must need to know
- $ clear : Clears the current session screen.
- $ cal : Displays a command line calendar.
- $ pkg install python : To install python in Termux.
- $ pkg install bc : To Install a basic command-line calculator
- $ bc : Opens the basic calculator: use +, -, ×, *, symbols to calculate any value.
- $ termux-setup-storage : This will allow access to the device’s internal storage.
- $ termux-info : Shows the Android device system informations.
- $ exit : Use to exit from the current terminal session.
These are some of the basic Termux commands list, from package managing to networking. With the help of these commands, you can start using Termux more easily and efficiently. However, these are just some basic Termux commands, but if you are a beginner, then these commands are enough to make you a pro Termux user.
Download Termux Commands List PDF
The Termux commands list PDF file that was provided in this post was loaded with all the basic Termux commands, from package management to networking. Simply click on the download button to download the Termux commands list PDF file.
Conclusion
Termux provides a Linux-like environment on Android devices where almost all Linux tools and packages can be used. You can perform many Linux tasks with the help of the Termux application. Although Termux is a command-line application that requires some command-line knowledge but if you learn the basic Termux commands, then you can easily use Termux.