Long time useless Gearman, the server Gearman server does not know when to be stopped, so when the execution of the program, error:
File "python/response.py", line $, in <module> File "python/response.py", line-up, in main gm_worker.set_ client_id (' your_worker_client_id_name ') File "/usr/lib64/python2.7/site-packages/gearman-2.0.2-py2.7.egg/ gearman/worker.py ", line 98, in work continue_working = self.poll_connections_until_stopped (Worker_connections, Continue_while_connections_alive, Timeout=poll_timeout) File "/usr/lib64/python2.7/site-packages/ gearman-2.0.2-py2.7.egg/gearman/connection_manager.py ", line 204, in poll_connections_until_stopped raise Serverunavailable (' Found no valid connections in list:%r '% self.connection_list) gearman.errors.ServerUnavailable: Found no valid connections in list: [<gearmanconnection localhost:4730 Connected=false>]
From the last line of error log serverunavailable, it can be seen that the Gearman server has been stopped.
1. When I execute gearmand-d command, first prompt/var/log/gearman/gearman.log does not exist, so first create a log file under this path;
2. Start the server on this computer, the port is 4730, the command is:
Gearmand--log-file gearmand.log--listen 127.0.0.1--port=4730--verbose=info &
Reference: http://tech-lightnight.blogspot.jp/2013/04/start-with-gearman.html
Linux Boot Gearman Service