AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / ubuntu / 问题 / 1521832
Accepted
Blue Grass
Blue Grass
Asked: 2024-07-28 06:39:50 +0800 CST2024-07-28 06:39:50 +0800 CST 2024-07-28 06:39:50 +0800 CST

Vagrant 安装过程卡在 VirtualBox Guest Additions 上

  • 772

我的 vanilla Vagrant Ubuntu 24.04 安装在 VirtualBox Guest Additions 的同一位置卡住了。我尝试了多次,但每次都停在相同的步骤和以下消息:

XXXXXXX@XXXXXX-PC MINGW64 /d/vagrant/projects/project6

$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'apavy/ubuntu-24.04-desktop-amd64'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'apavy/ubuntu-24.04-desktop-amd64' version '0.1.0' is up to date...
==> default: Setting the name of the VM: project6_default_1722119127024_28694
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default:
    default: Vagrant insecure key detected. Vagrant will automatically replace
    default: this with a newly generated keypair for better security.
    default:
    default: Inserting generated public key within guest...
    default: Removing insecure key from the guest if it's present...
    default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims:   6.0.0
VBoxService inside the vm claims: 7.0.14
Going on, assuming VBoxService is correct...
[default] GuestAdditions versions on your host (7.0.20) and guest (7.0.14) do not match.
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims:   6.0.0
VBoxService inside the vm claims: 7.0.14
Going on, assuming VBoxService is correct...
Reading package lists...
Building dependency tree...
Reading state information...
linux-headers-6.8.0-31-generic is already the newest version (6.8.0-31.31).
build-essential is already the newest version (12.10ubuntu1).
dkms is already the newest version (3.0.11-1ubuntu13).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Copy iso file C:\Program Files\Oracle\VirtualBox\VBoxGuestAdditions.iso into the box /tmp/VBoxGuestAdditions.iso
Mounting Virtualbox Guest Additions ISO to: /mnt
mount: /mnt: WARNING: source write-protected, mounted read-only.
Installing Virtualbox Guest Additions 7.0.20 - guest version is 7.0.14
Verifying archive integrity...  100%   MD5 checksums are OK. All good.
Uncompressing VirtualBox 7.0.20 Guest Additions for Linux  100%
VirtualBox Guest Additions installer
Removing installed version 7.0.14 of VirtualBox Guest Additions...
Copying additional installer modules ...
Installing additional modules ...
VirtualBox Guest Additions: Starting.
VirtualBox Guest Additions: Setting up modules
VirtualBox Guest Additions: Building the VirtualBox Guest Additions kernel
modules.  This may take a while.
VirtualBox Guest Additions: To build modules for other installed kernels, run
VirtualBox Guest Additions:   /sbin/rcvboxadd quicksetup <version>
VirtualBox Guest Additions: or
VirtualBox Guest Additions:   /sbin/rcvboxadd quicksetup all
VirtualBox Guest Additions: Building the modules for kernel 6.8.0-31-generic.
update-initramfs: Generating /boot/initrd.img-6.8.0-31-generic
VirtualBox Guest Additions: Running kernel modules will not be replaced until
the system is restarted or 'rcvboxadd reload' triggered
VirtualBox Guest Additions: reloading kernel modules and services
VirtualBox Guest Additions: kernel modules and services 7.0.20 r163906 reloaded
VirtualBox Guest Additions: NOTE: you may still consider to re-login if some
user session specific services (Shared Clipboard, Drag and Drop, Seamless or
Guest Screen Resize) were not restarted automatically

这Vagrantfile:

Vagrant.configure("2") do |config|
  # Machine Image
  config.vm.box = "apavy/ubuntu-24.04-desktop-amd64"

  # Provisioning
  config.vm.provision :shell, path: "provision.sh"
end
virtualbox
  • 1 1 个回答
  • 120 Views

1 个回答

  • Voted
  1. Best Answer
    jadephantom
    2024-08-07T23:44:06+08:002024-08-07T23:44:06+08:00

    根据 vagrant 的输出,我猜测你已经安装了vagrant-vbguest插件,因为我也一直在使用它并且遇到了同样的问题。

    您可以通过输入来检查它是否已安装vagrant plugin list。如果输出显示类似的内容vagrant-vbguest (0.32.0, global),则表示插件已安装。

    我通过告诉 vagrant-vbguest 插件它不应该自动安装客户机附加组件来解决这个问题。为此,请打开您的 Vagrantfile,然后Vagrant.configure("2") do |config|输入以下代码:

      if Vagrant.has_plugin? "vagrant-vbguest"
        config.vbguest.no_install  = true
      end
    

    使用此代码会报告 GuestAdditions 的不同版本,但不会触发自动安装。虚拟机启动后,请手动安装 GuestAdditions。

    我猜这是 vagrant-vbguest 插件的一个错误。但是,正如您在插件 github 页面上看到的,该插件的开发已经停止:

    请注意,自 2023-12-17 起,该项目已归档,我不会再提供任何更新或支持。但是,现有代码库仍可在项目的开源许可下供参考和使用。

    〜https://github.com/dotless-de/vagrant-vbguest

    所以也许最好是完全停止使用它。

    • 0

相关问题

  • VirtualBox 中的屏幕分辨率更高?

  • 虚拟 Ubuntu 网络配置

  • vmware/virtualbox 3d 加速

  • 如何将主机 Ubuntu 上的 VPN (tun0) 网络适配器映射到 VirtualBox 来宾 Windows?

  • 如何在 Ubuntu 中运行 Windows XP

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve