[uWSGI] Namespaced vassals and log rotation
l.mierzwa at gmail.com
Sat Apr 5 18:03:57 CEST 2014
So I shall write one ;P
2014-04-05 17:53 GMT+02:00 Roberto De Ioris <roberto at unbit.it>:
> > Hi,
> > I'm not sure if this is bug with logging or I simply failed to find the
> > right combination of options. Right now I'm pushing logs from vassals
> > using
> > remote syslog plugin (localhost syslog over tcp), it works just fine. I
> > wanted to switch to plain log files, each vassal would have rotated log
> > file inside the namespace.
> > If I use --logto I must pass full path including namespace path, example:
> > --logto=/ns/app1/home/uwsgi.log
> > so I guess that logs are opened before jailing vassal.
> > If I'll add --log-maxsize it doesn't work regardless if I set full path,
> > or
> > just path inside the namespace. I think that uWSGI tries to call
> > using full path as first arg, but we are inside the namespace so it
> > So i tried using --logto2 - it would open logfile after dropping
> > privileges, so it will happen inside my namespace. This works just fine.
> > So I've added --log-maxsize again, log is being rotated, but all writes
> > are
> > still going to rotated log, looks like it's not being reopened after
> > rotating. I've checked with lsof and it turns out that master process has
> > new file opened, but all workers keep old file opened.
> > I've tried adding --log-master, but it doesn't seem to have any effect.
> > Am I missing something with this setup?
> --logto2 seems the right approach to me, but the problem is here:
> the filename checked is the one from --logto
> it should be an easy fix, i will wait for your patch ;)
> Roberto De Ioris
> uWSGI mailing list
> uWSGI at lists.unbit.it
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the uWSGI