Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi All,
I am new to LQ and this is my first question.
I am running a build script on my Ubuntu 11.10 system that tries to write into /usr/local/bin, but permission is denied to it. I understand that I can simply run the script as sudo to get around it, but the build must be done as a normal user. I am afraid I cannot post the script here, but I'd appreciate if you could point me in the right direction.
Actually, the build will create a ramdisk and the script is supposed to write into /usr/local/bin of the ramdisk. But for some environment issue it tries to write into the system's path instead. I am not sure what is happening here.
Any suggestions/pointers are much appreciated. I'd be happy to provide as much additional info as I can without actually posting the build scripts (this is a problem I have at work, so...).
If you want a non-root program to write in /usr/local/bin, you need to give permission, probably temporarily. Ways to do that include adding the user to a special group and giving that group permission, or adding the user to the disk group (or whatever has the permission), or making the user be the temporary owner of /usr/local/bin, or changing the permissions to allow any user to write there. Then remember to change things back, otherwise. Apparmor may be another way to approach this.
Thanks for the quick reply, Skaperen!
I was thinking more on the lines of some environment variable telling the script that the root path is to a different directory... Is that a possibility? I ask because it appears to be an environment issue: works for some colleagues and does not for some others, and we have not been able to figure out any difference in the environment setup yet.
Any ideas in that direction?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.