-
-
Save azkadev/6ddd20a44056a00c0ca47ea1cf9fa172 to your computer and use it in GitHub Desktop.
run linux on android by chroot in case that android device doesn't have enought free space.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/system/bin/sh | |
cd /data/local/tmp | |
mount -o bind /dev /data/local/tmp/linux_root/dev | |
mount -o bind /dev/pts /data/local/tmp/linux_root/dev/pts | |
mount -t sysfs /sys /data/local/tmp/linux_root/sys | |
mount -t proc /proc /data/local/tmp/linux_root/proc | |
export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/system/bin:/system/xbin | |
export TERM=xterm | |
export HOME=/root | |
chroot /data/local/tmp/linux_root /bin/bash |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment