Installing Linux on a Virtual Machine

From CsWiki
Jump to: navigation, search

Instructions for installing a Linux VM on your personal computer

Installing a virtualization engine

Download debian 9 netinstall image:

Vmware Play

Download link: https://www.vmware.com/il/products/workstation-player.html (easier to use. start a VM from an ISO file, very fast)

Creating a new virtual machine

  • Open vmware play and create a new vm with the iso (probably located in Downloads)
  • Debian installation will start

VirtualBox

  • install virtualbox from https://www.virtualbox.org/wiki/Downloads
  • run virtual box and create new machine:
    • Click on "new" button or in the menu File -> new
      Create a new machine on VirtualBox.png
      • Choose memory size (I chose 2048M RAM, for some JetBrains products like IntelliJ and CLion, 2GB is minimum and 4GB is recommended. Note that your hosting machine = your computer needs a minimum of RAM to function and for running the virtualbox system itself... )
      • Hard Disk: choose "Create a virtual har disk now", the size depends on the free space on your computer but at least 8GB

the type of the disk image can be VDI (to use with oracle virtualbox), VHD (can be use with windows virtualization as well) or VMDK (can be used with VMware virtualization)

  • For the installation, attach the ISO file to the virtual machine:
    • Click on the new virtual machine you created
    • Click on settings, choose "storage"
    • Click on the cd image on the right of the "Optical Drive" and "Choose Virtual Disk File...", choose the debian iso file from your Downloads directory.
    • click OK
    Add cd for virtualbox machin.png
  • Run the machine, and debian installation will start.

Linux Installation process

  • Choose language (I recommend to use English as installation language, and later choose an Hebrew keyboard.)
  • Choose all default values, root password as you wish - but something you'll remember when you'll have to run commands with root (administrator) permissions.
  • In Disk Partitioning you'll have to confirm the partitioning, choosing "yes" instead of the default "no"
  • Right after the basic installation you would be asked to choose additional software. I recommend installing "GNOME" or "KDE" desktops, since JetBrains solutions mention it as system requirement. if you want interface similar to CS', install MATE.

Installing some additional applications

  • Open terminal with Alt-F2, type int "mate-terminal" or "gnome-terminal" or "xterm"
  • Become root by typing "su" in the terminal, and the root password
  • Install sudo : apt install sudo
  • Add yourself to sudo group: (the command will open an editor, default is nano. search text with Ctrl+W, saving is done with Ctrl+O, exiting with Ctrl+X) vigr
  • Edit the line starting with sudo, add your login name after the ':'. if there are more than one user, separate them with comma.
  • Make the same proccess running "vigr -s"
  • In case you are running using VMWare Play, install vmware tools: apt install open-vm-tools

End of installation proccess

Now you have an up and running Linux VM. You can install JetBrains solutions: