Bug#861325: gearman-job-server "Too many open files" logging

2017-04-27 Thread Alexei Pastuchov
Package: gearman-job-server
Version: 1.0.6-5

If gearmand logs on EMFILE error.
(http://man7.org/linux/man-pages/man2/accept.2.html)
In such situation the log file grows rapidly.

I hope we'll solve the issue in next release.
In attachment is a patch for aforementioned version used Debian stable.

See also:
https://github.com/gearman/gearmand/issues/102

Regards,
Alexei
From 11798da5382f6d9cdfb3f79b8d1404ba46b8f27b Mon Sep 17 00:00:00 2001
From: Alexei Pastuchov <alexei.pastuc...@telecolumbus.de>
Date: Wed, 26 Apr 2017 11:54:00 +0200
Subject: [PATCH] Fix: no logging on accept EMFILE to prevend log file dumping

---
 libgearman-server/gearmand.cc |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libgearman-server/gearmand.cc b/libgearman-server/gearmand.cc
index a4601ee..1e2dae1 100644
--- a/libgearman-server/gearmand.cc
+++ b/libgearman-server/gearmand.cc
@@ -781,10 +781,10 @@ static void _listen_event(int event_fd, short events __attribute__ ((unused)), v
 switch (local_error)
 {
 case EINTR:
+case EMFILE:
   return;
 
 case ECONNABORTED:
-case EMFILE:
   gearmand_perror(local_error, "accept");
   return;
 
-- 
1.7.10.4



signature.asc
Description: OpenPGP digital signature


Bug#774143: malicious HTTP request kills gearmand

2014-12-29 Thread Alexei Pastuchov
Package: gearman-job-server
Version: 1.0.6-4
Status: install ok installed
Installed-Size: 268
Architecture: amd64
Severity: serious

A bad HTTP request force gearmand (=0.33 AFAIK) to run in in endless loop 
until memory out. See bug report 
https://bugs.launchpad.net/gearmand/+bug/1348865
Bug fixing was commited here 
http://bazaar.launchpad.net/~1-infe-w/gearmand/1.0/revision/802#libgearman-server/plugins/protocol/http/protocol.cc

Regards,
Alexei


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#774144: NO worker result HTTP-response content

2014-12-29 Thread Alexei Pastuchov
Package: gearman-job-server
Version: 1.0.6-4
Status: install ok installed
Installed-Size: 268
Architecture: amd64
Severity: important

there is a bug in HTTP plugin implementation: gearmand doesn't return
worker result to the client HTTP response as expected. See bug report
https://bugs.launchpad.net/gearmand/+bug/1152707

Here is bug fixing solution in gearman-1 
http://bazaar.launchpad.net/~1-infe-w/gearmand/1.0/revision/802#libgearman-server/plugins/protocol/http/protocol.cc

Regards,
Alexei


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#744021: gearmand doesn't start with --queue-type libmemcached

2014-04-09 Thread Alexei Pastuchov

Package: gearman-job-server
Version: 0.33-2
Status: install ok installed
Installed-Size: 268
Architecture: amd64

Hi,
gearmand will start with queue-type libmemcached only if no pending 
background jobs are in the queue. In other case it failes on start.

Loocking for any help in gearman group remained unanswered.
https://groups.google.com/forum/#!topic/gearman/tHY5V8Z8ktk

1. restart memcached and start gearmand
# /etc/init.d/memcached restart
Restarting memcached: memcached.
# /usr/sbin/gearmand --queue-type libmemcached --libmemcached-servers 
127.0.0.1:11211 --protocol=http --http-port=8080 --verbose DEBUG


2. add a background job
$ gearadmin --status
foo 1   0   0

3. kill previous gearmand process and try to start a new once
# /usr/sbin/gearmand --queue-type libmemcached --libmemcached-servers 
127.0.0.1:11211 --protocol=http --http-port=8080 --verbose DEBUG
gearmand: libgearman-server/plugins/queue/libmemcached/queue.cc:251: 
memcached_return callback_loader(const memcached_st*, 
memcached_result_st*, void*): Assertion `strlen(unique)' failed.

Aborted

# cat /var/log/gearmand.log
   INFO 2014-03-09 09:24:43.353604 [  main ] Initializing libmemcached 
module

   INFO 2014-03-09 09:24:43.353878 [  main ] Initializing HTTP
   INFO 2014-03-09 09:24:43.353978 [  main ] Starting up, verbose set 
to DEBUG
  DEBUG 2014-03-09 09:24:43.354042 [  main ] Method for libevent: epoll 
- libgearman-server/gearmand.cc:300
  DEBUG 2014-03-09 09:24:43.354067 [  main ] staring up Epoch thread - 
libgearman-server/timer.cc:58
  DEBUG 2014-03-09 09:24:43.354224 [  main ] Trying to listen on 
0.0.0.0:4730 - libgearman-server/gearmand.cc:435

   INFO 2014-03-09 09:24:43.354255 [  main ] Listening on 0.0.0.0:4730 (8)
  DEBUG 2014-03-09 09:24:43.354268 [  main ] Trying to listen on 
:::4730 - libgearman-server/gearmand.cc:435

   INFO 2014-03-09 09:24:43.354289 [  main ] Listening on :::4730 (9)
  DEBUG 2014-03-09 09:24:43.354343 [  main ] Trying to listen on 
0.0.0.0:8080 - libgearman-server/gearmand.cc:435

   INFO 2014-03-09 09:24:43.354366 [  main ] Listening on 0.0.0.0:8080 (10)
  DEBUG 2014-03-09 09:24:43.354377 [  main ] Trying to listen on 
:::8080 - libgearman-server/gearmand.cc:435

   INFO 2014-03-09 09:24:43.354395 [  main ] Listening on :::8080 (11)
  DEBUG 2014-03-09 09:24:43.354405 [  main ] Creating wakeup pipe - 
libgearman-server/gearmand.cc:732
  DEBUG 2014-03-09 09:24:43.354417 [  main ] Creating 4 threads - 
libgearman-server/gearmand.cc:314
  DEBUG 2014-03-09 09:24:43.354431 [  main ] Initializing libevent for 
IO thread - libgearman-server/gearmand_thread.cc:91
  DEBUG 2014-03-09 09:24:43.354456 [  main ] Creating IO thread wakeup 
pipe - libgearman-server/gearmand_thread.cc:291
  DEBUG 2014-03-09 09:24:43.354507 [  main ] Thread 1 created - 
libgearman-server/gearmand_thread.cc:143
  DEBUG 2014-03-09 09:24:43.354551 [  main ] Initializing libevent for 
IO thread - libgearman-server/gearmand_thread.cc:91
  DEBUG 2014-03-09 09:24:43.354579 [  main ] Creating IO thread wakeup 
pipe - libgearman-server/gearmand_thread.cc:291
  DEBUG 2014-03-09 09:24:43.354585 [ 1 ] Entering thread event loop 
- libgearman-server/gearmand_thread.cc:261
  DEBUG 2014-03-09 09:24:43.354625 [  main ] Thread 2 created - 
libgearman-server/gearmand_thread.cc:143
  DEBUG 2014-03-09 09:24:43.354638 [  main ] Initializing libevent for 
IO thread - libgearman-server/gearmand_thread.cc:91
  DEBUG 2014-03-09 09:24:43.354661 [  main ] Creating IO thread wakeup 
pipe - libgearman-server/gearmand_thread.cc:291
  DEBUG 2014-03-09 09:24:43.354681 [ 2 ] Entering thread event loop 
- libgearman-server/gearmand_thread.cc:261
  DEBUG 2014-03-09 09:24:43.354733 [  main ] Thread 3 created - 
libgearman-server/gearmand_thread.cc:143
  DEBUG 2014-03-09 09:24:43.354747 [  main ] Initializing libevent for 
IO thread - libgearman-server/gearmand_thread.cc:91
  DEBUG 2014-03-09 09:24:43.354751 [ 3 ] Entering thread event loop 
- libgearman-server/gearmand_thread.cc:261
  DEBUG 2014-03-09 09:24:43.354770 [  main ] Creating IO thread wakeup 
pipe - libgearman-server/gearmand_thread.cc:291
  DEBUG 2014-03-09 09:24:43.354816 [  main ] Thread 4 created - 
libgearman-server/gearmand_thread.cc:143

   INFO 2014-03-09 09:24:43.354828 [  main ] libmemcached replay start
  DEBUG 2014-03-09 09:24:43.354897 [ 4 ] Entering thread event loop 
- libgearman-server/gearmand_thread.cc:261


Regards,
Alexei


--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#744022: gearman-job-server logrotate doesn't work

2014-04-09 Thread Alexei Pastuchov

Package: gearman-job-server
Version: 0.33-2
Status: install ok installed
Installed-Size: 268
Architecture: amd64

Hi,

as described here https://bugs.launchpad.net/gearmand/+bug/1223994
gearmand doesn't support current gearman-job-server logrotate entry

copytruncate added in /etc/logrotate.d/gearman-job-server was a 
workaround in my case too.


Regards,
Alexei


--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org