Linux

15 DAYS 15 TOOLS EXPLORE. #DAY1 Linux SETUP.



I’d be glad to provide a comprehensive response on setting up a basic Linux environment on an Android mobile using Termux and Nether Kex:
Prerequisites:
* Android mobile device with a stable internet connection
* Termux app from the Google Play Store or F-Droid
* Nether Kex app from the Google Play Store or F-Droid
Steps:
* Install Termux:
* Open the Google Play Store or F-Droid and search for “Termux.”
* Install the Termux app on your device.
* Install Nether Kex:
* Open the Google Play Store or F-Droid and search for “Nether Kex.”
* Install the Nether Kex app on your device.
* Launch Termux:
* Open the Termux app from your app drawer.
* Update and Upgrade Packages:
* In the Termux terminal, type the following command and press Enter:
pkg update && pkg upgrade

* This command will update the package lists and upgrade any outdated packages.
* Install Proot (Optional):
* Proot is a tool that allows you to run Linux binaries in a chroot environment on Android. While not strictly necessary, it can provide a more isolated and secure environment for your Linux applications.
* To install Proot, type the following command and press Enter:
pkg install wget

* Install Minimal Debian Environment:
* Use the following command to download and extract a minimal Debian environment:
wget wget -O install-nethunter-termux

* This will create a directory named debian-root containing the basic Debian system files.
* Start the Linux Environment:
* To start the Linux environment, use the following command, replacing [USERNAME] with your desired username:
proot -0 -r debian-root -b /system/sdcard/ -w /sdcard/nether -e /bin/bash -u [USERNAME]

* The -0 flag specifies to use the current working directory as the root directory for the chroot environment.
* The -r debian-root flag specifies the directory containing the Debian root filesystem.
* The -b /system/sdcard/ flag binds the system’s SD card to the /system/sdcard directory within the chroot environment.
* The -w /sdcard/nether flag binds the /sdcard/nether directory (create it if it doesn’t exist) to the /sdcard directory within the chroot environment, providing persistent storage for your Linux environment.
* The -e /bin/bash flag specifies the shell to be executed within the chroot environment.
* The -u [USERNAME] flag specifies the username to use within the chroot environment.
* Note: The first time you run this command, it may take a while to set up the environment.
* Package Management:
* Once inside the chroot environment, you can use the apt command to install packages:
apt update && apt upgrade

* Exiting the Environment:
* To exit the Linux environment, type the following command and press Enter:
exit

Remember that using tools like Termux and Nether Kex may have security implications, so proceed with caution and at your own risk. It’s essential to be aware of the potential risks involved in running unverified code or modifying your device’s system.

[ad_2]

source

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button