How to upload an ISO using Virtual Box to a Linode

Linode Staff

I'm wondering if it's possible to upload a Virtual Box image to a Linode. Will this work with Windows as well as a Linux distribution?

2 Replies

It is possible to get an ISO or Windows to run on a Linode. You are going to need VirtualBox and a copy of the ISO that you want to use. It will work for most ISO files to load a Linux distribution or Windows machine.

Download

The first thing you're going to need to do is download:

VirtualBox
Finnix
The ISO

VirtualBox

Follow these instructions to install and spin up a VirtualBox instance on your local computer. When setting up your VirtualBox instance, the hard disk should be for 20GB. If it's not set up correctly, you won't be able to copy your ISO to your Linode. 20GB should be enough hard disk for any ISO OS. If necessary, your Linode's disk can be resized at any time.

After you have created your VirtualBox instance with the ISO do not enter in the product key if using Windows. Use the 30-day free trial. If the product key in registered and you transfer the VirtualBox instance, you will have to enter a new key.

If using Windows

Startup you ISO VirtualBox, and make all of your configurations so you can log in after you have uploaded your Windows OS inside your Linode:

1. Control Panel
2. System and Security
3. System
4. Enable "Allow Remote Access"
5. "Allow remote connections to this computer"

If using any other ISO
Make any configuration changes that are needed to run the instance on a Linode.

Now shut down your VirtualBox instance.

Set Up Your Linode

I recommend using a 4GB Linode. It can be done with a 2GB Linode or even a 1GB Nanode, but Linodes under these smaller plans may run slow depending on what you are doing with your Linode. You can always resize your Linode plan later. We use hourly billing, so running a 4GB Linode for 24 hours will cost less than a dollar.

Create a Raw Disk

In your Linode Manager click "Create a new Disk" Use the following specifications when setting up your Linode:

  • Label: ISO Volume
  • Type: unformatted/raw
  • Size: use the whole disk available
  • Save configuration

Then click "Create a new Configuration Profile" and use the following specifications:

Label and Notes

  • Label: ISO Profile

Virtual Machine Mode

  • Full-virtualization

Boot Setting

  • Kernel: Direct Disk
  • Run Level: Default Run Level
  • Memory Limit: Maximum

Block Device Assignment

  • /dev/sda ISO
  • Leave the rest of the partitions blank except "initrd"
  • initrd: No initrd

Filesystem/Boot Helpers

  • Yes to all

Boot into Rescue Mode

Now we boot the Linode into Rescue Mode make sure /dev/sda is set to "ISO Volume"

  • Launch the Glish console in the Remote Access tab of your Linode Manager.
  • Set the password using passwd command. It is only a temporary password to receive the ISO disk image. It doesn't need to be complicated.
  • Start the SSH service using service ssh start

Move your ISO from VirtualBox to your Linode

This step is where you're going to need to use Finnix. While your VirtualBox shuts down, put the Finnix image in the virtual disk drive of your VirtualBox and boot.

Boot ISO VirtualBox with Finnix

Select the following option:

  • Boot Finnix (64-bit)

When you are at the command line, you are ready to send your ISO to your Linode. You are going to use the following command (replace $LinodeIP in the above command with the IP address of your Linode):

dd if=/dev/sda | pv | gzip -9 | ssh root@$LinodeIP "gzip -d | dd of=/dev/sda"

If the above command does not work, you need to find the disk that the ISO resides on in your VirtualBox. Run the following command in Finnix on your virtual machine "fdisk -l" and replace "sda" in the first part of the command with the results of the fdisk command. It should be "sda" or "sdb" or something similar. Do not use the number at the end of the partition name. The second "sda" in the command is where we are sending the image, so do not change that.

Finnix will ask for the password you just created for your Linode in Rescue Mode.

Now, this may take some time depending on your connection speed. Once you finish, the command line should say that 20GB has copied.

Accessing your Linode

To verify that you have uploaded your ISO disk image correctly, power down your Linode and boot normally. Then access your Linode using the Glish console. If everything worked successfully, you should see your Linode boot with the Virtual Box image you uploaded.

If you're using Windows, you can remote desktop into the ISO instance. It is possible to use the Glish interface, but I've found that there are problems with the mouse pointer not working correctly. I've successfully uploaded Windows 10 and Server 2012 and 2016 on a Linode.

A good post here. It would be nice if we could simply boot and build a linode from an ISO as easily as one can with VirtualBox.

I have been having difficulty pulling an ISO (dropbox hosted) into a Linode but it would seem that "sending" an ISO to a Linode seems worth pursuing.

Thanks for posting this here.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct