I am trying to use the shared folders feature when running the Arch ISO as a VirtualBox guest OS. The reason is that in the shared folder I have the scripts to make my persistent setup.

After the Arch ISO bootstrap, I run:

pacman -Syu virtualbox-guest-utils

Everything seems smooth but when I load VirtualBox modules:

modprobe -a vboxguest vboxsf vboxvideo #Following guide here: vboxsf only might do

it gives an error. I know that I can fix it creating the dependency file:

depmod 3.16.1-1-ARCH 

The version is that from uname -r and I get an error again, as there is no directory:


The previous pacman -Syu ... has updated the kernel and therefore I have now a 3.16.2-1-ARCH directory. In fact:

depmod 3.16.2-1-ARCH 

works, but modprobe keeps not working.

I assume that this is due to the mismatch between the uname -r and the updated kernel. Reading around it is suggested to reboot, but in my case I will lose everything since I am running from an ISO.

I reboot an try to install the guest additions without updating, using the last Arch ISO available:

pacman -Sy virtualbox-guest-utils # now no -u

but I know that this is a bad practice! Anyway I run:

depmod 3.16.1-1-ARCH # non-updated kernel!
modprobe -a vboxguest vboxsf vboxvideo
mount.vboxsf arch /mnt
ls /mnt

and I can finally see my shared files.

This process was a kind of lucky trial and error.
Can you tell me which is the best practice to accomplish this? That is installing the VirtualBox guest additions in a volatile environment (the Arch ISO).

  • Well, you figured it out by yourself: Do not update the kernel if you cant reboot. Btw, it's not bad practice to run simply pacman -S <package>. You don't always have to update your entire system (and neither updated the database) just to install a poop.\
    – Sebastian
    Sep 15 '14 at 7:00

The best way is subjective but there are a couple of them:

  1. Make your own ISO already containing the VBox modules for the included kernel. (See [1], [2], or [3].) This might generally be the preferred option if you can and if you're going to use it a lot, but if you're only going to use it once it might be considered a bit of a waste of time.

  2. Upload the scripts to a pastebin or file host site instead, or even just run a simple HTTP server on your host, and download them inside the virtual machine. darkhttpd is one simple HTTP server that is under 100KiB big and you just execute it giving it the path to the directory to serve over HTTP, and might be the easiest and preferred for more one-off things like in your case.

  3. Or just do what you did. It works in a lot of cases, but you should do your best to avoid it because it could break. Never do this outside the installation medium.

  • Currently I am moving to FTP server on host + curlftpfs on guest. The workaround I found in my question depends on the kernel version, so sometimes it is unavoidable to restart the system. If you can give (the scratch of) a script to generate an Arch-for-VirtualBox ISO, it will be nice.
    – antonio
    Oct 6 '14 at 4:31
  • @antonio, I don't have any scripts, but I linked to three different ways to make a custom ISO, no script is really necessary, instead you probably want a custom archiso profile.
    – remmy
    Oct 6 '14 at 8:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.