Making a Ubuntu/Linux Virtual Machine Using VirtualBox - Step by Step Tutorial

in #linux8 years ago (edited)


Introduction

If you don't want to run Ubuntu on a dedicated computer there is an easy way to run it using an existing Mac or Windows PC. This involves creating a "virtual machine".

There are a number of virtual machine solutions but the one I would recommend is "VirtualBox" from Oracle. It is not only easy to use but it is also completely FREE!

If you are curious and want to learn more about Linux then this is a great way to start.

This guide uses OS-X/Mac OS as that is my primary operating system.

The process should be exactly the same for Windows - the only difference will be in the appearance of the desktop and default folders - the actual linux/VB interface will be identical.

I am also using Ubuntu as my linux distribution but the process will be pretty similar whatever form of linux you are using.


Install the VirtualBox Software

You can download VirtualBox (VB) for free here:

https://www.virtualbox.org/wiki/Downloads

Choose your appropriate version of VirtualBox - Windows or OS-X.

Open the file to run it and install:


Configure Your VirtualBox Machine

Open VB if it is not already open.

Click the "NEW" button in the VB window.

Choose "Linux" as your OS.

Give your installation a suitable name - I chose "Ubuntu Steem".

Configure your RAM amount - the default is 1024MB (1GB).

I have plenty of RAM (32GB) so went with 2 GB. Obviously you want to go with an amount that leaves you enough to do everything else you do on your machine.

If this is a new install you will need to create a new "Virtual Hard Disk".

Unless you want to use other virtualisation software you will want to go with the default option to use the VirtualBox format for the image.

If you are reading this guide then it is unlikely you will be doing that so just stick with the default.

Next you need to choose either a fixed or dynamic size for your hard drive. I don't think it makes a huge difference but it may be slightly faster to use a fixed size.

I am not planning on doing anything performance intensive so just went with dynamic size.

Next you need to choose a location and a maximum size for the Hard Drive. I have a lot of space so moved the slider as close to 100 GB as I could get it.

Once you have chosen click "Create".

Congratulations! You now have a Virtual Machine but it doesn't have an OS yet. We will install Ubuntu in the next step.


Installing Ubuntu on Your Virtual Machine

Get the latest desktop version of Ubuntu here:

https://www.ubuntu.com/desktop

Make a note of where you save the file.

First click "start" on the VB window.

You will then be asked to locate the UBUNTU iso file which we downloaded earlier. Click on the little folder icon to find the location:

Select the file and click "Open". The Ubuntu installation should start:


The Installation Process

This is really easy and a lot faster than actually installing on a real machine.

Choose your language:

You need to choose again for some reason. I think the first is the language for the installation instructions and the second is for the OS itself.

Leave these boxes ticked - they should be ticked by default. Sometimes the top box will be greyed out. Ignore it if it is and make sure the second one is ticked before clicking "Continue".

Don't panic when you see this screen it is referring to erasing your "virtual disk".

You will want to use the default option at the top since we are just setting up a machine for experimental purposes but if you are security conscious you can check the box to encrypt your installation too.

You will need to set a security key in an extra step if you do that.

Click "Install Now".

Choose Your Location/Timezone.

Choose your keyboard localisation options.

Pick your machine name, username and password.

Make sure you keep backups of them because without them the virtual machine will be useless.

You can also choose to login automatically or encrypt your home folder depending on how much security you want.

Click "Continue"

The installation process will begin.

The time this takes will vary depending on how fast your machine is and the options you chose.

For me it was done in about 5-10 minutes. This screen will appear when it is finished.

You can just press enter and the virtual machine will reboot taking you to the Ubuntu login screen.

Enter the password you chose earlier. Congratulations you are now running Ubuntu!


Final Step - Updating Ubuntu

Before doing anything else and installing other software it is a good idea to update Ubuntu.

The button on the top left hand side of the screen is the "Search" button. Clicking on it will bring up a search Box which lets you find files and apps quickly:

Type in terminal. The icon for terminal should come up as you are typing:

Double click the terminal icon:

This will open the terminal window. We can check if any updates are available by typing:

sudo apt-get update

Then press enter. You will be asked to type your password as this is a "super-user" command - that means it needs special privileges which need your password to execute.

We can see that there are a few updates. Let's install them. Type:

sudo apt-get upgrade

If you have waited a while since the last command you may need to enter your password again.

Type "Yes".

The system will start updating and may take some time as it downloads and installs packages.

When it is finished the command prompt will return as shown.

Congratulations - you now have an up to date Ubuntu installation on a Virtual Machine!


What Next?

Well that is entirely up to you. There are a massive number of online resources for Ubuntu.

The Linux foundation has links to lots of free resources to get you started:

https://training.linuxfoundation.org/free-linux-training

As always Google is your friend here and the only limit is your own imagination. There are a huge amount of tutorials for various linux applications on Steemit too.

You can even install and run the Steem blockchain, the CLI wallet or run your own voting bot.

Conclusion

I hope you found this guide useful and easy to follow. Please let me know if you spot any mistakes.

Thank you for reading.


Before you go have you filled in the Coinbase form to list STEEM? It only takes a few seconds. THIS POST shows you how.


If you like my work please follow me and check out my blog - @thecryptofiend


All uncredited photos are taken from my personal Thinkstock Photography account. More information can be provided on request.


Are you new to Steemit and Looking for Answers? - Try:


HTML tutorial


Sort:  

Hello @thecryptofiend,

Congratulations! Your post has been chosen by the communities of SteemTrail as one of our top picks today.

Also, as a selection for being a top pick today, you have been awarded a TRAIL token for your participation on our innovative platform...STEEM.
Please visit SteemTrail to get instructions on how to claim your TRAIL token today.

If you wish to learn more about receiving additional TRAIL tokens and SteemTrail, stop by and chat with us.

Happy TRAIL!

Thank you that is very kind:)

Thanks glad you liked it mate:)

Agreed but I don't understand all this stuff LOL!

So much tech speak LOL, you know I don't understand most of what you guys all discussed here eh? lol

Good comments once again, good nuggets of info there.

Have a good day man!!!

Great post! Extremely helpful. Gonna take a shot at this :D
Thanks @thecryptofiend

You're welcome! Let me know how you get on:)

Thank you for writing this excellent tutorial!!! Its just what i was looking for. Cheers :)

You're welcome. Thank you so much:)

Great post! I love that Virtual Box is shockingly easy to use, even for the average user!

It's brilliant and best of all free:)

I usually run a dual-boot Windows and Linux computer when I don't use an old desktop PC as a dedicated Linux device. Is a virtual machine easier to use, and does it allow easy switching without rebooting?

Yes it is easier because no rebooting is necessary. You just run it in a Window (or you can use it fullscreen) but you can easily switch between it and your main OS like you would a regular app.

This post has been ranked within the top 10 most undervalued posts in the second half of Jan 12. We estimate that this post is undervalued by $43.78 as compared to a scenario in which every voter had an equal say.

See the full rankings and details in The Daily Tribune: Jan 12 - Part II. You can also read about some of our methodology, data analysis and technical details in our initial post.

If you are the author and would prefer not to receive these comments, simply reply "Stop" to this comment.

Very nice! I used a lot VB in the past, in particular for tutorials. That is the only way if you don't want to spend hours in solving configuration problems on the student machines.

Thanks. I used to use Parallels but VB seems just as good for most use cases, in some respects it is easier to use and best of all is completely free:)

Coin Marketplace

STEEM 0.20
TRX 0.14
JST 0.029
BTC 67443.68
ETH 3234.73
USDT 1.00
SBD 2.65