Vagrant报错,好像没有加载上Homestead的设置
另:在我的编辑器界面,报错都是红的,很显眼。但是我粘贴代码来论坛的时候,报错都是白色字了,请问贴代码的时候有什么小技巧吗,比较显眼的错误可能方便大家帮助我更快定位问题,谢谢。
Vagrant的问题感觉是一整套,启动也有问题,加载设置也有问题,具体如下:
1、vagrant up的时候,提示VirtualBox和VBoxService的版本号不一致。然后出了一个mount VirtualBox shared folder的错误。如下(不知道怎么设置颜色,我把其中的一些省略掉了):
➜ Homestead git:(master) ✗ vagrant reload
==> homestead: Attempting graceful shutdown of VM...
==> homestead: Checking if box 'laravel/homestead' version '12.2.0' is up to date...
.
.
.
==> homestead: Machine booted and ready!
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims: 6.1.34
VBoxService inside the vm claims: 6.1.36
Going on, assuming VBoxService is correct...
[homestead] GuestAdditions seems to be installed (6.1.36) correctly, but not running.
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims: 6.1.34
VBoxService inside the vm claims: 6.1.36
Going on, assuming VBoxService is correct...
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims: 6.1.34
VBoxService inside the vm claims: 6.1.36
Going on, assuming VBoxService is correct...
.
.
.
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims: 6.1.34
VBoxService inside the vm claims: 6.1.36
Going on, assuming VBoxService is correct...
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims: 6.1.34
VBoxService inside the vm claims: 6.1.36
Going on, assuming VBoxService is correct...
Restarting VM to apply changes...
.
.
.
Vagrant was unable to mount VirtualBox shared folders. This is usually
because the filesystem "vboxsf" is not available. This filesystem is
made available via the VirtualBox Guest Additions and kernel module.
Please verify that these guest additions are properly installed in the
guest. This is not a bug in Vagrant and is usually caused by a faulty
Vagrant box. For context, the command attempted was:
mount -t vboxsf -o uid=,gid=,_netdev vagrant /vagrant
The error output from the command was:
2、感觉vagrant虽然设置可能没有加载上,但是应该是起来了,所以我执行了vagrant ssh,可以正常登进去,但是出来了一个奇怪的提示,感觉是和之前的heroku有点啥关系似的
➜ Homestead git:(master) ✗ vagrant ssh
Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-124-generic x86_64)
* Homestead v13.2.1 | Thanks for using Homestead
* Settler v12.2.0
Last login: Mon Oct 3 01:16:44 2022 from 10.0.2.2
› Warning: shellenv is not a heroku command.
Did you mean scale? [y/n]: › Error: Run heroku help for a list of available commands.
vagrant@homestead:~$
3、现在浏览器输入larabbs.test,会进入homestead.test的首页,我猜是homestead.yaml的设置没有被加载上
sites:
- map: homestead.test
to: /home/vagrant/Code/Laravel/public
- map: weibo.test
to: /home/vagrant/Code/weibo/public
- map: larabbs.test
to: /home/vagrant/Code/larabbs/public
databases:
- homestead
- weibo
- larabbs
4、尝试重新加载,直接报错
➜ Homestead git:(master) ✗ vagrant provision && vagrant reload
==> homestead: Running provisioner: file...
Vagrant failed to determine the shell expansion of a guest path
(probably for one of your shared folders). This is an extremely rare
error case and most likely indicates an unusual configuration of the
guest system. Please report a bug with your Vagrantfile and debug log.
➜ Homestead git:(master) ✗
求指点
本作品采用《CC 协议》,转载必须注明作者和本文链接
推荐文章: