2

I followed this tutorial in installing Bugzilla, I didn't encounter any problem not until I hit localhost/bugzilla in the URL. My sites-available/default config is as follows:

    #ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    Alias /bugzilla/ /var/www/bugzilla/
    <Directory /var/www/bugzilla>
            AddHandler cgi-script .cgi .pl
            Options +Indexes +ExecCGI +FollowSymLinks
            DirectoryIndex index.cgi
            AllowOverride Limit
    </Directory>
    #<Directory "/usr/lib/cgi-bin">
    #       AllowOverride All
    #       Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
    #       Order allow,deny
    #       Allow from all
    #</Directory>

And when tailing at var/log/apache2/error.log

(13)Permission denied: exec of '/var/www/bugzilla/index.cgi' failed

From comments ...

ls -l -rwxr-x--- 1 root apache2 2.6K Feb 20 01:16 /var/www/bugzilla/index.cgi 

2 Answers2

1

If you do a

ls -l /var/www/bugzilla/index.cgi

and it shows

ls -l -rwxr-x--- 1 root apache2 2.6K Feb 20 01:16 /var/www/bugzilla/index.cgi 

you will see that the user of the file (root) is not the apache user. Change it to the user you use for Apache. Let's assume this is www-data then ...

sudo chown www-data /var/www/bugzilla/index.cgi

will change this file (and only this file) to user www-data. This will set all files in /var/www/bugzilla/ to user www-data:

sudo chown -R www-data /var/www/bugzilla/

Be careful with that one though: it might change more than you want.

Rinzwind
  • 309,379
0

Make sure you have $webservergroup, and $use_suexec set correctly for your setup in Bugzilla's localconfig file, then run checksetup.pl and it will take care of fixing all of your permissions. If you have root access on the box (which it looks like you do since you can mess with the apache config) then $use_suexec should be 0 and $webservergroup should be "www-data". Make sure you are root when you run checksetup.pl.