I'm trying to run a program in C++ compiladom in Ubuntu, but is giving permission denied. I tried chmod 755 file but does not work. How do I solve this?

  • 1
    Could you please provide more details like whether you were using it in command line or IDE... and if possible the full output/error – abhishek Jan 6 '12 at 16:12
  • Sounds like the program may be using other files as well, files for which you don't have the rights. – bioShark Jan 6 '12 at 16:58

Are you running the program as a normal user? are you able to run the program using sudo?

try doing

chmod +x programname
  • Don't just blindly use sudo. Use sudo when you need to do something as root (i.e. an administrative operation). – tumbleweed Jan 6 '12 at 17:32
  • Note that I have /dev/sda6 on /media/HD type vfat (rw,nosuid,nodev,uid=1000,gid=1000,shortname=mixed,dmask=0077,utf8=1,showexec,flush,uhelper=udisks) e a opção showexec está me impedindo de executar os binarios. – Regis da Silva Jan 7 '12 at 1:09

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.