在Ubuntu12.04下安装VirtualBox 小结

如果之前安装过Virtualbox,首先会需要进行卸载:

方法一:

首先,在终端查看已经安装的VirtualBox的版本:
$ dpkg -l
此会列出所有安装的软件。查看到VirtualBox版本号,例如:virtualbox-4.3
执行卸载:
$ sudo apt-get remove virtualbox-4.3

方法二:

百度经验上是使用 sudo apt-get remove virtualbox* 去进行卸载的


安装VirtualBox 4.3
    第一步:
    打开sudo gedit /etc/apt/sources.list此文件,将以下源添加到文件最后。

    deb http://download.virtualbox.org/virtualbox/debian saucy contrib
    deb http://download.virtualbox.org/virtualbox/debian raring contrib
    deb http://download.virtualbox.org/virtualbox/debian quantal contrib
    deb http://download.virtualbox.org/virtualbox/debian precise contrib
    deb http://download.virtualbox.org/virtualbox/debian lucid contrib non-free
    deb http://download.virtualbox.org/virtualbox/debian wheezy contrib
    deb http://download.virtualbox.org/virtualbox/debian squeeze contrib non-free

    第二步:
    新建oracle_vbox.asc为名的文档,复制以下内容(全部复制)到此文档,并保存。
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.4.9 (GNU/Linux)

mQGiBEvy0LARBACPBH1AUv6krDseyvbL63CWS9fw43iReZ+NmgmDp4/sPsYHLduQ
rxKSqiK7fgFFE+fas/7DCaZXIQW6hnqeD3CgnX0w1+gYiyqEuPY1LQH9okBR5o92
/s2FLm7oUN4RNGv6vWoNSH1ZiRHknL5D0pKSGTKU+pG6cBYWJytAuJZHfwCguS55
aPZuXfhjaWsXG8TF6GH0K8ED/RY3KbirJ7rueK/7KL7ziwqn4CdhQSLOhbZ/R2E0
bknJQDo+vWJciRRRpTe+AG59ctgDF7lEXpjvCms0atyKtE8hObNaMJ5p48l/sgFL
LEujqiq4tByAn2hDOf0s7YrfruIY+HHkBSI9XbwH9nPlsQq8WNsTWTzPrw+ZlQ7v
AEuuA/9cJ/4qYUOq1pg3i/GqH+2dbRHOFH6idXr5YrdB3cYW8jORagOcwdQHeV/0
CaTZVMyMhTVjtIiUt+UR/96CHKxedg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UTnq
qACgtXuTbe2b72sgKdc6gGRKPhLDoEMAmgLwGVN3a4CqewQL+03bqfcKczNH
=19g1
-----END PGP PUBLIC KEY BLOCK-----

    第三步:
    进入oracle_vbox.asc文件所在目录(以你建的为主),执行下面命令。
    sudo apt-key add oracle_vbox.asc

    第四步:
    wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add -

    第五步:
    sudo apt-get update
    sudo apt-get install virtualbox-4.3







郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。