Roberto De Ioris | 16 Apr 10:11 2014
Picon

Re: Varnish 4.0


> New varnish allows to create directors as loadable modules [1] [2] so I
> think it would be nice to have varnish as frontend without the need for
> HTTP router or nginx & FastRouter. But that would probably require to
> re-implement subscription logic (or split this code into
> libsubscription.so
> and link to it).
> On one hand it's nice to have one less layer, but on the other hand I
> doubt
> it would bring us much profit.
> But maybe there is some other way we could benefit from it?
>
> --
> Łukasz Mierzwa
> _______________________________________________
> uWSGI mailing list
> uWSGI <at> lists.unbit.it
> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
>

links are missing :)

--

-- 
Roberto De Ioris
http://unbit.it
_______________________________________________
uWSGI mailing list
uWSGI <at> lists.unbit.it
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
(Continue reading)

Łukasz Mierzwa | 16 Apr 10:07 2014
Picon

Varnish 4.0

New varnish allows to create directors as loadable modules [1] [2] so I think it would be nice to have varnish as frontend without the need for HTTP router or nginx & FastRouter. But that would probably require to re-implement subscription logic (or split this code into libsubscription.so and link to it).
On one hand it's nice to have one less layer, but on the other hand I doubt it would bring us much profit.
But maybe there is some other way we could benefit from it?

--
Łukasz Mierzwa
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
Richard Collins | 16 Apr 03:51 2014
Picon

Disable uWSGI exceptions catcher

On a new server, I have somehow managed to get python exceptions coming out to web browsers. It looks like I have accidentally enabled some debugging mode.

It is definately uWsgi, here is the first line I see in the browser:
uWSGI exceptions catcher for "GET /" (request plugin: "python", modifier1: 0)

How do I configure uWsgi to print the error to stderr and send a 500 error to nginx?

Richard Collins
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
Tim Tisdall | 14 Apr 17:38 2014
Picon

restarting uwsgi with HUP occasionally gives bad fd

I have an init.d script that I use to restart my uwsgi instance by sending a HUP signal to the process.  In the past I've had no issues and it usually restarts the instance in a nice way.  Recently I've occasionally gotten the following in my logs:

worker 1 buried after 2 seconds
worker 2 buried after 3 seconds
binary reloading uWSGI...
chdir() to /
closing all non-uwsgi socket fds > 2 (max_fd = 1024)...
found fd 3 mapped to socket 0 (/var/run/uwsgi/metrics_dev.sock)
running /sites/metrics_dev/env/bin/uwsgi
Bad file descriptor (epoll.cpp:144)

After that, the process is no longer running and I have to start it up as if it was shut down completely.  It's only a mild annoyance, but was wondering if there was a way to fix this.

I'm using uWSGI 2.0.3 which is using that socket to communicate with nginx.

-Tim
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
Alain Meunier | 13 Apr 17:25 2014
Picon

nginx -> uwsgi -> nginx

Hello,

I would like to implement that :

1) client query nginx server (that is ok)
2) nginx proxy_pass to uwsgi to treat the answer and do the calculation (that is ok)
3) uwsgi talks back to nginx to serve a static file to the client via a loadbalanced upstream (how ?).

Is this logic ok ? If so, i cannot find a way in the uwsgi api to talk back to nginx without losing the initial client connection.

I thought about another http connection from uwsgi to nginx once the calculation is done but I don't know how not to lose the client informations (x-real) in the meantime.


Any ideas ?

Thanks
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
james | 10 Apr 22:30 2014
Picon

Using emperor for managing celery

Hi,

I'm trying to get my head around using emperor to manage celery. Let's say I have just installed celery via PIP and for testing I am running the following code to run it manally:

export C_FORCE_ROOT="true"
cd /var/www/test
/var/www/test/venv/bin/celery worker --app=app.celery

How can I translate this into a line for my ini:

smart-attach-daemon = /tmp/celery.pid celery -A tasks worker --pidfile=/tmp/celery.pidIt seems like anything I try refuses to start it.
James
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
Gheorghe Chirica | 10 Apr 13:45 2014
Picon

Auth MongoDB collections for configuration

Hi. I'm trying to scan mongodb for collections. Without auth on mongodb all is working ok, when I add auth like: 

emperor = mongodb://user:pass-savSHZN5Fh8qMp+WYRx65w@public.gmane.org:27017,emperor.vassals,{enabled:1}

I get the following error:

Thu Apr 10 13:42:40 getaddrinfo("user:pass-savSHZN5Fh8qMp+WYRx65w@public.gmane.org") failed: Name or service not known.

How should I use the auth to mongo db? Is it supported?
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
Gilles | 7 Apr 22:09 2014
Picon

uwsgi as an authentication proxy?

Hello

Since I can't find a working web proxy for Android to filter web
pages, I'm thinking of...

1. Installing Privoxy on an ARM linux appliance,
2. Adding some front-end to authenticate incoming connections (since
Privoxy doesn't support it, and I'd rather no let anyone connect to
the appliance from the Net)
3. Configuring ProxyDroid on my Android smartphone to go through
Privoxy on the appliance.

Here's a diagram:
http://postimg.org/image/y9opoxme1/

Since uwsgi has tons of features, I was wondering if it could act as
that authentication proxy.

Thank you.
Roberto De Ioris | 5 Apr 19:53 2014
Picon

[ANNOUNCE] ganglia and riemann plugins

https://github.com/unbit/uwsgi-ganglia

https://github.com/unbit/uwsgi-riemann

both are work in progress, but should be already useful for storing uWSGI
metrics

--

-- 
Roberto De Ioris
http://unbit.it
Łukasz Mierzwa | 5 Apr 17:52 2014
Picon

Namespaced vassals and log rotation

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 rename() using full path as first arg, but we are inside the namespace so it fails.

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?

--
Łukasz Mierzwa
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
Łukasz Mierzwa | 5 Apr 16:20 2014
Picon

HTTP router vs FastRouter

Hi,

I'm evaluating http router instead of fastrouter+nginx and it seems that it's much slower.
With fastrouter + nginx I'm getting 8k-10k req/s (small static files) on my test virtual machines, but with http router I'm only getting 800-1.5k Increasing number of workers helps, but not much.
Is this something I can expect to get better? Or should I stick with nginx in front of fastrouter if I need  to handle bigger traffic?

My configs: https://gist.github.com/prymitive/a9ac9b7867c4c502984a
(ignore the https part, I was testing only http connections)

--
Łukasz Mierzwa
_______________________________________________
uWSGI mailing list
uWSGI@...
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Gmane