ls /vagrant fails in 13.10 vagrant cloud image

Bug #1239417 reported by loci von Myrmidons
44
This bug affects 8 people
Affects Status Importance Assigned to Milestone
Ubuntu
Confirmed
Undecided
Unassigned

Bug Description

    ls /vagrant
hangs on a fresh 13.10 box.

    strace ls /vagrant
shows that it calls getdents indefinitely.

Here's my vagrantfile

    VAGRANTFILE_API_VERSION = "2"

    box = "saucy_64"
    url = "http://cloud-images.ubuntu.com/vagrant/saucy/current/saucy-server-cloudimg-amd64-vagrant-disk1.box"
    hostname = "localhost"

    Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
        config.vm.box = box
        config.vm.box_url = url
        config.vm.hostname = hostname
    end

I'm using vagrant 1.3.4, ruby 1.8.7 and virtualbox 4.2.18 on Mac OS X 10.8.5

Thanks.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ubuntu:
status: New → Confirmed
Revision history for this message
Lance Rushing (lance-rushing) wrote :

Steps to reproduce:

# Install Vagrant / Virtual Box first

$ vagrant box add saucy64 http://cloud-images.ubuntu.com/vagrant/saucy/current/saucy-server-cloudimg-amd64-vagrant-disk1.box
$ vagrant init saucy64
$ vagrant up
$ vagrant ssh
## in ssh connection...
$ ls /vagrant

Revision history for this message
Jakub Gocławski (jgoclawski) wrote :

This issue is VirtualBox (and kernel 3.11) related. Latest version of VirtualBox 4.3 fixes this error.

https://www.virtualbox.org/changeset/48529/vbox

Unfortunatelly, the newest version of VirtualBox isn't available in Ubuntu repos. You need to manually download and install it from here: https://www.virtualbox.org/wiki/Linux_Downloads .

So how to fix it for Vagrant?

Well, you need to do 2 things:

1. Update VirtualBox to newest version on your host machine (https://www.virtualbox.org/wiki/Linux_Downloads)
2. When using official Ubuntu 13.10 box for Vagrant, you need to update it's Guest Additions so it matches the host version of VirtualBox.

2a. Or you can wait till Ubuntu adds newest version of VirtualBox to it's repos, so the box will have VirtualBox 4.3 installed, so to say, "out of the box" ;)

Revision history for this message
Jakub Gocławski (jgoclawski) wrote :

I assumed Ubuntu is used as a host machine, my bad. I now reread the original post and saw that Mac OS X is used.

What I mean is that you need VirtualBox 4.3 Guest Additions on the guest Ubuntu 13.10, but official Ubuntu 13.10 box has only VirtualBox 4.2.16.
Since the Guest Additions version must match the host machine VirtualBox version, it means you need VirtualBox 4.3 on your host machine as well.

When you manage to install Guest Additions for version 4.3 on the Ubuntu 13.10 box, you can then save it for later use as described here: http://docs-v1.vagrantup.com/v1/docs/getting-started/packaging.html

Revision history for this message
lautreamont33 (lautreamont33) wrote :

I have same problem so I tested all newest vagrant-cloud-images on clean install of Ubuntu 13.10 on real (old) machine, so I could only testing i386 boxes. Precise and Raring works but Quantal and Saucy did not. Quantal did work after
$ vagrant halt -f
and
$ vagrant up
but not Saucy.

Then I tested on clean install of Ubuntu 12.04 same boxes and everything was same except that Saucy has no errors. But when I ssh in to it mounted vagrant directory was unreadable. When I replace guest additions with 4.3.0 everything works.

Tested with VB 4.3.0 and vagrant 1.3.5.

This might tell as that guest additions must be right version but they are not on Precise and Raring and they work from the box (really from .box). From debug.logs you can see that vagrant can not establish ssh connection with booted VM. On newest vagrant version there is big delay (2-3sec) on establishing ssh connection so I think that they work in that direction.

Revision history for this message
lautreamont33 (lautreamont33) wrote :

Forgot to mention, that I am also using vagrant-lxc plugin that has lxc boxes (no guest additions) and have this same error.

Revision history for this message
Lance Rushing (lance-rushing) wrote :

I've tested this further with pure virtual box (no vagrant) on windows7 Host and ubuntu 13.10 guest.

Windows7 - Virtual Box - Version 4.2.18 r88780

I've installed the VBOXADDITIONS_4.2.18_88780 guest additions.

Guest machine:
$ uname -a
Linux sandbox 3.11.0-12-generic #19-Ubuntu SMP Wed Oct 9 16:20:46 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
~$ lsmod
Module Size Used by
...
vboxsf 39525 1
vesafb 13828 1
...
vboxvideo 12658 2
vboxguest 235580 8 vboxsf
...
drm 296739 3 vboxvideo
...

Steps to reproduce.
1. Create folder on windows host. c:\code (for example)
2. Share folder in virtual box settings
3. boot virtual Ubuntu
4. check the mounts:
  $ mount | grep vboxsf
    code on /media/sf_code type vboxsf (gid=129,rw)
5. try to ls the mount
  $ sudo ls -l /media/sf_code
6. And it hangs forever.

Thanks,
Lance

Revision history for this message
Lance Rushing (lance-rushing) wrote :

After re-reading the comments, I upgraded to 4.3 and shared folders are working now.

Recap: I upgraded virtual box on the host machine to 4.3.6, and installed the 4.3.6 guest additions on the guest.

Bug is closed (for me...).

Thanks,
Lance

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.