Sudo groupadd: Command not found

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I'm trying to move my wsgi file to the /var/www/test directory to use Apache in Python.
While doing that, I found out that I could not copy the wsgi file to that directory or save the file there.
It said 'Permission Denied'.



I've researched various questions, but I couldn't solve the problem, so I'm posting this here.



Here's what I've done so far.



1. Changed .bash_profile file's path to like this.



PATH="$HOME/bin:/usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin"



reference: Addgroup: command not found



2. Confirmed that the PATH has "/usr/sbin"



~ $ echo $PATH



Output: /usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin



reference: https://superuser.com/questions/180898/groupadd-command-not-found



3. Logged in as root by 'sudo -i' and went to the /usr/sbin/ directory by cd command, but couldn't find the 'groupadd' directory.



Still, the groupadd command is not working.
The 'Command not found' message appears.



Some says it might be due to the lack of 'shadow-utils' package, but I'm not sure if it's okay to install that package for my problem.
That package seems to be related to CentOS, according to other people's reply on other questions..



However, I just don't know anything about Linux and which Linux I'm using by Mac Terminal...so I'm trying to figure it out.



One person say,




groupadd is part of the package "shadow".
Maybe that is not installed on OBS when it tries to install your
package? Try to Require it explicitely. In your case the correct thing
would be to add a line like this to your spec file




Requires(pre): /usr/sbin/groupadd


but, what does it mean by 'spec file'?



What I'm trying to do is,



sudo groupadd varwwwusers
sudo adduser www-data varwwwusers
sudo chgrp -R varwwwusers /var/www/
sudo chmod -R 760 /var/www/


reference: https://stackoverflow.com/questions/21797372/django-errno-13-permission-denied-var-www-media-animals-user-uploads



What can I do more from where I am now?
I really need help.







share|improve this question


















  • 4




    Which Linux are you using? Debian, Ubuntu, Fedora, CentOS, Red Hat, something else? You might have a Debian/Ubuntu system with addgroup. Also see groupadd: command not found on Super User.
    – jww
    Feb 18 at 7:01











  • What does man -k group | egrep 'add|create' say? I would expect addgroup to be on a system with adduser
    – Fox
    Feb 18 at 19:54






  • 1




    What jww said; are you trying to run these commands on a Linux system or on the MacOS system? If Linux, can you run ls -l /usr/sbin/groupadd to see if the binary (not directory) is there?
    – Jeff Schaller
    Feb 20 at 19:11










  • I fail to see the link between the wsgi file and groupadd.
    – Dmitry Grigoryev
    Feb 21 at 8:02














up vote
0
down vote

favorite












I'm trying to move my wsgi file to the /var/www/test directory to use Apache in Python.
While doing that, I found out that I could not copy the wsgi file to that directory or save the file there.
It said 'Permission Denied'.



I've researched various questions, but I couldn't solve the problem, so I'm posting this here.



Here's what I've done so far.



1. Changed .bash_profile file's path to like this.



PATH="$HOME/bin:/usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin"



reference: Addgroup: command not found



2. Confirmed that the PATH has "/usr/sbin"



~ $ echo $PATH



Output: /usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin



reference: https://superuser.com/questions/180898/groupadd-command-not-found



3. Logged in as root by 'sudo -i' and went to the /usr/sbin/ directory by cd command, but couldn't find the 'groupadd' directory.



Still, the groupadd command is not working.
The 'Command not found' message appears.



Some says it might be due to the lack of 'shadow-utils' package, but I'm not sure if it's okay to install that package for my problem.
That package seems to be related to CentOS, according to other people's reply on other questions..



However, I just don't know anything about Linux and which Linux I'm using by Mac Terminal...so I'm trying to figure it out.



One person say,




groupadd is part of the package "shadow".
Maybe that is not installed on OBS when it tries to install your
package? Try to Require it explicitely. In your case the correct thing
would be to add a line like this to your spec file




Requires(pre): /usr/sbin/groupadd


but, what does it mean by 'spec file'?



What I'm trying to do is,



sudo groupadd varwwwusers
sudo adduser www-data varwwwusers
sudo chgrp -R varwwwusers /var/www/
sudo chmod -R 760 /var/www/


reference: https://stackoverflow.com/questions/21797372/django-errno-13-permission-denied-var-www-media-animals-user-uploads



What can I do more from where I am now?
I really need help.







share|improve this question


















  • 4




    Which Linux are you using? Debian, Ubuntu, Fedora, CentOS, Red Hat, something else? You might have a Debian/Ubuntu system with addgroup. Also see groupadd: command not found on Super User.
    – jww
    Feb 18 at 7:01











  • What does man -k group | egrep 'add|create' say? I would expect addgroup to be on a system with adduser
    – Fox
    Feb 18 at 19:54






  • 1




    What jww said; are you trying to run these commands on a Linux system or on the MacOS system? If Linux, can you run ls -l /usr/sbin/groupadd to see if the binary (not directory) is there?
    – Jeff Schaller
    Feb 20 at 19:11










  • I fail to see the link between the wsgi file and groupadd.
    – Dmitry Grigoryev
    Feb 21 at 8:02












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I'm trying to move my wsgi file to the /var/www/test directory to use Apache in Python.
While doing that, I found out that I could not copy the wsgi file to that directory or save the file there.
It said 'Permission Denied'.



I've researched various questions, but I couldn't solve the problem, so I'm posting this here.



Here's what I've done so far.



1. Changed .bash_profile file's path to like this.



PATH="$HOME/bin:/usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin"



reference: Addgroup: command not found



2. Confirmed that the PATH has "/usr/sbin"



~ $ echo $PATH



Output: /usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin



reference: https://superuser.com/questions/180898/groupadd-command-not-found



3. Logged in as root by 'sudo -i' and went to the /usr/sbin/ directory by cd command, but couldn't find the 'groupadd' directory.



Still, the groupadd command is not working.
The 'Command not found' message appears.



Some says it might be due to the lack of 'shadow-utils' package, but I'm not sure if it's okay to install that package for my problem.
That package seems to be related to CentOS, according to other people's reply on other questions..



However, I just don't know anything about Linux and which Linux I'm using by Mac Terminal...so I'm trying to figure it out.



One person say,




groupadd is part of the package "shadow".
Maybe that is not installed on OBS when it tries to install your
package? Try to Require it explicitely. In your case the correct thing
would be to add a line like this to your spec file




Requires(pre): /usr/sbin/groupadd


but, what does it mean by 'spec file'?



What I'm trying to do is,



sudo groupadd varwwwusers
sudo adduser www-data varwwwusers
sudo chgrp -R varwwwusers /var/www/
sudo chmod -R 760 /var/www/


reference: https://stackoverflow.com/questions/21797372/django-errno-13-permission-denied-var-www-media-animals-user-uploads



What can I do more from where I am now?
I really need help.







share|improve this question














I'm trying to move my wsgi file to the /var/www/test directory to use Apache in Python.
While doing that, I found out that I could not copy the wsgi file to that directory or save the file there.
It said 'Permission Denied'.



I've researched various questions, but I couldn't solve the problem, so I'm posting this here.



Here's what I've done so far.



1. Changed .bash_profile file's path to like this.



PATH="$HOME/bin:/usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin"



reference: Addgroup: command not found



2. Confirmed that the PATH has "/usr/sbin"



~ $ echo $PATH



Output: /usr/local/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/bin:/bin



reference: https://superuser.com/questions/180898/groupadd-command-not-found



3. Logged in as root by 'sudo -i' and went to the /usr/sbin/ directory by cd command, but couldn't find the 'groupadd' directory.



Still, the groupadd command is not working.
The 'Command not found' message appears.



Some says it might be due to the lack of 'shadow-utils' package, but I'm not sure if it's okay to install that package for my problem.
That package seems to be related to CentOS, according to other people's reply on other questions..



However, I just don't know anything about Linux and which Linux I'm using by Mac Terminal...so I'm trying to figure it out.



One person say,




groupadd is part of the package "shadow".
Maybe that is not installed on OBS when it tries to install your
package? Try to Require it explicitely. In your case the correct thing
would be to add a line like this to your spec file




Requires(pre): /usr/sbin/groupadd


but, what does it mean by 'spec file'?



What I'm trying to do is,



sudo groupadd varwwwusers
sudo adduser www-data varwwwusers
sudo chgrp -R varwwwusers /var/www/
sudo chmod -R 760 /var/www/


reference: https://stackoverflow.com/questions/21797372/django-errno-13-permission-denied-var-www-media-animals-user-uploads



What can I do more from where I am now?
I really need help.









share|improve this question













share|improve this question




share|improve this question








edited Feb 18 at 8:19

























asked Feb 18 at 6:56









Orinthia Joo

11




11







  • 4




    Which Linux are you using? Debian, Ubuntu, Fedora, CentOS, Red Hat, something else? You might have a Debian/Ubuntu system with addgroup. Also see groupadd: command not found on Super User.
    – jww
    Feb 18 at 7:01











  • What does man -k group | egrep 'add|create' say? I would expect addgroup to be on a system with adduser
    – Fox
    Feb 18 at 19:54






  • 1




    What jww said; are you trying to run these commands on a Linux system or on the MacOS system? If Linux, can you run ls -l /usr/sbin/groupadd to see if the binary (not directory) is there?
    – Jeff Schaller
    Feb 20 at 19:11










  • I fail to see the link between the wsgi file and groupadd.
    – Dmitry Grigoryev
    Feb 21 at 8:02












  • 4




    Which Linux are you using? Debian, Ubuntu, Fedora, CentOS, Red Hat, something else? You might have a Debian/Ubuntu system with addgroup. Also see groupadd: command not found on Super User.
    – jww
    Feb 18 at 7:01











  • What does man -k group | egrep 'add|create' say? I would expect addgroup to be on a system with adduser
    – Fox
    Feb 18 at 19:54






  • 1




    What jww said; are you trying to run these commands on a Linux system or on the MacOS system? If Linux, can you run ls -l /usr/sbin/groupadd to see if the binary (not directory) is there?
    – Jeff Schaller
    Feb 20 at 19:11










  • I fail to see the link between the wsgi file and groupadd.
    – Dmitry Grigoryev
    Feb 21 at 8:02







4




4




Which Linux are you using? Debian, Ubuntu, Fedora, CentOS, Red Hat, something else? You might have a Debian/Ubuntu system with addgroup. Also see groupadd: command not found on Super User.
– jww
Feb 18 at 7:01





Which Linux are you using? Debian, Ubuntu, Fedora, CentOS, Red Hat, something else? You might have a Debian/Ubuntu system with addgroup. Also see groupadd: command not found on Super User.
– jww
Feb 18 at 7:01













What does man -k group | egrep 'add|create' say? I would expect addgroup to be on a system with adduser
– Fox
Feb 18 at 19:54




What does man -k group | egrep 'add|create' say? I would expect addgroup to be on a system with adduser
– Fox
Feb 18 at 19:54




1




1




What jww said; are you trying to run these commands on a Linux system or on the MacOS system? If Linux, can you run ls -l /usr/sbin/groupadd to see if the binary (not directory) is there?
– Jeff Schaller
Feb 20 at 19:11




What jww said; are you trying to run these commands on a Linux system or on the MacOS system? If Linux, can you run ls -l /usr/sbin/groupadd to see if the binary (not directory) is there?
– Jeff Schaller
Feb 20 at 19:11












I fail to see the link between the wsgi file and groupadd.
– Dmitry Grigoryev
Feb 21 at 8:02




I fail to see the link between the wsgi file and groupadd.
– Dmitry Grigoryev
Feb 21 at 8:02















active

oldest

votes











Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f424918%2fsudo-groupadd-command-not-found%23new-answer', 'question_page');

);

Post as a guest



































active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes










 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f424918%2fsudo-groupadd-command-not-found%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How to check contact read email or not when send email to Individual?

Bahrain

Postfix configuration issue with fips on centos 7; mailgun relay