I am having trouble getting some of the syslogging features to work. From the 
documentation at http://projects.unbit.it/uwsgi/wiki/Doc I found:
log-syslog
Log to syslog instead of a log-file.
Passing a parameter makes uwsgi use the parameter as program-name in the syslog 
entry header:
--log-syslog mywebapp



So I set up my environment like so (I have tried both with and without quotes):
exec $BINPATH --emperor "/var/www/*/Application/emperor.ini" --binary-path 
$BINPATH --log-syslog "MyProgram"

Also in the actual emporer.ini files to get to log to sys I am having to use 
the logto:

[uwsgi]
master = true
lazy = true
processes = 5
buffer-size = 3200
pythonpath = /var/www/ERP/Application
virtualenv = /var/www/ERP/Environment/
logto = localhost:514
log-syslog = erp   <-- this line doesn't seem to matter. If I remove it logs to 
syslog. However If I remove the logto line it won't log..
logdate = true
pidfile2 = /var/run/uwsgi/erp.pid
socket = /tmp/uwsgi-erp.sock
chmod-socket = 660
vacuum = true
uid = web
gid = web
wsgi-file = /var/www/ERP/Application/app.wsgi
stats = /tmp/stats-erp.sock

Should log-syslog work and when working can you pass it a variable as well for 
the program name?

My sample logs (my log template is $template Alta, "== %programname% -- 
%syslogtag% -- %msg:::drop-last-lf% -- \n"):
==  -- [erp.controllers.holidays] --  INFO  THIS IS A TEST --
==  -- [erp.controllers.holidays] --  INFO  THIS IS A TEST --
==  -- [pid: --  1849|app: 0|req: 1/1] 38.110.28.226 () {42 vars in 795 bytes} 
[Thu Oct 20 18:19:42 2011] GET /ERP/holidays/test => generated 0 bytes in 715 
msecs (HTTP/1.1 200) 4 headers in 121 bytes (1 switches on core 0) --
== uwsgi -- uwsgi: --  *** vassal /var/www/ERP/Application/emperor.ini is now 
loyal *** --
== uwsgi -- uwsgi: --  *** vassal /var/www/ERP/Application/emperor.ini is now 
loyal *** --

Thanks in advance,

Justin Barber
Web Developer

ALTA Language Services, Inc.
3355 Lenox Road, Suite 510
Atlanta, GA 30326

Direct:    404.920.3846
Main: 404.920.3800
Fax: 404.920.3801
Web: www.altalang.com<http://www.altalang.com>

_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to