Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 16
My apache2 doesn't work correctly. If I browse localhost (127.0.0.1), I don't get anything, although I have index file in correct folder (/var/www). If I do as root Code: apache2ctl ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jul 2012
    Posts
    10

    Problem with apache (apache2)


    My apache2 doesn't work correctly. If I browse localhost (127.0.0.1), I don't get anything, although I have index file in correct folder (/var/www). If I do as root
    Code:
    apache2ctl start
    I have output:
    Code:
    Syntax error on line 17 of /etc/apache2/conf.d/mumble-django:
    <FilesMatch> cannot occur within <Location> section
    Action 'start' failed.
    The Apache error log may have more information.
    What should I do, so apache would be working correctly?

    Sorry if I wrote something strangely, I'm not English

  2. #2
    Linux Guru
    Join Date
    Oct 2007
    Location
    Tucson AZ
    Posts
    3,190
    You apparently have an incorrect entry for "<FilesMatch>" in the "<Location>" section. Your error message specifices that and gives you the line (17) of the file with the error. If you post the first part (20-30 lines) of the file someone should be able to point out the error.

  3. #3
    Just Joined!
    Join Date
    Jul 2012
    Posts
    10
    cat /etc/apache2/conf.d/mumble-django:

    Code:
    Alias                   /mumble-django/static/  /usr/share/mumble-django/htdocs/
    Alias                   /mumble-django/media/   /usr/share/pyshared/django/contrib/admin/media/
    
    WSGIScriptAlias         /mumble-django          /usr/share/mumble-django/mumble-django.wsgi
    WSGIDaemonProcess       mumble-django threads=25
    WSGIProcessGroup        mumble-django
    WSGIScriptReloading     Off
    
    <Location /mumble-django>
            FileETag None
            <IfModule mod_deflate.c>
                    AddOutputFilterByType DEFLATE text/html text/plain text/css text/javascript image/png image/jpeg image/gif
                    <IfModule mod_headers.c>
                            # properly handle requests coming from behind proxies
                            Header unset ETag
                            Header append Vary User-Agent
                            <FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|js|css|swf)$">
                                    Header set Cache-Control "max-age=86400, must-revalidate"
                            </FilesMatch>
                    </IfModule>
            </IfModule>
    </Location>

  4. #4
    Just Joined!
    Join Date
    Nov 2006
    Posts
    11
    listen to yancek:

    Those lines should be outside of the <Location> Section:
    <FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|js|css|swf)$" >
    Header set Cache-Control "max-age=86400, must-revalidate"
    </FilesMatch>

  5. #5
    Just Joined!
    Join Date
    Jul 2012
    Posts
    10
    O.K. I'll do that

  6. #6
    Just Joined!
    Join Date
    Jul 2012
    Posts
    10
    That problem is solved, but there's another:

    If I do apache2ctl start, it just says me:

    Code:
    Action 'start' failed.
    The Apache error log may have more information.
    In /var/log/apache2/error.log there is on last 4 lines:

    Code:
    [Thu Jul 19 16:21:02 2012] [error] Can't locate /usr/share/torrus/conf_defaults/webmux2.pl in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl . /etc/apache2) at (eval 2) line 1.\n
    [Thu Jul 19 16:21:02 2012] [error] Can't load Perl file: /usr/share/torrus/conf_defaults/webmux2.pl for server LEdoian.imt:0, exiting...
    [Thu Jul 19 16:21:09 2012] [error] Can't locate /usr/share/torrus/conf_defaults/webmux2.pl in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.10.1 /usr/local/share/perl/5.10.1 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.10 /usr/share/perl/5.10 /usr/local/lib/site_perl . /etc/apache2) at (eval 2) line 1.\n
    [Thu Jul 19 16:21:09 2012] [error] Can't load Perl file: /usr/share/torrus/conf_defaults/webmux2.pl for server LEdoian.imt:0, exiting...
    Thanks for any useful answer

  7. #7
    Linux Engineer
    Join Date
    Apr 2012
    Location
    Virginia, USA
    Posts
    880
    Apache can't locate the files that it says it can't locate. This could be because they are either not there, or apache does not have read/execute permissions (as appropriate) to those files.

    Whatever tutorial or whatever document you are following is not helping you. What are you trying to do specifically? These are not everyday apache problems.

  8. #8
    Just Joined!
    Join Date
    Jul 2012
    Posts
    10
    I don't understand you very well, but I'll try reinstalling apache

  9. #9
    Just Joined!
    Join Date
    Jul 2012
    Posts
    10
    I did the reinstalling, and apache2ctl start still giving error. It says:

    Code:
    Syntax error on line 4 of /etc/apache2/conf.d/mumble-django:
    Invalid command 'WSGIScriptAlias', perhaps misspelled or defined by a module not included in the server configuration
    Action 'start' failed.
    The Apache error log may have more information.
    I did the reinstall using tasksel: I uninstalled web server and installed it again.

  10. #10
    Linux Engineer
    Join Date
    Apr 2012
    Location
    Virginia, USA
    Posts
    880
    What release of Debian are you using, and why aren't you starting apache with the service command?

Page 1 of 2 1 2 LastLast

Posting Permissions

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