Linux环境安装VirtualBox

简介: VirtualBox是一款强大的x86和AMD64/Intel64虚拟化产品,适用于企业和家庭。VirtualBox不仅是为企业客户提供的一款功能丰富、高性能的产品,它也是根据GNU通用公共许可证(GPL)版本3条款作为开放源码软件免费提供的唯一专业解决方案。有关VirtualBox的介绍请参见“关于VirtualBox”。

在官网下载virtualbox


简介


irtualBox是一款强大的x86和AMD64/Intel64虚拟化产品,适用于企业和家庭。VirtualBox不仅是为企业客户提供的一款功能丰富、高性能的产品,它也是根据GNU通用公共许可证(GPL)版本3条款作为开放源码软件免费提供的唯一专业解决方案。有关VirtualBox的介绍请参见“关于VirtualBox”。


目前,VirtualBox运行在Windows、Linux、Macintosh和Solaris主机上,支持大量客户操作系统,包括但不限于Windows (NT 4.0, 2000, XP, Server 2003, Vista, Windows 7, Windows 8, Windows 10), DOS/Windows 3。x, Linux (2.4, 2.6, 3)Solaris和OpenSolaris、OS/2和OpenBSD


VirtualBox正在积极地开发,频繁地发布版本,并拥有不断增长的功能列表,支持它所运行的客户操作系统和平台。VirtualBox是一个由专门公司支持的社区努力:鼓励每个人都做出贡献

下载链接acc87c7eb010436a88871888ed87c6f4.png有很多linux发行版,选择适合自己的版本下载,我这里是centos78c131cfa3f774b5e8d821c3af8caff31.png

安装


yum -y install VirtualBox-6.1-6.1.32_149290_el7-1.x86_64.rpm

报错处理


缺少libSDL-1.2.so.0 依赖


3651fb78afbc470f8a7aee9d34edf6e4.png下载链接0867434f8db0496d80908d1e822170c1.png

The vboxdrv kernel module is not loaded.


8d571b2ebd66478792e9899307db26bb.png安装OS 的时候没有安装kernel-moduel 等相关依赖。/sbin/vboxconfig 往内核编译virtualbox相关模块时报错。infra协助挂载hel-server-7.8-x86_64-dvd.iso 进行安装后解决。

[root@179-sc /monitor/monitor-vagrant/meta]#vagrant up
No usable default provider could be found for your system.
Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.
The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.
If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#vagrant up --provider=VirtualBox
The provider 'VirtualBox' could not be found, but was requested to
back the machine 'meta'. Please use a provider that exists.
Did you mean 'virtualbox'?
Vagrant knows about the following providers: docker, hyperv, virtualbox
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#vagrant up --provider=virtualbox
The provider 'virtualbox' that was requested to back the machine
'meta' is reporting that it isn't usable on this system. The
reason is shown below:
VirtualBox is complaining that the kernel module is not loaded. Please
run `VBoxManage --version` or open the VirtualBox GUI to see the error
message which should contain instructions on how to fix this error.
[root@179-sc /monitor/monitor-vagrant/meta]#^C
[root@179-sc /monitor/monitor-vagrant/meta]#^C
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#VBoxManage --version
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
         available for the current kernel (3.10.0-1127.el7.x86_64) or it failed to
         load. Please recompile the kernel module and install it by
           sudo /sbin/vboxconfig
         You will not be able to start VMs until this problem is fixed.
6.1.32r149290
[root@179-sc /monitor/monitor-vagrant/meta]#^C
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#
[root@179-sc /monitor/monitor-vagrant/meta]#/sbin/vboxconfig
vboxdrv.sh: Stopping VirtualBox services.
vboxdrv.sh: Starting VirtualBox services.
vboxdrv.sh: Building VirtualBox kernel modules.
This system is currently not set up to build kernel modules.
Please install the gcc make perl packages from your distribution.
Please install the Linux kernel "header" files matching the current kernel
for adding new hardware support to the system.
The distribution packages containing the headers are probably:
    kernel-devel kernel-devel-3.10.0-1127.el7.x86_64
This system is currently not set up to build kernel modules.
Please install the gcc make perl packages from your distribution.
Please install the Linux kernel "header" files matching the current kernel
for adding new hardware support to the system.
The distribution packages containing the headers are probably:
    kernel-devel kernel-devel-3.10.0-1127.el7.x86_64
There were problems setting up VirtualBox.  To re-start the set-up process, run
  /sbin/vboxconfig
