WebFaction
Community site: login faq

The only errors appearing in ~/logs/frontend/error_<application>_php.log are occasional "File does not exist: robots.txt" entries. No PHP errors of any severity are showing. They display on my web pages and I have php.ini entries:

display_errors=1

log_errors=On

Adding an explicit error_log directive to php.ini pointing to the log file doesn't help. Neither does enabling log_errors in my PHP code.

After looking at docs and relevant questions, I don't know what I'm doing wrong.

asked 11 Jun '15, 14:54

bvbb
11316
accept rate: 0%

edited 11 Jun '15, 19:22


The name error_<application>_php.log is a bit misleading, I'm afraid. It's not used to log PHP errors - it's used to log errors from the back-end Apache server that serves your PHP sites.

If you want to log your PHP errors somewhere, then try specifying a path to a log file, like this:

display_errors=0
log_errors=1
error_log=/home/your_username/logs/user/yourapp_phperrors.log

Hope that helps!

permanent link

answered 11 Jun '15, 19:33

seanf
12.2k41936
accept rate: 37%

Thank you. That works. This information should be in your PHP documentation.

Interestingly and counterintuitively, pointing error_log to the existing error_<application>_php.log file in exactly the same way does not cause PHP errors to be logged there.

Any idea why my log, /home/bvb/logs/bucksvsbytesphperrors.log, doesn't do a 7 day rotation the way Webfaction-created log files do? The entries in /etc/logrotate.users.conf would seem to apply, but it's not happening.

permanent link

answered 13 Jun '15, 12:40

bvbb
11316
accept rate: 0%

It might have been a temporary issue with the log not rotating as user logs in /home/<username>/logs/user/ are rotated daily.

If it continues to happen I would suggest opening a support ticket.

(13 Jun '15, 13:07) aaront ♦♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×262
×28
×5

question asked: 11 Jun '15, 14:54

question was seen: 3,034 times

last updated: 13 Jun '15, 13:07

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM