LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Help installing latest Wine and Virtualbox! (https://www.linuxquestions.org/questions/slackware-14/help-installing-latest-wine-and-virtualbox-4175416103/)

Laxman_prodigy 07-11-2012 06:32 AM

Help installing latest Wine and Virtualbox!
 
Hey.

I see the version of Virtualbox a little older than offered at their sites. I have gone multilib on Slackware 13.37 just couple of hours ago with the help of folks around here.

How do you install Virtualbox?

EDIT: And about Wine, will the .txz package from the Wine HQ work straight away if I have multilib enabled?

ruario 07-11-2012 06:38 AM

Quote:

Originally Posted by Laxman_prodigy (Post 4724873)
How do you install Virtualbox?

If you don't want to use the SlackBuild, you could just use the VirtualBox generic install script that they provide (I do this myself).

This would involve installing as follows:

Code:

$ wget http://download.virtualbox.org/virtualbox/4.1.18/VirtualBox-4.1.18-78361-Linux_amd64.run
$ chmod +x VirtualBox-4.1.18-78361-Linux_amd64.run
$ su
Password:
# ./VirtualBox-4.1.18-78361-Linux_amd64.run

Should you ever want to uninstall, switch to root and issue:

Code:

# /opt/VirtualBox/uninstall.sh

ruario 07-11-2012 06:46 AM

If you don't trust the installer (I would, but then I have used it quite a few times). You can get a rough log of the files it places down by running a find command before and after the install and diffing the results as follows:

Code:

# find /etc /opt /usr ! -type d -print > /tmp/before_vbox
# ./VirtualBox-4.1.18-78361-Linux_amd64.run
# find /etc /opt /usr ! -type d -print > /tmp/after_vbox
# diff /tmp/before_vbox /tmp/after_vbox | sed -n 's/^> //p' > VirtualBox-4.1.18-78361_install.log

In addition to the files listed in VirtualBox-4.1.18-78361_install.log. The install script will also add some commands to /etc/rc.d/rc.local and (I think, though perhaps I added them myself) /etc/rc.d/rc.local_shutdown, so have a look at these files before and after install.

For a more comprehensive tracking solution:

Code:

$ man slacktrack

Laxman_prodigy 07-11-2012 06:48 AM

Quote:

Originally Posted by ruario (Post 4724879)
If you don't want to use the SlackBuild, you could just use the VirtualBox generic install script that they provide (I do this myself).

This would involve installing as follows:

Code:

$ wget http://download.virtualbox.org/virtualbox/4.1.18/VirtualBox-4.1.18-78361-Linux_amd64.run
$ chmod +x VirtualBox-4.1.18-78361-Linux_amd64.run
$ su
Password:
# ./VirtualBox-4.1.18-78361-Linux_amd64.run

Should you ever want to uninstall, switch to root and issue:

Code:

# /opt/VirtualBox/uninstall.sh

Hey, thanks mate.

Okay, so are there any other things to be careful about before installing Virtualbox? I mean, some dependencies or guest additions? Could you help me with the Wine too? Sorry for bombarding but am new at this all. But, am loving it! :D

ruario 07-11-2012 06:54 AM

If you did a full Slackware install it should just work. If not you should get an error, which will give you clues anyway. The guest additions are for the guest OSes running underneath it, not the host (your PC) that is running VirtualBox itself.

I don't use Wine but I believe most people who are using it here, just use the Wine SlackBuild after first making there system multilib (which you have already done).

P.S. If you haven't used SlackBuilds before, read the HOWTO.

Laxman_prodigy 07-11-2012 06:57 AM

Quote:

Originally Posted by ruario (Post 4724889)
If you did a full Slackware install it should just work. If not you should get an error, which will give you clues anyway. The guest additions are for the guest OSes running underneath it, not the host (your PC) that is running VirtualBox itself.

I don't use Wine but I believe most people who are using it here, just use the Wine SlackBuild after first making there system multilib (which you have already done).

P.S. If you haven't used SlackBuilds before, read the HOWTO.

Thanks man! Yeah, I have used Slackbuilds, but a little and then came sbopkg. :) Will give it a go and report back!

tronayne 07-11-2012 07:05 AM

You need the Extension Pack too: https://www.virtualbox.org/wiki/Downloads and it's right there in front of you.

When you start VirtualBox (without starting a virtual machine), click File, Preferences, Extensions and add the Extension Pack you downloaded (the current version is Oracle_VM_VirtualBox_Extension_Pack-4.1.18-78361.vbox-extpack). Do not install an Extension Pack with a different version number.

Included in the installation of VirtualBox are Guest Additions; you will want to add those to any virtual machine you install. If you're installing the Guest Additions in a Windows virtual machine, you do that after Windows is installed (and you've gotten the 200+ Critical Updates downloaded, of course) -- boot Windows in Safe Mode then install the Guest Additions. This is documented in the UserManal.pdf that you'll find in /opt/VirtualBox.

Hope this helps some.

ruario 07-11-2012 08:28 AM

Tracking software outside of pkgtools
 
Just a side note regarding this:

Quote:

Originally Posted by ruario (Post 4724885)
If you don't trust the installer (I would, but then I have used it quite a few times). You can get a rough log of the files it places down by running a find command before and after the install and diffing the results as follows:

Code:

# find /etc /opt /usr ! -type d -print > /tmp/before_vbox
# ./VirtualBox-4.1.18-78361-Linux_amd64.run
# find /etc /opt /usr ! -type d -print > /tmp/after_vbox
# diff /tmp/before_vbox /tmp/after_vbox | sed -n 's/^> //p' > VirtualBox-4.1.18-78361_install.log

