vbox挂载共享文件夹失败
平常用vbox共享文件夹,偶尔有的centos的vm会出现下面的错误
mount: unknown filesystem type ‘vboxsf’
解决方法参照
http://d.hatena.ne.jp/pospome/20140309/1394346690
http://mpweb.mobi/windows/guestadditions-centos.php
简单来说
1 [root@localhost ~]# yum install gcc
[root@localhost ~]# yum install make
[root@localhost ~]# yum install kernel-devel 一般只需要装一下这个
2 vbox的菜单选择 Device -> Insert Guest Additions CD Image
3 mount -r /dev/cdrom /mnt/cdrom/ 或者 mount -r /dev/cdrom1 /mnt/cdrom/
看一下自己设备的名字是cdrom还是cdrom1
4 sh ./VBoxLinuxAdditions.run
Verifying archive integrity... All good.
Uncompressing VirtualBox 4.3.12 Guest Additions for Linux............
VirtualBox Guest Additions installer
Removing installed version 4.3.12 of VirtualBox Guest Additions...
Copying additional installer modules ...
Installing additional modules ...
Removing existing VirtualBox non-DKMS kernel modules [ OK ]
Building the VirtualBox Guest Additions kernel modules
Building the main Guest Additions module [ OK ]
Building the shared folder support module [ OK ]
Building the OpenGL support module [失敗]
(Look at /var/log/vboxadd-install.log to find out what went wrong)
Doing non-kernel setup of the Guest Additions [ OK ]
Installing the Window System drivers
Could not find the X.Org or XFree86 Window System, skipping.
虽然有失败,但是 Building the shared folder support module就够了
5 重新执行一下mount命令就可以挂载一下自己的共享文件夹 mount -t vboxsf xxxx /opt/xxxx