Enable multiple users to install software using homebrew
up vote
12
down vote
favorite
I installed homebrew using my other user account (which I use during work), but it is impossible to install software from my newly created personal account:
$ brew install unrar
Error: Cannot write to /usr/local/Cellar
A ls -dl /usr/local/Cellar/
shows that the directory is owned by my other user account.
How do I configure homebrew to allow multiple users to install software?
mac user-accounts homebrew
add a comment |
up vote
12
down vote
favorite
I installed homebrew using my other user account (which I use during work), but it is impossible to install software from my newly created personal account:
$ brew install unrar
Error: Cannot write to /usr/local/Cellar
A ls -dl /usr/local/Cellar/
shows that the directory is owned by my other user account.
How do I configure homebrew to allow multiple users to install software?
mac user-accounts homebrew
You can take control from the other user by doingsudo chown -R $(whoami) /usr/local
– Nathan Lloyd
Aug 20 at 22:14
add a comment |
up vote
12
down vote
favorite
up vote
12
down vote
favorite
I installed homebrew using my other user account (which I use during work), but it is impossible to install software from my newly created personal account:
$ brew install unrar
Error: Cannot write to /usr/local/Cellar
A ls -dl /usr/local/Cellar/
shows that the directory is owned by my other user account.
How do I configure homebrew to allow multiple users to install software?
mac user-accounts homebrew
I installed homebrew using my other user account (which I use during work), but it is impossible to install software from my newly created personal account:
$ brew install unrar
Error: Cannot write to /usr/local/Cellar
A ls -dl /usr/local/Cellar/
shows that the directory is owned by my other user account.
How do I configure homebrew to allow multiple users to install software?
mac user-accounts homebrew
mac user-accounts homebrew
asked May 14 '11 at 0:59
Sridhar Ratnakumar
2,05683352
2,05683352
You can take control from the other user by doingsudo chown -R $(whoami) /usr/local
– Nathan Lloyd
Aug 20 at 22:14
add a comment |
You can take control from the other user by doingsudo chown -R $(whoami) /usr/local
– Nathan Lloyd
Aug 20 at 22:14
You can take control from the other user by doing
sudo chown -R $(whoami) /usr/local
– Nathan Lloyd
Aug 20 at 22:14
You can take control from the other user by doing
sudo chown -R $(whoami) /usr/local
– Nathan Lloyd
Aug 20 at 22:14
add a comment |
3 Answers
3
active
oldest
votes
up vote
13
down vote
set umask
for each user first. (.basrc or .profile or .bash_profile)
umask 0002 # group write permission
then give write permission for groups via /usr/local
recursively:
sudo chmod -R g+w /usr/local/
then change the owner to staff
sudo chgrp -R staff /usr/local
now, each user, who is in staff
group can use brew install
and other brew related operations... Mostly every user is in that group.
1
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped thechgrp
– Duvrai
Dec 16 '14 at 16:50
add a comment |
up vote
1
down vote
On the homebrew wiki, it mentions that you can install it anywere, try having local installations for each user.
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
add a comment |
up vote
0
down vote
accepted
Here's my workaround:
su - myother_user_account -c "brew install ..."
1
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
add a comment |
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
13
down vote
set umask
for each user first. (.basrc or .profile or .bash_profile)
umask 0002 # group write permission
then give write permission for groups via /usr/local
recursively:
sudo chmod -R g+w /usr/local/
then change the owner to staff
sudo chgrp -R staff /usr/local
now, each user, who is in staff
group can use brew install
and other brew related operations... Mostly every user is in that group.
1
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped thechgrp
– Duvrai
Dec 16 '14 at 16:50
add a comment |
up vote
13
down vote
set umask
for each user first. (.basrc or .profile or .bash_profile)
umask 0002 # group write permission
then give write permission for groups via /usr/local
recursively:
sudo chmod -R g+w /usr/local/
then change the owner to staff
sudo chgrp -R staff /usr/local
now, each user, who is in staff
group can use brew install
and other brew related operations... Mostly every user is in that group.
1
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped thechgrp
– Duvrai
Dec 16 '14 at 16:50
add a comment |
up vote
13
down vote
up vote
13
down vote
set umask
for each user first. (.basrc or .profile or .bash_profile)
umask 0002 # group write permission
then give write permission for groups via /usr/local
recursively:
sudo chmod -R g+w /usr/local/
then change the owner to staff
sudo chgrp -R staff /usr/local
now, each user, who is in staff
group can use brew install
and other brew related operations... Mostly every user is in that group.
set umask
for each user first. (.basrc or .profile or .bash_profile)
umask 0002 # group write permission
then give write permission for groups via /usr/local
recursively:
sudo chmod -R g+w /usr/local/
then change the owner to staff
sudo chgrp -R staff /usr/local
now, each user, who is in staff
group can use brew install
and other brew related operations... Mostly every user is in that group.
edited Nov 29 at 5:28
answered Jan 17 '12 at 12:05
vigo
18126
18126
1
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped thechgrp
– Duvrai
Dec 16 '14 at 16:50
add a comment |
1
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped thechgrp
– Duvrai
Dec 16 '14 at 16:50
1
1
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped the
chgrp
– Duvrai
Dec 16 '14 at 16:50
I had to do the same for /Library/Caches/Homebrew to make this actually work. And since all my users have Administrator Access enabled I skipped the
chgrp
– Duvrai
Dec 16 '14 at 16:50
add a comment |
up vote
1
down vote
On the homebrew wiki, it mentions that you can install it anywere, try having local installations for each user.
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
add a comment |
up vote
1
down vote
On the homebrew wiki, it mentions that you can install it anywere, try having local installations for each user.
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
add a comment |
up vote
1
down vote
up vote
1
down vote
On the homebrew wiki, it mentions that you can install it anywere, try having local installations for each user.
On the homebrew wiki, it mentions that you can install it anywere, try having local installations for each user.
answered Jun 18 '11 at 21:56
MatthewFord
1313
1313
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
add a comment |
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I don't want that, actually. I want the software to go to a common place irrespective of who installed it.
– Sridhar Ratnakumar
Jun 22 '11 at 3:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
I've tried this and wish I hadn't as you get messed up user permissions
– MatthewFord
Jul 12 '11 at 11:36
add a comment |
up vote
0
down vote
accepted
Here's my workaround:
su - myother_user_account -c "brew install ..."
1
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
add a comment |
up vote
0
down vote
accepted
Here's my workaround:
su - myother_user_account -c "brew install ..."
1
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
add a comment |
up vote
0
down vote
accepted
up vote
0
down vote
accepted
Here's my workaround:
su - myother_user_account -c "brew install ..."
Here's my workaround:
su - myother_user_account -c "brew install ..."
answered May 23 '11 at 4:05
Sridhar Ratnakumar
2,05683352
2,05683352
1
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
add a comment |
1
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
1
1
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
This is not a recommended solution to the multiple-users problem. It requires users to be able to have root access and/or direct access to run commands as another user which kind of defeats the purpose of having user level privileges in the first place. You can break the model for your own use case given you own the box and both accounts, but it would be ill advised for anybody else to use this and your own system usage would be safer for using proper privilege separations.
– Caleb
Sep 18 '15 at 9:46
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f283254%2fenable-multiple-users-to-install-software-using-homebrew%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
You can take control from the other user by doing
sudo chown -R $(whoami) /usr/local
– Nathan Lloyd
Aug 20 at 22:14