Failed to set Exception - Gearman 0.29

895 views
Skip to first unread message

Dr Börse

unread,
Mar 31, 2012, 5:15:07 AM3/31/12
to gea...@googlegroups.com
I installed Gearman 0.29 on my Server.

When this Error occurs:
Fatal error: Uncaught exception 'GearmanException' with message 'Failed to set e
xception option' in /var/www/cron/client.php:41                                 
Stack trace:                                                                    
#0 /var/www/cron/client.php(41): GearmanClient->runTasks()                      
#1 {main}                                                                       
  thrown in /var/www/cron/client.php on line 41

PHP .ini says:
gearman                                                                         
gearman support => enabled                                                      
libgearman version => 0.29                                                      
OLDPWD => /root/gearmand-0.29                                                   
_SERVER["OLDPWD"] => /root/gearmand-0.29

So gearmand and libgearman are on the same version level. Gearman Server is also running.

My client.php looks like.
client = new GearmanClient();
    $client->addServer();
    $client->setCreatedCallback("reverse_created");
    $client->setDataCallback("reverse_data");
    $client->setStatusCallback("reverse_status");
    $client->setCompleteCallback("reverse_complete");
    $client->setFailCallback("reverse_fail");
    $client->addTask("upper", "asd ajskdj AS  kas");
    $client->addTask("upper", "213 aSDkdfdsaj ASasdf  kaasdgs");
 
    # run the tasks in parallel (assuming multiple workers)
$client->runTasks();
echo "DONE\n";


Where is the Problem? How can I solve this?

Mats Lindh

unread,
Mar 31, 2012, 12:49:37 PM3/31/12
to gea...@googlegroups.com
2012/3/31 Dr Börse <fbmh...@googlemail.com>:

> I installed Gearman 0.29 on my Server.
>
> When this Error occurs:
>
> Fatal error: Uncaught exception 'GearmanException' with message 'Failed to set e
> xception option' in /var/www/cron/client.php:41

This is usually caused by either gearmand not being available (try to
connect to it manually through telnet from the same host as PHP runs
on) or the versions differing. You didn't provide any information
about the gearmand you're currently running (only the version of
libgearman used when compiling the gearman extension for PHP), so be
sure that you've restarted gearmand after upgrading it.

--mats

Dr Börse

unread,
Apr 1, 2012, 4:15:33 AM4/1/12
to gea...@googlegroups.com
Thanks mats for your response.
My gearmand version was 1.0.2. And I restarted the Server with the command "gearmand". But same error occurs.
That's why I went back to gearmand 0.7.0 and libgearman 0.1.3.
Reply all
Reply to author
Forward
0 new messages