Run Amazon Linux 2 in VirtualBox

I don't know what number it is, but I ran Amazon Linux 2 in VirtualBox.

The official documentation is here. https://docs.aws.amazon.com/ja_jp/AWSEC2/latest/UserGuide/amazon-linux-2-virtual-machine.html

The official documentation describes how to create a customized seed.iso, but a sample seed.iso is also available, so I'll start it using this.

Preparation

Disk image (vdi) https://cdn.amazonlinux.com/os-images/latest/virtualbox/

Sample seed.iso https://cdn.amazonlinux.com/os-images/latest/

As of October 17, 2020, latest will be redirected to 2.0.20200917.0.

Contents of sample seed.iso

In the sample seed.iso, the following settings are made.

Host name amazonlinux.onprem user user1 (password amazon) user2 (password amazon)? user3 (no password set, ssh key specified) ec2-user (password amazon)

I feel like I should start it with seed.iso for the time being and change the settings later.

Creating a virtual machine

Just set the vdi file you got as a hard disk and seted.iso as an optical drive.

スクリーンショット 2020-10-17 21.56.19.png

スクリーンショット 2020-10-17 21.57.33.png

Start-up

You can log in with ec2-user (password amazon).

スクリーンショット 2020-10-17 22.24.03.png

Bonus: Install GUI and VNC

https://aws.amazon.com/jp/premiumsupport/knowledge-center/ec2-linux-2-install-gui/ Follow the instructions to install mate desktop and TigerVNC and try to access with GUI.

sudo amazon-linux-extras install mate-desktop1.x
sudo bash -c 'echo PREFERRED=/usr/bin/mate-session > /etc/sysconfig/desktop'

sudo yum install tigervnc-server

vncpasswd

sudo cp /lib/systemd/system/[email protected] /etc/systemd/system/[email protected]
sudo sed -i 's/<USER>/ec2-user/' /etc/systemd/system/[email protected]
sudo systemctl daemon-reload
sudo systemctl enable vncserver@:1
sudo systemctl start vncserver@:1

It looks pretty dull, but I was able to access it via VNC.

スクリーンショット 2020-10-17 22.48.25.png

Recommended Posts

Run Amazon Linux 2 in VirtualBox
[Note] Run Django on Amazon Linux 2
Run docker-compose on Amazon Linux2 on ARM64
Run cron on Amazon Linux (set on Linux)
Put Python3 in Docker container of Amazon Linux2
OpenVPN Summary + Amazon Linux2
Seurat in Linux (installation)
Run Kali Linux on Windows with GUI (without VirtualBox)
Create Amazon Linux with AWS EC2 and log in
Addition of amazon linux swap
Run automatic jobs in python
Run shell commands in python
Run Python unittests in parallel
Install tomcat 5.5 on Amazon Linux.
Run background job in fabric
Use sshpass on Amazon linux2
Install Homebrew on Amazon Linux 2
Linux: DNS replacement in systemd.
Run FreeBSD on Linux + qemu
Build a Selenium environment on Amazon Linux 2 in the shortest time
[Linux] When the screen is cut off when installing CentOS in VirtualBox
[Work memo] Until matplotlib and numpy are installed in Amazon Linux
Run a multi-line script in a PDB
Prepare pipenv environment with amazon Linux 2
Run eclipse in Docker environment (noVNC)
Install oracle java8 on amazon linux2
Let's run "python -m antigravity" in python
Run shell command / python in R
Try installing OpenAM on Amazon Linux
Steps to install Ubuntu in VirtualBox
About Linux environment construction (VMware VirtualBOX)
Install tensorflow in Docker (LINUX) (memo)
How to install wkhtmltopdf (Amazon Linux2)
Install pyenv on EC2 (Amazon Linux)
[Linux] I installed CentOS on VirtualBox
[Linux] [kernel module] Create kthread in kernel module
run uwsgi server in uwsgi-gevent mode
Introducing Amplify to Amazon Linux 2 AMI
Remote debugging in Visual Studio (Linux)
Use django-debug-toolbar in VirtualBox / Vagrant environment
[Note] Install Imagick on Amazon Linux2
Run unittests in Python (for beginners)
Run a simple algorithm in Python
Introduce Python 3.5.2 environment on Amazon Linux
Linux command (basic in basic) personal memo
Change font size in Serene Linux
Run a batch of Python 2.7 with nohup on Amazon Linux AMI on EC2
Install Python3 and Django on Amazon Linux (EC2) and run your web server