Use the Amazon Linux 2 virtual machine (VM) images for on-premises development and testing. These images are available for use on the following virtualization platforms: VMWare, KVM, VirtualBox (Oracle VM), Microsoft Hyper-V
- https://cdn.amazonlinux.com/os-images/2.0.20201111.0/vmware/
- https://cdn.amazonlinux.com/os-images/2.0.20201111.0/kvm/
- https://cdn.amazonlinux.com/os-images/2.0.20201111.0/virtualbox/
- https://cdn.amazonlinux.com/os-images/2.0.20201111.0/hyperv/
How to Install Amazon Linux on On-Premises VMWare
1. Download the VM Image and upload to VM Datastore: For Vmware https://cdn.amazonlinux.com/os-images/2.0.20201111.0/vmware/amzn2-vmware_esx-2.0.20201111.0-x86_64.xfs.gpt.ova
2. Login to any of your Linux machine and create a directory – mkdir amazonlinux
3. cd amazonlinux
4. vi meta-data (Update hostname & Network Details)
local-hostname: alonpremise01
network-interfaces: |
iface eth0 inet static
address 10.99.2.155
network 10.99.2.0
netmask 255.255.255.0
broadcast 10.99.2.255
gateway 10.99.2.11
5. vi user-data (Update the password for default ec2-user)
#cloud-config
#vim:syntax=yaml
users:
– default
chpasswd:
list: |
ec2-user:amazon
6. Install genisoimage if not installed
yum -y install genisoimage
7. Create the seed.iso boot image using the meta-data and user-data configuration files
genisoimage -output seed.iso -volid cidata -joliet -rock user-data meta-data
8. Upload the seed.iso to the same VM datastore where you upload the image
9. Deploy OVF Template by selecting amzn2-vmware_esx-2.0.20201111.0-x86_64.xfs.gpt.ova and do not start the VM after Deployment completed
10. Edit the VM and add CD/ROM by selecting the ISO as seed.iso and make the first boot device as CD/ROM and Then Harddisk
11. Boot the VM and login Via Vm Console with ec2-user & the password amazon. FYI SSH login do not works as you need to enable Password authentication in ssh configuration. Enable – (PasswordAuthentication yes)
12. Sometimes the network configuration may fail, and the IP will be updated by dhcp, you can edit manually and set the required IP.
13. Modify the VM as you required and Export the OVF from this VM.
14. You may customize Amazon Linux OVF Template and create N number of VM from this.