Last active
January 25, 2023 23:04
-
-
Save katabame/5c071deb2075455b4f21089d4bd7a1b6 to your computer and use it in GitHub Desktop.
Debian on QEMU on Termux CheetSheet
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
~ $ pkg upgrade -y | |
~ $ pkg install screen qemu-utils qemu-common qemu-system-x86_64-headless -y | |
~ $ mkdir debian && cd $_ | |
~/debian $ screen | |
~/debian $ qemu-img create -f qcow2 debian.img 4G | |
~/debian $ qemu-system-x86_64 -nographic -m 4G -hda debian.img | |
< PRESS Ctrl+B quickly > | |
iPXE> dhcp net0 | |
iPXE> kernel http://ftp.jaist.ac.jp/debian/dists/stable/main/installer-amd64/current/images/netboot/debian-installer/amd64/linux console=ttyS0 | |
< Keep in mind, Backspace key doesn't work well. Use Delete key instead. > | |
iPXE> initrd http://ftp.jaist.ac.jp/debian/dists/stable/main/installer-amd64/current/images/netboot/debian-installer/amd64/initrd.gz | |
iPXE> boot | |
< Debian installer boots up.... > |
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
root@debian: ~# apt install screen curl sudo ufw -y | |
< Note that all packages are already up-to-date in setup > | |
< FOLLOW: https://github.com/homebridge/homebridge/wiki/Install-Homebridge-on-Debian-or-Ubuntu-Linux > | |
root@debian: ~# ufw allow 8581/tcp | |
root@debian: ~# ufw enable |
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
root@debian: ~# shutdown now | |
~/debian $ echo qemu-system-x86_64 -nographic -m 4G -hda debian.img -net nic -net user,hostfwd=tcp::8581-:8581 > ./start.sh | |
~/debian $ chmod a+x ./start.sh | |
~/debian $ ./start.sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment