Showing posts with label virtualization. Show all posts
Showing posts with label virtualization. Show all posts

Thursday, December 5, 2013

VM Tools on W7 Host

As some may or may not know, for the last few years I have primarily used VirtualBox for all my type two hypervisor needs on my Linux based desktop. Well, the time finally came to work in the reverse direction and start virtualization on the wife’s laptop so I could be more comfortable in my Linux distributions on a Windows host. Rather than install VirtualBox though, I decided to give VMware Player a go as many people have been telling me they find it is much easier to work with.

Similar to VirtualBox guest additions, VMware Player has what are referred to as “Tools” which allow for advanced features required to get the most from our virtual installations. In this short How-To, I wanted to cover getting those installed as the instructions at VMware aren’t really as cut and dry as many people would prefer. In this example, we will be installing the extra tools for a Debian 7.2 guest installation. Just for the record, I went through this once already installing Mint 16 and it was even easier with that distribution then with Debian, however, most of the steps are close to the same.

First thing to do is launch the VMware PLayer


As we will be working with Debian 7.2, we’re going to select that from the left hand column and get it up and running


The next image shows what the installation is like to work with before the VMware Tools are installed. In this condition, working with your VM is less than fun to say the least considering the entire screen size on this particular laptop is only 15”. What we want to do is max this out so that working in our VM is as close to a native installation as possible.


The above view shows the VM maximized on the host. When in the default window size before loading in the extra tools, we will be working with a screen that looks like the one below. We want to click on the button below the VM desktop that says install VM Tools.


After this, in the footer, it’s going to give some instructions to follow but don’t worry about those too much; those instructions are what we are covering here. What we need to do next is eject the disk (if it’s still in the drive) or in this case, I used the iso file to install the OS so we need to go into Places and eject the iso file from the virtual drive. Once the iso is ejected from the virtual drive, the VM will automatically mount the VMware Tools disk and open it for us to get to the Tar file inside which holds the information we are looking for.


Once we are in the drive and find our Tar file, we want to copy this over to the tmp folder found in our root files; simply copy and paste to do this. There is no need to become root to paste this file into the tmp folder.


Once the Tar file has been copied over, eject the disk from the virtual drive and come back to the temp folder. Perform a right-click on the Tar file and extract the contents directly into the tmp folder. There is nothing more than another folder inside the Tar file called vmware-tools-distrib that holds the files we need to do our installation. Once that file is extracted, double click on it to get inside.


Once inside this file, we will find the compiled program we want to run and it needs to be run from the terminal. In some distributions, there is an option to “run terminal from here” which is one of my favorite handy dandy apps (so much easier than having to navigate through the CLI). If that is not an option, open a terminal as root or become root in a terminal and navigate to the folder with vmware-install.pl in it. Run the command as in the screenshot above to run the installation.

./vmware-install.pl

Accept all the defaults

If we are lucky, such as was the case when I did this with Mint, there will be no dependency packages to have to chase down. With Debian, I had to shut down the installation and install some dependencies then come back and do these steps all over again. Not a big deal really, but just slightly annoying. The installer is pretty smart and knows how to deal with this situation so don’t panic if the first time around you have to go back and do some other stuff. It will rewrite everything and repeat the process as many times as necessary without breaking anything.

Once all is said and done, restart your installation and when the OS has completely boot click on maximize and now we should be working with a full screen installation such as the one below.


Definitely a better looking environment and more practical than the tiny screen we started out with.

This is one way to do the installation which is simply a variation to the original instruction found at VMware located at the link below. In their instruction they will walk you through the command line operations. They’re kind of dated, but the concept is pretty much the same.

http://www.vmware.com/support/ws55/doc/new_guest_tools_ws.html

Saturday, November 23, 2013

VMWare on W7

From some of my previous articles, people know that I have been using VirtualBox for sometime on Linux systems for a variety of tasks but primarily to run Windows as I’m not a big fan of dual-booting. After discussions with others who use type 2 hypervisors, I decided it was time to give VMWare a whirl so I installed it on my wife’s laptop running Windows 7 allowing me to be more comfortable using my Linux distribution in place of Windows. With so many people promoting VMWare, including my cousin over at Apple, I had high expectations from this software and still do aside from the following error I had to get through to install on the laptop.

When the first installation didn’t go through I was actually very surprised and preceded to try the installation again. On the second go around I got the following error:



Well, these things just happen now and again so I turned to my friends at Google and see what I can dig up. A few different opinions as to what the problem could be, many of which involve Avast but that’s not the issue in my case.

Another problem some people seemed to have was not having appropriate permissions to install the software on their machine so following those directions make sure to have administrative rights on the machine. Odds are good this is not the problem with most installations so on to the solution that worked.

Follow the path as shown in the image above and DELETE everything in the Temp folder. I had some 600+ files sitting in there which are all unnecessary stuff used by various programs and operations performed at one point or another. It’s completely safe to delete these files and if a person runs Disk Cleanup religiously, it should keep the files down to a manageable state.


Once the Temp folder has been cleared out, restart the computer and navigate over to the installation file for VMWare again BUT instead of simply clicking to install, perform a right click which should bring up an options window and click on “ Run as Administrator”. At this point the installation should go as planned.

Gotta love those small bugs that keep you on your toes.

Friday, March 22, 2013

VirtualBox Updated

I’ve read through a lot of forums on how to update Oracle’s VirtualBox and never really found many of them to be all that informative. I find a lot of answers to be rather short, fairly direct but not very good at giving directions. While the process is fairly simple, when someone hasn’t done it before and isn’t sure what they should do, the idea can be a little daunting. I run VBox on openSUSE with a few instances running and it is fairly easy once a person has done it a few times. Here is how it gets done using openSUSE.

Obviously, the new version needs to be downloaded with the extension pack that goes with it. It is important to note that the extension pack and VBox version numbers need to match as they are harmonious in their usage. Keep the both of them together and possibly make a backup if necessary.
 

First thing to do is make a backup of the directory housing all the virtual machines. The update process doesn’t mess with these, but it doesn’t hurt to have a backup anyway since as we all know “stuff happens”. Since a lot of the machines I run are installed directly from the iso files for various Linux systems, I keep these in a directory the same as the virtual machine directory and back them up as well. Doing this keeps all our data in a nice cozy spot that can be accessed just in case things don’t go as planned for some odd reason.
 

Next, open YaST and in the search box on the left type in Oracle and click on the box checked with VirtualBox until it become a red X to signify removal of the software from the system then click “Accept” to have it removed. Once that is done click the rpm VBox file and let it install itself. Believe it or not, the process is almost half done.
 


Start VBox and go to File > Preferences > Extension and select the old version of the extension pack and remove it. Then of course select to add a new extension and add the new one in its place. Now both the new VBox and the new extension pack that goes with it are installed and almost ready to be used. Now go into system runlevels and restart VBox.
 


Go back into YaST and go to System Services (Runlevels) and once that opens scroll down to the V’s and there should be an asterisk next to a couple of the VBox items that need to be running for it to work. Select each one with an asterisk and click on “Enable” to get them running again. Remember, don’t forget to click on “Ok” in the lower right corner or none of the changes will get registered with the system! If for any reason something doesn’t restart right, then check with the support team over at openSUSE and find out why, but there shouldn’t be any problems.
 


The last thing to do is reboot the system and launch VBox. Each of the machines will need to have the new extension pack re-installed for it to take effect.
 

Sunday, February 10, 2013

Oracle VirtualBox Repaired

For those individuals who choose to run other operating systems inside of VirtualBox instead of a dual boot system and run into the problem associated with a Linux kernel update, this short tutorial is what needs to be done to resolve that problem. It’s not as devastating as some may think it’s just a matter of where to go and what to do. Do not lose hope, all is not lost. This tutorial covers how to get an Oracle V-Box back up and running with no loss of any data or having to freak out looking for any other file upgrades or anything like that.

In an ideal world, when the kernel updates come through there really shouldn’t be any issues with our virtual machines, as it happens though, for whatever reason this is not the case. When the system kernel gets updated, the link gets broken between the virtual machine and the kernel that allows it to utilize system resources. Fixing this is really easy to do and I’ll walk through the process step by step as I have done a few times in the past.

The most immediate notification of this circumstance is when someone tries to open a virtual machine and gets this pop-up notification that something has gone wrong an VirtualBox needs attention before it will work again.



While the instructions are there of what needs to get done to repair the problem, since those instructions have already been followed once when the virtual machine was installed they really aren’t what needs to be done now. The key in the pop-up is the vboxdrv file which will need to be restarted in YaST. To do this, go to YaST and scroll down to System then select System Services (Runlevel) such as shown below.



Once inside, don’t be fooled by what is shown that all the files associated with VirtualBox are in fact running. They are, but just like certain updates to a system they need to be re-started for the changes to take effect. In the uppermost top left is a radio button that says Expert Mode, click on this button and scroll down until the vboxdrv file is viewable. Click on this file line to select it and at the bottom of the screen is a button that says Start/Stop/Refresh. Go ahead and select restart to restart the instance of the file with the new kernel installed. Just for good measure, I restarted all the files associated with VirtualBox. REMEMBER TO CLICK ON OK IN THE LOWER RIGHT CORNER! If ok is not clicked the change will not be recorded with the system so do not forget!



Now go back and start whatever operating system is being used inside of VirtualBox and everything should work as planned. No system re-boot is necessary as the changes have already been recorded with the system when the ok button was pressed.



Monday, January 14, 2013

Dexpot - Virtual Desktops for Windows

For those people who are still using Windows, or especially those frustrated with having to use it at work or some other reason when the preferred OS is a Linux distribution, this free program can make life a little bit tolerable. Dexpot is a nice little program that allows Windows users to enjoy the functionality of multiple virtual desktops we Linux users have come to appreciate and rely on to be more productive. After years of working with multiple desktops, sitting in front of a Windows machine and flipping through tabs and tabs of open applications I constantly remind myself how spoiled I am to have something so simple associated with my OS that just makes daily life a little easier.

The writers have done a great job at making installation as simple as just a couple of mouse clicks. After all is installed, this little program runs in the background and when set up, can show icons of all the desktops in the taskbar.


A simple click of the dropdown arrow or icon in the taskbar will show the control panel for Dexpot where the user can go into the program and make tweaks and adjustments to set the program up to their own personal liking.


For those who have never worked with virtual desktops before, I would personally suggest trying a variety of settings to see which ones work best for their particular style of usage. I actually prefer a little bit of extra “eye candy” to my daily functions so I prefer having the cube do my desktop switching graphics. I have also found it handy to have icons show up in the various taskbar screens so I have a reminder of what I have open and in which desktop. The image below shows that there is quite a bit of functionality built into this little program that by the way, is FREE for private use!


From the standpoint of a seasoned virtual desktop user, the most used functionality I found was under the General tab (of course) to select the number of desktops and under Switching Desktops and Plugins and Extras. Clicking on the various plugins will activate them so there’s no worry about getting lost in all the functions available or running into stuff not necessary while doing various things.


Under the controls tab, users can select a variety of mouse gestures or hotkeys that may be useful for some individuals. Just remember that assigning hotkeys to Dexpot could interfere with other hot key controls that are used for other routine functions so proceed with caution when exploring with these options.


Below is a shot of the options available with mouse controls. Sometimes it’s handy to be able to switch desktops just by pushing the mouse to the right or left of the screen and waiting a few hundred milliseconds. Other people may find this annoying and turn this function off. Most options are off by default which makes it much easier to set up Dexpot to your liking since I believe that most people find it annoying to have options on then try and figure out what it is they need to turn off.


Below is a screenshot I captured of the cube plugin screen switcher option. As I mentioned, there is a lot of options to go through and a lot of useful functionality built into this free program. If a person is accustomed to using a Linux OS and wants the functionality of their virtual desktops carried over to a Windows machine then this is the answer to make your life more tolerable. For those who are already Windows users and really don’t understand much about what is being presented in this article, I suggest giving it a whirl and in just a matter of minutes it will become clear. Either way, Dexpot is one of those great free programs that has changed the way Linux users appreciate the time they have to spend on a Windows machine.


Download Dexpot @ http://dexpot.de/

Tuesday, July 17, 2012

Virtually Shared Folders

While in the midst of a class discussion, one of my classmates was doing a presentation on virtualization. The presentation was done very well and afterwards questions were asked. One question that seemed to be on most minds was how to access folders on the host from the guest installation. This is actually a very easy thing to do, at least with VirtualBox and I would expect that VMWare is just as simple.

I was actually surprised with how many students in the class had not explored setting up a virtual machine. The entire process is actually pretty simple (at least to me). The benefits of having a virtual machine are really only limited to one’s imagination on what would a person do with an OS that they didn’t have to care if it crashes? How much exploration or trial and error would someone be willing to do if they didn’t have to worry about the ramifications of making a mistake? What would be the educational benefits of being able to try something totally crazy or bleeding edge new?

In this how-to I’m going to show just how easy it is to set up file sharing between an openSUSE host and a Windows guest. Perhaps once people get the opportunity to see just how simple this is, more people will consider being a little more adventurous with their systems. This also gives new IT students an idea of how simple it can really be to set up a virtualized server running a variety of different operating systems for their users based on requirements of the clients.

The first thing I usually do is to take a look at my uppermost file system and decide which ones I want to share with any particular guest. Although it is completely possible to simply provide access to the entire root system of the host, I don’t recommend it. If something should go buggy or awry with any particular guest situation, I personally wouldn’t want it to have access to too much on the host system.

Since I use virtual machines fairly frequently, I have a file structure that I create with every OS installation with the intent of providing sharing to a virtualized guest. In this case I am going to be sharing Documents, Downloads, Pictures and School.



Once the decision of what folders will be shared then we can go ahead and start our virtual machine and set these folders up to be accessed from our guest machine. Obviously this decision can be done simply from the selection process or, as in my earlier day of setting up virtual machines, a person may want to create folders specifically to be shared with each machine in particular. As an example “Windows Folder” either in the top tier or as a sub folder perhaps under documents.

One example of why this would be good is if a person decides they don’t want to provide internet access to their virtual machine. I typically turn off internet to my Windows machines and only download or access the internet through my Linux host. By doing things this way I don’t worry too much about virus protection or malware getting to my Windows install. Even if something does get in, I really don’t care since the OS is just a virtual guest which can be simply replaced anytime. This decision can be invoked or revoked any time with just a simple setting.

The next action to take is to start VirtualBox and go into the settings tab in the top left prior to starting the actual guest OS.



Inside the settings, on the left hand side, navigate down to “Shared Folders” and click on it. In the window that opens over on the right shows a file tree window and just to the right of that is a tiny folder with a green plus sign. Click on this little folder and a file browser will open allowing navigation to the folder to be shared between host and guest systems.



Repeat this process to add all the files you will want to allow access to between the guest and the host. As I stated earlier, I wouldn’t get overly zealous with this action. It is much safer to be conservative especially when various file types will probably be created and shared to the host over a period of time. Keeping your file system clean and organized is always a good thing.

Repeat this process to add all the files you will want to allow access to between the guest and the host. As I stated earlier, I wouldn’t get overly zealous with this action. It is much safer to be conservative especially when various file types will probably be created and shared to the host over a period of time. Keeping your file system clean and organized is always a good thing.



This is all fine and good for being able to access our folder system on the host machine but, what we really want to do is be able to access these documents with an application set up to run in our guest. So lets go ahead and fire up Adobe Illustrator and try to access some image file which is truly stored in our Pictures folder on our openSUSE host machine. Files for use in applications can either be accessed this way or they can be copied over into the guest machine and utilized there. Keep in mind though that the guest machine in itself without a lot of files in it takes up a lot of space. Windows 7 is kind of a space pig (in my opinion) although the sacriface is worth the improvement over the Vista release.


Once we have our software open, lets go ahead and open up a file we want to work with.


The end results are exactly as we want. We opened a file which was originally stored on the host machine for use in an application written to run on our guest machine. Kind of gives us the best of both worlds doesn’t it?

As can be seen this was really easy to set up and execute. If for any reason anyone runs into a problem with their folder sharing with VirtualBox, the first thing to do is go to the VirtualBox website and sift through the forums. Odds are really good someone else has asked the same questions or had the same problems.









Tuesday, July 10, 2012

How-To Set Up VirtualBox in openSUSE 12.1


 
  Recently I needed to do a new install of VirtualBox on my openSUSE 12.1 desktop. I usually only do this when I get in the mood to test new operating systems or I need a version of Windows for something specific that Linux isn’t suited for. I used to keep a copy installed by default, but lately I have been more resourceful in getting things done without Windows. This just happened to be one of those times when I had a new OS that I had never experienced before and I needed a platform to try it out on (the story on that later).

 I know that a lot of people still aren’t familiar with virtualization or how to set one up or what they would even want one for. There are also a lot of relatively new Linux users that still do the dual-boot system on their computers running Windows next to Linux and choose which system to run on start. When I started using Linux back in 2009, I did the very same thing so I could continue to be productive in my old ways while learning to accept change and migrate over to a Linux OS. Whatever the reasoning, often times Linux users still end up needing a copy of Windows for some reason or another now and again however, as each new release of the various Linux distributions improve in user interface, operation, and efficiency, I’m seeing less and less dependencies on the old Microsoft build.

 The dual boot system works fine for those who insist on having their OS have direct control to the hardware and network. The problem lies in the fact that some OS are more prone to infection and virus than other systems and if one of the two gets in deep enough trouble, it could render the entire machine useless and require a complete scrub and new install. By installing a second OS through means of a virtual machine such as Oracle’s VirtualBox, there is only one log in screen and when the need to use a secondary OS is required, a user just starts up the virtual instance just as if it were another program. If the secondary OS becomes unstable or infected in some way there is no complete loss, just scrub the virtual machine and install it again. Running two operating systems in this manner is far safer than trying to run side by side.

 Getting past a simple why and into the how-to section, obviously the first thing anyone is going to want to do is to visit the Oracle VirtualBox download page and find the correct version for their particular openSUSE distribution. I strongly suggest taking the time to read the documentation on this page and not just surf for the matching download to their particular system. It does make a difference as to whether or not a 32 or 64 bit will be the host OS. There are also a lot of hints, tips and tricks to installing VirtualBox on Linux so do your reading and save aspirin! While on the download page, make sure to also download the extensions pack that goes with the version of VirtualBox. The serial numbers should match on both.

 Once both the software and extension pack have been installed, don’t do anything with them just yet. As much as we would like, they are not ready to go right off the bat. There are a couple of things that need to be done prior to installing the first “guest” OS. Considering how popular the use of VirtualBox has become to Linux users over the last couple of years, I would hope that in future releases of openSUSE the programming engineers could make the installation a bit simpler, for now though it is what it is and that’s why I’m writing this how-to.

The next thing to do is go to YaST and in the search box on the upper left corner type in “DKMS”. Select the checkbox and install it. DKMS is an acronym for “Dynamic Kernel Module Support”. These packages are required for VirtualBox to generate Linux kernel modules for itself when updates are made and for driver support. No, I don’t know a whole lot about it except for the fact that the installation of VirtualBox will give an error when trying to initialize without it.


 After DKMS is installed then we can go ahead and get VirtualBox in. This should have been downloaded from Oracle as an RPM package. These are the best and easiest packages to deal with in openSUSE. They operate just like the old EXE files for Windows programs. Just click on the file and openSUSE will take care of the rest. Don’t get overly excited just yet however, there are still a number of steps we have to go through before we can actually get our guest OS up and running so just be patient and follow along. Once the loader is done doing its thing, go to the application launcher in the lower left corner and navigate to  Applications -> System -> Emulator and there should be the installation of VirtualBox. At this particular point I would actually suggest doing a right click and adding it to favorites since it will probably get used quite a bit in the beginning.


Once this is done there is another thing we need to do in YaST, so start this up and go to System -> System Services (Runlevel). For whatever reason there are dependencies for VirtualBox that do not initialize automatically so we are going to have to tell them to start with our system by default.



Once inside the runlevels interface up at the top, click on the radio button that says “Expert Mode”. Don’t worry about this too much, it’s not as intimidating as it sounds. Once the interface has changed scroll down to almost the bottom and look for the service called “vboxdrv” and click on it so that it is highlighted green or selected. For whatever reason, this is always “no” by default and it needs to be turned on for our program to work. Once selected, click on the button below that is labeled “Start/Stop/Refresh” and in that dropdown select “Start Now”. Next to the service the running indication should switch from no to yes. Once this is done make sure to click on the green button in the lower right corner labeled Ok and the setting will get saved. Now, every time the computer is started, this service will begin running automatically.


Once these steps are complete, we need to give ourselves permission to use our virtual application. This may seem odd, but this is the way it gets set up. So again go to YaST and navigate over to Security and Users -> User and Group Management. In the top tabs of this



screen select “Groups” and there should be a group called “vboxusers”. Highlight this group and at the bottom of the screen select “Edit”. In the next screen, in the column on the right look for your user name and check the box next to it then click “Ok”. You have now set permissions for yourself as being authorized to use VirtualBox.


The next hurdle to have to jump through is adding in some RPM groups associated with keeping all the kernel information cool with our virtual environment. These are loaded directly through the terminal so open one up of choice and log in as root. Now type in the following string and just select “y” every time it asks.

zypper in gcc make kernel-devel

Finally we have reached the point where we can re-boot the system so everything we changed gets set into place and start using our virtual environment.

I know this seems like a lot of work to set up a virtual machine, but once all is said and done, the payoff is totally worth it. I have actually had 4 different operating systems installed into one of these before for various levels of testing and trial purposes. One of the nice things is that a virtual machine can also be used for testing the same OS as the host before modifying the host itself. There are a number of good reasons for taking the time to install virtual machines besides being able to run Linux and Windows at one station. So I urge people to give it a try.

I also want to thank my friends over at openSUSE for helping me when I get stuck and motivating me to continue writing about my experiences and explorations with what I consider to be one of the most user friendly free OS available today. If for any reason these instructions aren’t working for anyone, please feel free to review the source I used to create them.