くんすとの備忘録

IT系技術メモ

移転しました。

15秒後に自動的にリダイレクトします。

Running Archlinux in Bash on Windows

I have installed ArchLinux in Bash on Ubuntu on Windows(Windows Subsystem for Linux).

Installation

1. Install packages

Install tools for installation in Bash on Ubuntu on Windows(BoW).

apt-get install -y squashfs-tools p7zip-full

2. Download ArchLinux ISO

Download an ISO from mirror sites as you like.

wget http://ftp.jaist.ac.jp/pub/Linux/ArchLinux/iso/2016.08.01/archlinux-2016.08.01-dual.iso

3. Pickup the “airootfs.sfs” from ISO

Extract an iso and pickup the airootfs.sfs.

7z x archlinux-*-dual.iso
cp arch/x86_64/airootfs.sfs .

4. Extract the “airootfs.sfs”

Extract the airootfs.sfs with the unsquashfs command.

unsquashfs airootfs.sfs

Error has occurred, but it’s OK. f:id:kunst1080:20160825234414p:plain

5. Move the squashfs-root to a rootfs.

Close ALL BoW windows.
Move the squashfs-root to root of BoW with Windows Explorer.

  • root of BoW - %USERPROFILE%\AppData\Local\lxss\
  • squashfs-root - %USERPROFILE%\AppData\Local\lxss\root\squashfs-root

f:id:kunst1080:20160825234425p:plain

6. Backup a rootfs and substitute squashfs-root for rootfs

f:id:kunst1080:20160825234434p:plain

7. Open BoW

It’s ArchLinux!! f:id:kunst1080:20160825234445p:plain

8. Setup pacman and isntall git

pacman-key --init
pacman-key --populate archlinux
pacman -Syy
pacman -S git

f:id:kunst1080:20160825234453p:plain f:id:kunst1080:20160825234504p:plain Error has occurred when pacman -S (i guess it’s chroot?), I can use git.

That’s ALL!!

References