On 3/19/17 8:26 PM, Chris Bennett wrote:
I have been switching over to mod_perl2 and Apache2.
I finally found some good info to fill in the blanks. Sigh.
Everything seems to be pulling into place fine, but I may still have
some stuff messed up or should I upgrade to a fresher snap?
OpenBSD 6.1-beta (GENERIC.MP) #220: Thu Mar 9 06:40:02 MST 2017
dera...@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP
real mem = 4277862400 (4079MB)
avail mem = 4143546368 (3951MB)
I can send a full dmesg if helpful.
I am running Apache2 error_log at debug.
I get this message, is it important?
[Sun Mar 19 21:04:41.049481 2017] [core:notice] [pid 45788] AH00052:
child pid 17244 exit signal Bus error (10)
But I get a 500 error on a perfectly good page. Stopping and restarting
PostgreSQL fixes problem.
[Sun Mar 19 20:53:33.137631 2017] [perl:error] [pid 4540] [client
192.168.0.8:42252] DBI
connect('dbname=benconphotos;host=127.0.0.1;port=5432','bencon',...)
failed: FATAL: sorry, too many clients already at
/usr/local/libdata/perl5/site_perl/MyPerl/PortableBuildingsGuide.pm line
59.\n, referer:
http://192.168.0.8/customer/portable_buildings/Metal_Roofing.html
This occurs randomly on any page. I am not running Firefox 52 yet.
I am the only client, so that isn't the problem.
I added
kern.seminfo.semmni=60 # PostgreSQL
kern.seminfo.semmns=1024 # PostgreSQL
Could the fact that I don't have crap for memory be the problem?
Any help appreciated!
Chris Bennett
I use this on a server with 8G ram:
# For PostgreSQL Port
kern.seminfo.semmni=512
kern.seminfo.semmns=4096
kern.shminfo.shmall=65536
kern.shminfo.shmmax=536870912
But the error suggests that you are making too many connections to
postgres. What is max_connections in postgresql.conf set to?
By default is is set at 100--I have mine set at:
jross@luna:/home/jross $ psql -d template1
Null display is "NULL".
Timing is on.
psql (9.5.3)
Type "help" for help.
jross@template1 localhost# show max_connections;
max_connections
-----------------
80
(1 row)
Time: 0.643 ms
and this is a fairly busy webserver running apache2 (no mode_perl though).
If you really are running out of connections (check the postgres logs to
make sure) I'd suggest adding a connection pooler like pgbouncer in
front of postgres rather than just blindly bumping up max_connections.
Jeff