18

I have Ubuntu 12.04 LTS and I tried to upgrade to Ubuntu 12.10. When I clicked in the Update Manager Upgrade a messagebox apeared:

Can not run the upgrade. This usually is caused by a system where /tmp is mounted noexec. Please remount without noexec and run the upgrade again.

I tried to make /tmp executable in Terminal with the following command:

mount -o remount,exec /tmp /var/tmp

I pressed Enter and I got the following message from Terminal:

mount: only root can do that

What should I do now to make /tmp executable and upgrade the OS.

  • 2
    Welcome to Ask Ubuntu! Could you include the output of cat /proc/mounts in your question? To be sure about the configuration on your system. – gertvdijk Jun 22 '13 at 14:28
  • You need to mount it as root using the sudo command like this sudo mount -o remount,exec /tmp /var/tmp – Scott Goodgame Jun 22 '13 at 15:11
24

You must to have root privileges. For this, put sudo in front of the command:

sudo mount -o remount,exec /tmp

When you are asked about password, just insert your usual user password.

  • 4
    This command doesn't work for me. Instead I get a : "mount: /tmp not mounted or bad option" error – Dark Star1 Apr 14 '14 at 21:21
  • It does not work for me either. – Andrew Thaddeus Martin Aug 3 '16 at 17:23
2

Would you try this command? In my case, this worked.

sudo mount -t tmpfs -o exec tmpfs /tmp

and then, check if it worked.

mount
1

Privileges and permissions in linux can be confusing. I recommend reading this before you start using sudo. Once you understand the difference between root, sudo, and normal user, you'll have a much better grasp of why this error happened (and *nix in general). See also the man pages for chown and chmod.

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.