'GDB Permissions
I'm attempting to run gdb on an executable file within Ubuntu. However, when I attempt to run within gdb, I get the following error.
/vagrant/unit_test: cannot execute: Permission denied
During startup program exited with code 126.
I've ensured that the file ./unit_test has the proper execute permissions. I've also tried running gdb with sudo in front of it, sudo gdb ./unit_test.
It might be important to know that I'm using a Vagrantfile to boot up a virtual environment. Has anyone run into this problem before?
Solution 1:[1]
If you encounter this error while using vagrant, try to add mount_options: ["dmode=0770", "fmode=0770"] to config.vm.synced_folder method call inside your Vagrantfile, e.g.:
config.vm.synced_folder "C:\\Projects", "/projects", mount_options: ["dmode=0770", "fmode=0770"]
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | evg656e |
