Results 1 to 4 of 4

Thread: How to find out Apache Username?

  1. #1
    Join Date
    Oct 2006
    Location
    Old Sydney Town
    Beans
    65
    Distro
    Ubuntu 11.10 Oneiric Ocelot

    How to find out Apache Username?

    Hi all
    Is there a quick way of determining what my apache username is? Trying to chown a subfolder of /var/www/ and it doesn't like apache.apache - not sure where to find the right name.

    Thanks!
    Damien

  2. #2
    Join Date
    Jul 2005
    Location
    Finland
    Beans
    72
    Distro
    Ubuntu Development Release

    Re: How to find out Apache Username?

    the default in ubuntu is www-data


    - Tero

  3. #3
    Join Date
    Oct 2006
    Location
    Old Sydney Town
    Beans
    65
    Distro
    Ubuntu 11.10 Oneiric Ocelot

    Re: How to find out Apache Username?

    Bingo, thank you very much Tero, that's solved it.


    Damien

  4. #4
    Join Date
    Sep 2006
    Beans
    8,627
    Distro
    Ubuntu 14.04 Trusty Tahr

    /etc/apache2/envvars

    Quote Originally Posted by t3r0 View Post
    the default in ubuntu is www-data
    Yep. That is the default.

    To be sure what it is really set to, check the actual configuration files.
    The umbrella file, apache2.conf will have something like the following,

    User ${APACHE_RUN_USER}
    Group ${APACHE_RUN_GROUP}

    Thats is a reference to environment variables set in /etc/apache2/envvars
    mod_suexec also allows scripts to be run as yet a different user and group.

    To find any virtual hosts which may use alternate users, groups or both, again, check the configurations.
    Code:
    $ egrep "^User|^Group|^SuexecUserGroup" /etc/apache2/apache2.conf /etc/apache2/sites-available/*.conf

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •