1

So a prior question led me to this, I am trying to use Magento2, (very frustrating)

I have a VPS, with all the proper things for Magento2 to run.

I can install it but have huge permissions issues, because the part of the documentation I cannot understand is the part about Put the Magento file system owner in the web server's group

http://devdocs.magento.com/guides/v2.0/install-gde/prereq/apache-user.html#install-update-depend-user-add2group

when I do: [~]# egrep -i '^user|^group' /etc/httpd/conf/httpd.conf

I get:

User nobody 
Group nobody 
UserDir 
public_html 
UserDir 
disabled 
UserDir disabled

and I don't know how to proceed from here.

Any help would be appreciated.

UPDATE### I have now completely started over... I wiped the host account clean and created a new one, starting from scratch, trying to follow the install directions from magento. everything is good up until the point where I have to: Put the Magento file system owner in the web server's group - I'm stuck there, since my user and group are both "nobody" I don't know what to do next, is says to do this THEN install magento... so I'm just stuck here now.

  • Group nobody shows that you server run with group nobody – KAndy Jan 24 '16 at 15:52
  • try change gorup for files with command sudo chown -R :nobody * from magento root – KAndy Jan 24 '16 at 15:54
  • yes, and parent folder as well. – MagenX Jan 25 '16 at 11:40
0

This command egrep -i '^user|^group' /etc/httpd/conf/httpd.conf is to help you to grab apache user and group automatically. But you can do it also manually:

Try to open your httpd.conf (using some editor, for example vim). And find this strings:

# User/Group: The name (or #number) of the user/group to run httpd as.
# It is usually good practice to create a dedicated user and group for
# running httpd, as with most system services.
#
User www
Group www

In this particular case my Apache user is www and Apache group is www.

Also from output of your command I can see that your apache user and group is nobody so you can proceed starting from http://devdocs.magento.com/guides/v2.0/install-gde/prereq/apache-user.html#install-update-depend-user-add2group (just keep in mind that you need to use user and group nobody instead apache)

If you have any questions or need more details - just let me know. Thank you.

0

1. to install magento first you have create a new user, and look for the web server group as mentioned below.

normally webserver user can be found with root login in SSH or terminal, to understand users and groups I found these articles helpful. https://www.linode.com/docs/tools-reference/linux-users-and-groups/ and https://www.tecmint.com/manage-users-and-groups-in-linux/

egrep -i '^user|^group' /etc/httpd/conf/httpd.conf

on Centos will show user as "apache"

on Ubuntu will show user ad "www-data"

however, you can change the user name in httpd.conf file

2. now you have to put "magento_user" in webserver group as a primary group

usermod -g apache magento_user

-g for primary group -G for additional secondary group

check groups

groups magento_user

Logout of ssh/terminal and

login back

restart apache server to take effect.

hope this helps

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.