In addition to the files listed in VirtualBox-4.1.18-78361_install.log, the install script will also add some commands to /etc/rc.d/rc.local and (I think, though perhaps I added them myself) /etc/rc.d/rc.local_shutdown, so have a look at these files before and after install.

If you go down this route, after making VirtualBox-4.1.18-78361_install.log manually check that it only has VirtualBox files (if you installed anything else in the background or made configuration changes in /etc, these might be listed). Once you are satisfied that they are VBox only files keep this log around as it means that should you ever want to kill VirtualBox, instead of /opt/VirtualBox/uninstall.sh you could simply do the following:

Code:

# cat VirtualBox-4.1.18-78361_install.log | xargs -d'\n' -n1 rm -v
Note: The changes to /etc/rc.d/rc.local would remain but the commands in them check for the precence of an installed VirtualBox before they attempt to run anything, so they are fairly harmless. Additionally, that command would leave behind some empty directories created by the VirtualBox install script. I intentionally left directories out of the find command because it simplifies the result and because empty directories don't really affect anything. Though if empty directories really bother you, they are fairly trivial to locate with a find command, e.g.:

Code:

# find /etc /opt /usr -type d \( -iname "vbox*" -o -iname "virtualbox*" \) -print
Another nice thing about creating install logs like this for VirtualBox is that you can make a binary backup package of the software. This is handy for quick reinstall (no compiling kernel modules), or for install on another similar architecture and version Slackware machine, even if the other machine does not have the kernel-source package installed (though you'd need to update /etc/rc.d/rc.local manually). This can be done as follows:

Code:

# cat VirtualBox-4.1.18-78361_install.log | cpio -ovHnewc | xz > VirtualBox-4.1.18-78361.x86.linuxbinary.cpio.xz
Once done you don't even need to keep VirtualBox-4.1.18-78361_install.log around anymore as the archive itself is also the log, e.g. you could use it to remove VirtualBox like so:

Code:

# xz -d < VirtualBox-4.1.18-78361.x86.linuxbinary.cpio.xz | cpio -t | xargs -d'\n' -n1 rm -v
If you wanted to reinstall (or install on another machine), you would issue:

Code:

# xz -d < VirtualBox-4.1.18-78361.x86.linuxbinary.cpio.xz | cpio -imdv
Or if you are more of a tar fan. Here are those three commands again, tar-style.

Make binary backup package:
Code:

# cat VirtualBox-4.1.18-78361_install.log | tar -T- -cvPJf VirtualBox-4.1.18-78361.x86.linuxbinary.tar.xz
Note: If you made the log differently and it included directories as discrete entries you would also need GNU tar's "--no-recursion" switch.

Remove software:
Code:

# tar Ptf VirtualBox-4.1.18-78361.x86.linuxbinary.tar.xz | xargs -d'\n' -n1 rm -v
(Re-)install software:
Code:

# tar Pxvf VirtualBox-4.1.18-78361.x86.linuxbinary.tar.xz
You can actually use simple tricks like this with almost any other software you wish to track, e.g. source installs where you are too lazy to make a SlackBuild.

That all said, it would be remiss of me not to mention that slacktrack, src2pkg, paco, etc. are better and more comprehensive solutions. What I like about doing things the way I outline above is the simplicity. No extra tools are required and the same kinds of tricks will work across distros.

Edit: If anyone is curious, on my own machine I make a directory ('/var/log/footprints/') where I keep logs for software that I am tracking in this way. For example on the machine I am using now that directory contains:

Code:

$ ls /var/log/footprints/
Pike-7.8.352
VirtualBox-4.1.18_78361
dillo-3.0
evilwm-1.1.0
fltk-1.3.0
heirloom-pax-070715
html2text-1.3.2a
jruby-1.5.5
karmen-0.15
kpartsplugin-20120605
littleutils-1.0.25
lxz-0.01
lzma_alone-9.20
lzop-1.03
wmx-7

Within the log files I add a reference to the log itself as the last entry, e.g.:

Code:

$ cat /var/log/footprints/heirloom-pax-070715
/usr/local/bin/pax
/usr/local/share/man/man1/pax.1.gz
/var/log/footprints/heirloom-pax-070715

That way a removal command would remove everything, including the log itself, e.g.:

Code:

# cat /var/log/footprints/heirloom-pax-070715 | xargs -d'\n' -n1 rm -v
removed `/usr/local/bin/pax'
removed `/usr/local/share/man/man1/pax.1.gz'
removed `/var/log/footprints/heirloom-pax-070715'

Now excuse me while I go and re-install heirloom-pax. ;)

P.S. [Even further off-topic] Compiling heirloom-pax the way I want is slightly messy. I'm half-way to a proper build script. I really should find the time to convert it to a SlackBuild and submit it to SBo. There is already one pax on SBo but this one has a lot of nice options not found in the more common pax implementations, such as being about to read and write the following cpio formats: newc, crc, sco, scocrc, odc, bin, bbs, sgi, cray, cray5 and dec, in addition to tar, otar, ustar, pax, suntar, gnutar, bar and even zip!

ruario 07-12-2012 02:18 AM

Quote:

Originally Posted by ruario (Post 4724879)
Should you ever want to uninstall, switch to root and issue:

Code:

# /opt/VirtualBox/uninstall.sh

Actually a quick test showed me that /opt/VirtualBox/uninstall.sh leaves behind a directory (/usr/lib/python2.6/site-packages/vboxapi) with 156.8KiB of files in it. Not much but I should probably report it upstream.

EDIT: Plus the 4.0KiB /usr/lib/python2.6/site-packages/vboxapi-1.0-py2.6.egg-info file.

EDIT 2: Logged www.virtualbox.org/ticket/10752


All times are GMT -5. The time now is 10:44 PM.