Saturday, January 12, 2019

Logging debug & error messages to file

Hi,

I'm trying to log debug & error messages to a file. But I receive this exception on the server:

ValueError: Unable to configure handler 'file': [Errno 13] Permission denied: '/var/log/speedy_net_django.log'

If I change the path to '/tmp/speedy_net_django.log' then it works.

How do I configure the server to write messages to '/var/log/speedy_net_django.log'? We use Ubuntu and nginx.

Our logging settings:

By the way, are there friendlier ways to view logging messages than with text files?

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CABD5YeGfd%3DUJseZiUP7me52A61pWfn6%3DE1JJnCwk5VZ%2BoMYRNA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment