3

I had a webserver running at luna.local, it got eaten when I upgraded to 10.10. In trying to restore it, I'm pretty stumped. I'm more stumped by this:

[0 amanda@luna ~]$ apache2 -D DUMP_VHOSTS
apache2: bad user name ${APACHE_RUN_USER}

Where is the run user supposed to be set?

in `/etc/apache2/envvars I see:

 16 export APACHE_RUN_USER=www-data
 17 export APACHE_RUN_GROUP=www-data

and ps aux | grep apache shows apache2 running as www-data:

root      1927  0.0  0.2  36216  8804 ?        Ss   07:44   0:01 /usr/sbin/apache2 -k start
www-data 14307  0.0  0.1  36216  4388 ?        S    14:10   0:00 /usr/sbin/apache2 -k start
www-data 14308  0.0  0.1  36544  5148 ?        S    14:10   0:00 /usr/sbin/apache2 -k start
www-data 14309  0.0  0.1  36216  4388 ?        S    14:10   0:00 /usr/sbin/apache2 -k start
www-data 14310  0.0  0.1  36216  4388 ?        S    14:10   0:00 /usr/sbin/apache2 -k start
www-data 14311  0.0  0.1  36216  4388 ?        S    14:10   0:00 /usr/sbin/apache2 -k start
www-data 14409  0.0  0.1  36216  4388 ?        S    14:11   0:00 /usr/sbin/apache2 -k start

So ... what gives?

Wierder: my Virtualhost definition definitely says:

  1 <VirtualHost *:80>
  2         ServerName luna.local
  3 
  4         DocumentRoot /home/amanda/Public/luna
  5         <Directory /home/amanda/Public/luna>
  6                 Options Indexes FollowSymLinks MultiViews
  7                 AllowOverride None
  8                 Order allow,deny
  9                 allow from all
 10         </Directory>

But the error log says:

[Tue Jun 07 14:25:54 2011] [crit] [client 127.0.0.1] (13)Permission denied: /home/amanda/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable
[Tue Jun 07 14:25:54 2011] [debug] mod_deflate.c(615): [client 127.0.0.1] Zlib: Compressed 278 to 215 : URL /

Why is it not looking all the way into Public/luna?

5
  • ennvars with www-data should be ok. what is the output of: sudo /etc/init.d/httpd start?
    – Pavlos G.
    Jun 7, 2011 at 18:26
  • Stopping, starting, reloading are fine. " * Starting web server apache2 [ OK ]"
    – Amanda
    Jun 7, 2011 at 18:27
  • If I set the variable manually in apache.conf, I get a more meaningful output from apache2 -D DUMP_VHOSTS, but my site still doesn't work.
    – Amanda
    Jun 7, 2011 at 18:31
  • when you run sudo apache2 -D DUMP_VHOSTS you want to run that as sudo otherwise you won't be able to switch to the right user Jun 7, 2011 at 18:36
  • @Marco Ceppi sudo makes no difference.
    – Amanda
    Jun 7, 2011 at 18:53

1 Answer 1

1

Total red herrings everywhere. I moved files from /var/www/luna to ~/Public/luna and my home directory wasn't world executable. Spotting this helped: Permissions issue: how can Apache access files in my Home directory?

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .