rasmusbergpalm / jslate

Write your dashboards in pure html/js
jslate.com
244 stars 54 forks source link

Error Log Killer #7

Closed pjobson closed 11 years ago

pjobson commented 12 years ago

I left the browser open last night and came in this morning to find my drive was full. It turns out my apache error_log was 595GB.

It was mainly full of these errors repeated thousands of times.

[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  fread() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 5, referer: http://localhost/jslate/dbviews/add/1
[Wed Jul 18 09:49:10 2012] [error] [client 127.0.0.1] PHP Warning:  feof() expects parameter 1 to be resource, boolean given in /opt/local/apache2/htdocs/proxy.php on line 4, referer: http://localhost/jslate/dbviews/add/1

Perhaps if it can't find the proxy or the proxy is misconfigured it should only ask a certain number of times, rather than multiple times per second.

rasmusbergpalm commented 12 years ago

Holy cow. That's a lot of errors. If you can come up with a nice solution I'd love to accept a pull request. Cheers