Rocksolid Light

Welcome to Rocksolid Light

register   nodelist   faq  

rocksolid / rocksolid.shared.linux / nginx with tor/i2p addresses

o nginx with tor/i2p addressesRetro Guy

Subject: nginx with tor/i2p addresses
From: Retro Guy@rslight.i2p (Retro Guy)
Newsgroups: rocksolid.shared.linux
Organization: Rocksolid Light
Date: Thu, 26 Dec 2019 02:28 UTC
Dropping this here if anyone might run into this.

I've moved two of my servers from running apache to nginx. So far so good, easy to configure and is working well, but I did run into an issue and here's the solution.

Once I had everything configured, I tried to run and got this error: nginx: [emerg] could not build the server_names_hash, you should increase server_names_hash_bucket_size

The simple solution is to modify nginx.conf adding the following in http:
server_names_hash_bucket_size 128:

The suggested value of 64 may work (it didn't for me), but I have quite a few long names, so I had to use 128. This seems fine.

Also, nginx timeout waiting for php-fpm seems very short, and I was receiving a lot of 502 Bad Gateway errors. The following (also in nginx.conf:http) seem to resolve this issue (also increases buffer size):

## fastcgi
    fastcgi_max_temp_file_size 0;
    fastcgi_buffers 128 2048k;
    fastcgi_buffer_size 2048k;

    fastcgi_read_timeout 600;
    fastcgi_send_timeout 600;

    proxy_buffering on;
    proxy_buffer_size 128k;
    proxy_buffers 4 256k;
    proxy_busy_buffers_size 256k;

I'm sure cleaning up my code wouldn't hurt, but for now this is working well.

Retro Guy

Posted on Rocksolid Light

rocksolid light 0.6.5e
clearnet i2p tor