制作Ubuntu根文件系统:
gunzip ubuntu-base-22.04.5-base-arm64.tar.gz
mkdir ubuntu
tar xvpf ubuntu-base-22.04.5-base-arm64.tar -C ubuntu
cd /userdisk/ubuntu
cp /etc/resolv.conf ./etc/resolv.conf
mount --bind /dev ./dev
mount --bind /dev/pts ./dev/pts
mount --bind /proc ./proc
mount --bind /sys ./sys
mkdir rootdir
mount --bind / ./rootdir
cd /userdisk/ubuntu
chroot .
su root
su root
apt update
chmod 777 /dev/null
chmod 1777 /tmp
alias ins=‘apt install’
ins -y htop neofetch file curl git zsh net-tools
sh -c “$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)”
apt install -y network-manager
apt install -y gnome-shell ubuntu-gnome-desktop
apt install -y xfce4
export LD_LIBRARY_PATH=/userdisk/ubuntu/lib:/userdisk/ubuntu/usr/lib:/userdisk/ubuntu/usr/lib/aarch64-linux-gnu/weston/:/userdisk/ubuntu/lib/aarch64-linux-gnu/:$LD_LIBRARY_PATH
export PATH=/bin/:/sbin/:/usr/bin/:
sudo cp -Rfd …/ubuntu_gnome/* .
sudo mount --bind /dev ./dev
sudo mount --bind /dev/pts ./dev/pts
sudo mount --bind /proc ./proc
sudo mount --bind /sys ./sys
sudo umount dev
sudo umount dev/pts
sudo umount proc
sudo umount sys
sudo vi etc/apt/sources.list
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy main restricted
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates main restricted
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates main restricted
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy universe
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy universe
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates universe
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy multiverse
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy multiverse
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates multiverse
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-backports main restricted universe multiverse
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-backports main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-security main restricted
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-security main restricted
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-security universe
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-security universe
deb http://mirrors.aliyun.com/ubuntu-ports/ jammy-security multiverse
# deb-src http://mirrors.aliyun.com/ubuntu-ports/ jammy-security multiverse
好家伙,systemd这么大:
root@jenkins-2:/# apt install systemd
qemu: Unsupported syscall: 293
qemu: Unsupported syscall: 293
Installing:
systemd
Installing dependencies:
adduser gir1.2-girepository-2.0 libgirepository-1.0-1 libkmod2 libreadline8t64 netbase python3.12 xdg-user-dirs
ca-certificates gir1.2-glib-2.0 libglib2.0-0t64 libkrb5-3 libsqlite3-0 networkd-dispatcher python3.12-minimal
dbus krb5-locales libglib2.0-data libkrb5support0 libsystemd-shared openssl readline-common
dbus-bin libapparmor1 libgssapi-krb5-2 libnsl2 libtirpc-common python3 shared-mime-info
dbus-daemon libatomic1 libicu74 libpython3-stdlib libtirpc3t64 python3-dbus systemd-resolved
dbus-session-bus-common libdbus-1-3 libk5crypto3 libpython3.12-minimal libxml2 python3-gi systemd-timesyncd
dbus-system-bus-common libexpat1 libkeyutils1 libpython3.12-stdlib media-types python3-minimal tzdata
Suggested packages:
liblocale-gettext-perl default-dbus-session-bus libarchive13t64 libfido2-1 iw python-dbus-doc readline-doc systemd-boot
perl | dbus-session-bus libbpf1 libip4tc2 | wireless-tools python3.12-venv systemd-container systemd-repart
cron low-memory-monitor libcryptsetup12 libpwquality1 python3-doc python3.12-doc systemd-cryptsetup libtss2-tcti-device0
quota krb5-doc libdw1t64 libqrencode4 python3-tk binutils systemd-homed polkitd
ecryptfs-utils krb5-user libelf1t64 libtss2-rc0t64 python3-venv binfmt-support systemd-userdbd
Recommended packages:
linux-sysctl-defaults
Summary:
Upgrading: 0, Installing: 51, Removing: 0, Not Upgrading: 0
qemu: Unsupported syscall: 293
Download size: 30.0 MB
Space needed: 111 MB / 616 MB available
Continue? [Y/n] y