7aGiven / AndroidDebian

在安卓上运行Debian

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

一个已root的安卓手机

Ubuntu

sudo apt install qemu-user-static debootstrap
sudo qemu-debootstrap --arch=arm64 --include=locales,sudo,python3,openjdk-17-jre-headless bookworm rootfs http://mirrors.tuna.tsinghua.edu.cn/debian/

修改_apt的用户组

cd rootfs
sudo vim etc/passwd

找到_apt那行,把65534改为3003

sudo tar -czf ../bookworm.tgz *

Termux

  1. 换源

termux-change-repo

  1. 升级系统

pkg upgrade -y

  1. 安装debootstrap并配置Debian rootfs
pkg install debootstrap
debootstrap --arch=arm64 --include=locales,sudo,python3,openjdk-17-jre-headless bookworm rootfs http://mirrors.tuna.tsinghua.edu.cn/debian/
cd rootfs
  1. 修改_apt的用户组

nano etc/passwd找到_apt那行,把65534改为3003

  1. 打包
termux-setup-storage
tar -czf /sdcard/bookworm.tgz *

About

在安卓上运行Debian