Making a Bootable .ISO from a Bootable Floppy Image

Follow the steps below to create a bootable .ISO file. These steps assume that the user’s host operating system is Microsoft Windows.

HelloWorldBootable

1. If you have not already done so, download and install VirtualBox. VirtualBox is a freeware virtualization hypervisor for Microsoft Windows. As of this writing, the latest version is available for download at the URL https://www.virtualbox.org/wiki/Downloads.

2. Download an .ISO of a Linux distribution such as Ubuntu or CentOS. As of this writing, the latest version of CentOS is available for download at the URL https://www.centos.org/download/.

3. Start VirtualBox and create a new virtual machine (“VM”) running the Linux .ISO downloaded in the previous step. For detailed directions on how to install CentOS in VirtualBox, see a previous post.

4. Start the Linux VM created in a previous step and log in with the root username and password. Open a console window and determine the IP address of the virtual machine by entering the command “ifconfig”. The external IP address of the VM should be displayed somewhere in this output, likely in the “eth1” section.

5. If you have not already done so, download and install PuTTY. PuTTY is a Telnet and SSH client, which will allow a user to log in to a remote machine and run commands on it. As of this writing, the latest version is available for download at the URL http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html.

6. If you have not already done so, download and install WinSCP. WinSCP allows a user to transfer files to and from a remote machine. As of this writing, the latest version is available for download at the URL https://winscp.net/eng/download.php.

7. Follow the steps in a previous post to create a new bootable disk image named “HelloWorldBootable.img”. This disk image, when booted, will simply display the message “Hello, World!”.

8. Start PuTTY, enter the IP address of the VM in the appropriate box, and click the “Open” button. When prompted, enter the username “root”, then the root user’s password to log in to the Linux VM.

9. In the PuTTy window, at the command prompt of the Linux VM, enter the command “yum install mkisofs” (if using a Fedora-based flavor of Linux such as CentOS) or “apt-get install mkisofs” (if using a Debian-based flavor of Linux such as Ubuntu).

10. Still at the command prompt of the Linux VM, center the command “cd /tmp” to change the current directory, enter the command “mkdir ISOTest” to create a new working subdirectory, and then enter “cd ISOTest” to move to that directory.

11. Back on the host machine, start WinSCP, enter the IP Address, username, and password for the Linux VM in the appropriate boxes, and click the Login button. In the tree view at the left side of the window that appears, locate the “/tmp/ISOTest” directory, and select it.

12. Back on the host machine, open a file explorer window, navigate to the directory containing the file “HelloWorldBootable.img” created in a previous step, and drag that file onto the WinSCP window to transfer it from the host machine to the Linux VM.

13. Back on the command prompt for the Linux VM, run the command below to convert the bootable.IMG file to a bootable .ISO file.

mkisofs -no-emul-boot -b HelloWorldBootable.img -o HelloWorldBootable.iso

14. Back in the WinSCP window, press the F5 key to refresh the view, locate the newly created file “HelloWorldBootable.iso” in the right pane, and drag it onto the desktop of the host Windows machine.

15. Close PuTTY and WinSCP, then shut down the Linux VM running in VirtualBox.

16. In the main window of VirtualBox, click the “New” button to create a new virtual machine, enter the value “BootableISOTest” in the “Name” box, select “Other” in the “Type” box, and select “Other/Unknown” in the “Version” box. Then click the “Next” or “Create” buttons several times to accept the defaults to create a new “blank” virtual machine.

17. Start the “BootableISOTest” virtual machine. In the “Select start-up disk” dialog that appears, click the “Choose a virtual optical disk file…” button to the right of the select box, locate and select the file “HelloWorldBootable.iso” in the dialog that appears, then click the “Start” button to start the VM.

Advertisements
This entry was posted in Uncategorized and tagged , , , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s