I apologize if this has been asked, I couldn't find it. I'm running Ubuntu 12.04, and I have a VirtualBox VM that starts headless when the machine boots up. For some reason, when it first tries to run, VirtualBox complains that it's can't find the virtual disk (which is on another drive) - once I open the directory manually, I can run the VM and everything is fine.

Why doesn't Ubuntu see the other drive at first? Has anyone encountered this?

  • Is the additional partition mounted by the time Virtual Box tries to open it? – Takkat Aug 20 '12 at 7:52
  • Actually, no. I just figured that out. There is nothing to automatically mount it, but it lists in nautalis, and will mount when I click on it. I guess I need to update the startup scripts to mount that drive. – aserwin Aug 20 '12 at 21:10
  • If its an NTFS partition look here: askubuntu.com/questions/46588/how-to-automount-ntfs-partitions else you may want to edit fstab to either automount or allow non-root users to mount the drive prior to starting Virtual Box. – Takkat Aug 20 '12 at 22:00
  • I've tried a line in fstab, and it creates an error at startup. I have to ignore mounting to get Ubuntu to start up. I went to the startup console to check it out, and /dev/sda1 (the NTFS drive in question) is not there... for some reason that drive doesn't exist until about the time Ubuntu is fully booted. Pretty strange. – aserwin Aug 21 '12 at 21:21

The answer was to find the UUID of the drive using blkid and inserting a line in fstab...

UUID=<id of drive> /media/ntfs ntfs 0 1

I usually backup things on another drive, for that it needs that drive to be mounted at boot. You can try the fstab method described above, or you can run a cron job at reboots.

sudo su
crontab -e
@reboot mount /dev/sda2 /mnt

where /dev/sda2 is the drive and /mnt is the mount point

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.