mincs
mincs copied to clipboard
problem running on android twrp/adb shell
Dear all,
I am an Android system hobbyist and is a bit new to linux. I success to compile a arm64 kernel for a unlocked phone thus is running TWRP now. since the phone is old enough, the boot loader is not support for newer Android so I would like to seek for a way to bootstrap into Android 8/9 GSI into a container with twrp shell. I found that MINC is very interesting such that i might not need to do futher cross-compile LXC on arm64 anymore.
Here is what i did below in adb shell, apparently not working at all. Detail is in bottom, below is the pin-point message.
/usr/local/bin # ./minc -D -r /system_root --user 0:0 --usedev --pivot mkdir: can't create directory '/tmp/minc4504-AmHQeg/root/etc': No such file or directory
Is there anybody found it interesting and offer some help?
Thanks Uleak
===================== /tmp/mincs-master # ls LICENSE install.sh minc samples README.md libexec polecat sigpack ermine-breeder marten runtests.sh test.d /tmp/mincs-master # ./install.sh Install minc into /usr/local/bin/minc Install marten into /usr/local/bin/marten Install polecat into /usr/local/bin/polecat Install libexec/ermine-ifup into /usr/local/libexec/ermine-ifup Install libexec/minc-cage into /usr/local/libexec/minc-cage Install libexec/minc-coat into /usr/local/libexec/minc-coat Install libexec/minc-core into /usr/local/libexec/minc-core Install libexec/minc-dens into /usr/local/libexec/minc-dens Install libexec/minc-exec into /usr/local/libexec/minc-exec Install libexec/minc-farm into /usr/local/libexec/minc-farm Install libexec/minc-hunt into /usr/local/libexec/minc-hunt Install libexec/minc-leash into /usr/local/libexec/minc-leash Install libexec/minc-moult into /usr/local/libexec/minc-moult Install libexec/minc-smuggler into /usr/local/libexec/minc-smuggler Install libexec/minc-trapper into /usr/local/libexec/minc-trapper /tmp/mincs-master # chmod a+x /usr/local/bin/* /tmp/mincs-master # chmod a+x /usr/local/libexec/ /tmp/mincs-master # cd //usr/local/bin /usr/local/bin # minc -D -r /system_root -n raw --user 0:0 --usedev --pivot /sbin/sh: minc: not found /usr/local/bin # ./minc -D -r /system_root -n raw --user 0:0 --usedev --pivot BusyBox v1.30.1 (Debian 1:1.30.1-4) multi-call binary.
Usage: ip [OPTIONS] address|route|link|tunnel|neigh|rule [ARGS]
OPTIONS := -f[amily] inet|inet6|link | -o[neline]
ip addr add|del IFADDR dev IFACE | show|flush [dev IFACE] [to PREFIX] ip route list|flush|add|del|change|append|replace|test ROUTE ip link set IFACE [up|down] [arp on|off] [multicast on|off] [promisc on|off] [mtu NUM] [name NAME] [qlen NUM] [address MAC] [master IFACE | nomaster] ip tunnel add|change|del|show [NAME] [mode ipip|gre|sit] [remote ADDR] [local ADDR] [ttl TTL] ip neigh show|flush [to PREFIX] [dev DEV] [nud STATE] ip rule [list] | add|del SELECTOR ACTION /usr/local/bin # ./minc -D -r /system_root --user 0:0 --usedev --pivot mkdir: can't create directory '/tmp/minc4504-AmHQeg/root/etc': No such file or directory /usr/local/bin #
/usr/local/bin # cd / / # cd system_root/ /system_root # ls acct init postinstall bin init.environ.rc proc bugreports init.rc product cache init.recovery.usb.rc sbin charger init.usb.configfs.rc sdcard config init.usb.rc storage d init.zygote32.rc sys data init.zygote64_32.rc system default.prop lost+found ueventd.rc dev mnt vendor etc odm verity_key fstab.enableswap oem /system_root # uname -a Linux localhost 3.18.119+ #92 SMP PREEMPT Wed Aug 21 13:26:23 CST 2019 aarch64 GNU/Linux /system_root # cd / / # ls bin protect_f cache protect_s charger res data root default.prop sbin dev sdcard etc seapp_contexts external_sd selinux_version file_contexts sepolicy include service_contexts init share init.rc sideload init.recovery.hlthchrg.rc sys init.recovery.service.rc system init.recovery.usb.rc system_root lib tmp libexec twres license ueventd.rc nvdata usb-otg oem usr proc var property_contexts / # cd bin /bin # ls bocker lxc-console lxc-info lxc-unfreeze lxc-attach lxc-copy lxc-ls lxc-unshare lxc-autostart lxc-create lxc-monitor lxc-update-config lxc-cgroup lxc-destroy lxc-snapshot lxc-usernsexec lxc-checkconfig lxc-device lxc-start lxc-wait lxc-checkpoint lxc-execute lxc-stop sh lxc-config lxc-freeze lxc-top /bin #
/usr/local/bin # busybox --help BusyBox v1.30.1 (Debian 1:1.30.1-4) multi-call binary. BusyBox is copyrighted by many authors between 1998-2015. Licensed under GPLv2. See source distribution for detailed copyright notices.
Usage: busybox [function [arguments]...] or: busybox --list[-full] or: busybox --install [-s] [DIR] or: function [arguments]...
BusyBox is a multi-call binary that combines many common Unix
utilities into a single executable. The shell in this build
is configured to run built-in utilities without $PATH search.
You don't need to install a link to busybox for each utility.
To run external program, use full path (/sbin/ip instead of ip).
Currently defined functions: [, [[, acpid, adjtimex, ar, arch, arp, arping, ash, awk, basename, bc, blkdiscard, blockdev, brctl, bunzip2, busybox, bzcat, bzip2, cal, cat, chgrp, chmod, chown, chroot, chvt, clear, cmp, cp, cpio, crond, crontab, cttyhack, cut, date, dc, dd, deallocvt, depmod, devmem, df, diff, dirname, dmesg, dnsdomainname, dos2unix, dpkg, dpkg-deb, du, dumpkmap, dumpleases, echo, ed, egrep, env, expand, expr, factor, fallocate, false, fatattr, fdisk, fgrep, find, fold, free, freeramdisk, fsfreeze, fstrim, ftpget, ftpput, getopt, getty, grep, groups, gunzip, gzip, halt, head, hexdump, hostid, hostname, httpd, hwclock, i2cdetect, i2cdump, i2cget, i2cset, id, ifconfig, ifdown, ifup, init, insmod, ionice, ip, ipcalc, ipneigh, kill, killall, klogd, last, less, link, linux32, linux64, linuxrc, ln, loadfont, loadkmap, logger, login, logname, logread, losetup, ls, lsmod, lsscsi, lzcat, lzma, lzop, md5sum, mdev, microcom, mkdir, mkdosfs, mke2fs, mkfifo, mknod, mkpasswd, mkswap, mktemp, modinfo, modprobe, more, mount, mt, mv, nameif, nc, netstat, nl, nologin, nproc, nsenter, nslookup, nuke, od, openvt, partprobe, passwd, paste, patch, pidof, ping, ping6, pivot_root, poweroff, printf, ps, pwd, rdate, readlink, realpath, reboot, renice, reset, resume, rev, rm, rmdir, rmmod, route, rpm, rpm2cpio, run-init, run-parts, sed, seq, setkeycodes, setpriv, setsid, sh, sha1sum, sha256sum, sha512sum, shred, shuf, sleep, sort, ssl_client, start-stop-daemon, stat, strings, stty, su, sulogin, svc, svok, swapoff, swapon, switch_root, sync, sysctl, syslogd, tac, tail, tar, taskset, tc, tee, telnet, telnetd, test, tftp, time, timeout, top, touch, tr, traceroute, traceroute6, true, truncate, tty, tunctl, ubirename, udhcpc, udhcpd, uevent, umount, uname, uncompress, unexpand, uniq, unix2dos, unlink, unlzma, unshare, unxz, unzip, uptime, usleep, uudecode, uuencode, vconfig, vi, w, watch, watchdog, wc, wget, which, who, whoami, xargs, xxd, xz, xzcat, yes, zcat /usr/local/bin #