[SOLVED] Cannot install Guest Additions on Debian

Discussions about using Linux guests in VirtualBox.
Post Reply
Igor Semenov
Posts: 4
Joined: 28. Nov 2013, 17:36

[SOLVED] Cannot install Guest Additions on Debian

Post by Igor Semenov »

Host OS: Windows 7 Professional
Guest OS: Debian 3.2.51-1 x86_64
VirtualBox: 4.3.2 r90405

Mounting of Guest Additions virtual CD is successful, but setup is not starting: "Cannot find autorun program".
When I try to run it from command prompt, I receive "Permission denied".

Code: Select all

root@debian-dev:/media/cdrom# whoami
root

root@debian-dev:/media/cdrom# ls -la
total 56555
dr-xr-xr-x 6 root root     2048 Nov  1 18:34 .
drwxr-xr-x 4 root root     4096 Jun 13 19:28 ..
dr-xr-xr-x 2 root root     2048 Nov  1 18:34 32Bit
dr-xr-xr-x 2 root root     2048 Nov  1 18:34 64Bit
-r-xr-xr-x 1 root root      647 Oct  8 19:30 AUTORUN.INF
-r-xr-xr-x 1 root root     6966 Nov  1 18:25 autorun.sh
dr-xr-xr-x 2 root root     2048 Nov  1 18:34 cert
dr-xr-xr-x 2 root root     2048 Nov  1 18:34 OS2
-r-xr-xr-x 1 root root     5523 Nov  1 18:25 runasroot.sh
-r-xr-xr-x 1 root root  9655755 Nov  1 18:29 VBoxLinuxAdditions.run
-r-xr-xr-x 1 root root 20722176 Nov  1 19:28 VBoxSolarisAdditions.pkg
-r-xr-xr-x 1 root root 16797560 Nov  1 18:23 VBoxWindowsAdditions-amd64.exe
-r-xr-xr-x 1 root root   311568 Nov  1 18:15 VBoxWindowsAdditions.exe
-r-xr-xr-x 1 root root 10396488 Nov  1 18:16 VBoxWindowsAdditions-x86.exe

root@debian-dev:/media/cdrom# ./autorun.sh
bash: ./autorun.sh: Permission denied
Igor Semenov
Posts: 4
Joined: 28. Nov 2013, 17:36

Re: [SOLVED] Cannot install Guest Additions on Debian

Post by Igor Semenov »

Fixed by dismounting/mounting Additions virtual CD several times...
DogsGoWoof
Posts: 1
Joined: 15. Jan 2014, 23:37

Re: [SOLVED] Cannot install Guest Additions on Debian

Post by DogsGoWoof »

I had the same problem recently and found a solution on the Unix & Linux pages of Stack Exchange, in a thread entitled "Can't execute a file with execute permission bit set".

Here is their explanation of the problem and how to fix it:

...the filesystem is mounted with the noexec option, so the execute permission bits on all files are ignored, and you cannot directly execute any program residing on this filesystem. Note that the noexec mount option is implied by the user option in /etc/fstab. ... If you use user and want to have executable files, use user,exec.

In my own case I modified one line, as follows:
Original line:

Code: Select all

/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0
Modified line:

Code: Select all

/dev/sr0        /media/cdrom0   udf,iso9660 user,exec     0       0
This did the trick.

--DGW
socratis
Site Moderator
Posts: 27330
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: [SOLVED] Cannot install Guest Additions on Debian

Post by socratis »

This should end up in the FAQ and/or the manual. Great info!
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
noteirak
Site Moderator
Posts: 5229
Joined: 13. Jan 2012, 11:14
Primary OS: Debian other
VBox Version: OSE Debian
Guest OSses: Debian, Win 2k8, Win 7
Contact:

Re: [SOLVED] Cannot install Guest Additions on Debian

Post by noteirak »

You can also make it work by calling a shell interpreter before - no need to mess with files:

Code: Select all

sh VBoxLinuxAdditions.run
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
Post Reply