Forum

500 internal server error in grav cms

j3lc
6 November 2017, 23:06
Hello,

I get 500 internal server error when deleting pages in Grav cms admin panel. Also I get it when I login in the admin panel for the first time.
A simple reload solves the problem but I would like to know what causes the error.

The UrlToolkit I use is
UrlToolkit {
ToolkitID = grav

Match base64_encode[^(]*\([^)]*\) DenyAccess
Match (<|%3C)([^s]*s)+cript.*(>|%3E) DenyAccess
Match GLOBALS(=|\[|\%[0-9A-Z]{0,2}) DenyAccess
Match _REQUEST(=|\[|\%[0-9A-Z]{0,2}) DenyAccess

Match ^/(.git|cache|bin|logs|backup|webserver-configs)/(.*) DenyAccess
Match ^/(system|vendor)/(.*)\.(txt|xml|md|html|yaml|php|pl|py|cgi|twig|sh|bat$
Match ^/(user)/(.*)\.(txt|md|yaml|php|pl|py|cgi|twig|sh|bat)$ DenyAccess
Match \.md$ DenyAccess
Match ^/(LICENSE.txt|composer.lock|composer.json|\.htaccess)$ DenyAccess

RequestURI exists Return
Match ^([^?]*)(\?(.*))? Rewrite /index.php?_url=$1&$3
}

In this Grav wiki https://learn.getgrav.org/troubleshooting/internal-server-error#rewritebase-problems they give some troubleshooting suggestions. On of them is to comment out Options -Indexes in .htaccess. How do we do it in hiawatha?
The second suggestion is changing
# RewriteBase 
to
RewriteBase 
. Again how do we do it in hiawatha?

Any other suggestions I should look into?
Hugo Leisink
7 November 2017, 20:57
What does the error logfile say about the 500 error?
j3lc
8 November 2017, 18:52
In the virtual host error log I see this
192.168.1.155|Wed 08 Nov 2017 17:47:58 +0000|/srv/http/webS/grav/index.php|CGI application timeout

Hugo Leisink
8 November 2017, 19:37
What if you increase the runtime for CGI (default is 5 seconds) to, for example, 15 seconds? Use the TimeForCGI option for that.
j3lc
8 November 2017, 20:12
Seems to work thank you.
This topic has been closed.