as root.  If your system is using EFI Secure Boot you may need to sign the
kernel modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) before you can load
them. Please see your Linux system's documentation for more information.
[root@179-sc /]#ll /etc/yum.repos.d/
total 8
-rw-r--r-- 1 root root  55 Nov  4 15:31 123.repo
-rw-r--r-- 1 root root 358 Nov  4 15:31 redhat.repo
[root@179-sc /]#
[root@179-sc /]#
[root@179-sc /]#yum -y install gcc
Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-manager
This system is not registered with an entitlement server. You can use subscription-manager to register.
Package gcc-4.8.5-39.el7.x86_64 already installed and latest version
Nothing to do
[root@179-sc /]#
[root@179-sc /]#
[root@179-sc /]#VBoxManage --version
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
         available for the current kernel (3.10.0-1127.el7.x86_64) or it failed to
         load. Please recompile the kernel module and install it by
           sudo /sbin/vboxconfig
         You will not be able to start VMs until this problem is fixed.
6.1.32r149290
[root@179-sc /]#
[root@179-sc /]#
[root@179-sc /]#/sbin/vboxconfig
vboxdrv.sh: Stopping VirtualBox services.
vboxdrv.sh: Starting VirtualBox services.
vboxdrv.sh: Building VirtualBox kernel modules.
相关实践学习
CentOS 8迁移Anolis OS 8
Anolis OS 8在做出差异性开发同时,在生态上和依赖管理上保持跟CentOS 8.x兼容,本文为您介绍如何通过AOMS迁移工具实现CentOS 8.x到Anolis OS 8的迁移。
目录
相关文章
|
2月前
|
Ubuntu Linux Shell
(已解决)Linux环境—bash: wget: command not found; Docker pull报错Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: request canceled
(已成功解决)Linux环境报错—bash: wget: command not found;常见Linux发行版本,Linux中yum、rpm、apt-get、wget的区别;Docker pull报错Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: request canceled
460 68
(已解决)Linux环境—bash: wget: command not found; Docker pull报错Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: request canceled
|
4月前
|
安全 Linux 网络安全
Linux环境中安装和使用Paramiko
Linux环境中安装和使用Paramiko
231 12
|
4月前
|
Java 关系型数据库 MySQL
Linux环境
Linux环境
52 5
|
2月前
|
消息中间件 Java Kafka
【手把手教你Linux环境下快速搭建Kafka集群】内含脚本分发教程,实现一键部署多个Kafka节点
本文介绍了Kafka集群的搭建过程,涵盖从虚拟机安装到集群测试的详细步骤。首先规划了集群架构,包括三台Kafka Broker节点,并说明了分布式环境下的服务进程配置。接着,通过VMware导入模板机并克隆出三台虚拟机(kafka-broker1、kafka-broker2、kafka-broker3),分别设置IP地址和主机名。随后,依次安装JDK、ZooKeeper和Kafka,并配置相应的环境变量与启动脚本,确保各组件能正常运行。最后,通过编写启停脚本简化集群的操作流程,并对集群进行测试,验证其功能完整性。整个过程强调了自动化脚本的应用,提高了部署效率。
【手把手教你Linux环境下快速搭建Kafka集群】内含脚本分发教程,实现一键部署多个Kafka节点
|
3月前
|
Linux UED iOS开发
|
4月前
|
Web App开发 搜索推荐 Unix
Linux系统之MobaXterm远程连接centos的GNOME桌面环境
【10月更文挑战第21天】Linux系统之MobaXterm远程连接centos的GNOME桌面环境
860 4
Linux系统之MobaXterm远程连接centos的GNOME桌面环境
|
3月前
|
缓存 Ubuntu Linux
Linux环境下测试服务器的DDR5内存性能
通过使用 `memtester`和 `sysbench`等工具,可以有效地测试Linux环境下服务器的DDR5内存性能。这些工具不仅可以评估内存的读写速度,还可以检测内存中的潜在问题,帮助确保系统的稳定性和性能。通过合理配置和使用这些工具,系统管理员可以深入了解服务器内存的性能状况,为系统优化提供数据支持。
105 4
|
3月前
|
关系型数据库 MySQL Linux
Linux环境下MySQL数据库自动定时备份实践
数据库备份是确保数据安全的重要措施。在Linux环境下,实现MySQL数据库的自动定时备份可以通过多种方式完成。本文将介绍如何使用`cron`定时任务和`mysqldump`工具来实现MySQL数据库的每日自动备份。
247 3
|
3月前
|
监控 关系型数据库 MySQL
Linux环境下MySQL数据库自动定时备份策略
在Linux环境下,MySQL数据库的自动定时备份是确保数据安全和可靠性的重要措施。通过设置定时任务,我们可以每天自动执行数据库备份,从而减少人为错误和提高数据恢复的效率。本文将详细介绍如何在Linux下实现MySQL数据库的自动定时备份。
128 3
|
4月前
|
存储 Oracle 关系型数据库