AtoM 2.4 install on ol7, 500 error, PHP message: No Gearman worker available that can handle the job

168 views
Skip to first unread message

Cindy

unread,
Sep 27, 2018, 12:35:34 PM9/27/18
to AtoM Users
Hi, 

I am new to AtoM, we've have installed 2.4 on ol7. The site is up running, but we get 500 error when trying to:
  • update publication status with descendants
  • generate the reports
  • generate a finding aid
Nginx error log:

FastCGI sent in stderr: "PHP message: No Gearman worker available that can handle the job arUpdatePublicationStatusJob" while reading response header from upstream, client: 10.0.2.2, server: _, request: "POST /index.php/....../informationobject/updatePublicationStatus HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm.atom.sock:",


  • Added options in /etc/sysconfig/gearmand, OPTIONS="--listen=* --port=4730"
  • Created service file as /usr/lib/systemd/system/atom-worker.service ( user and group = nginx )
gearmand is runing
ps aux | grep gearmand 
gearmand  7349  0.0  0.1 477848  5988 ?        Ssl  14:48   0:00 /usr/sbin/gearmand -d --listen=* - -port=4730

atom-work is running
sudo systemctl status atom-worker
● atom-worker.service - AtoM worker
   Loaded: loaded (/usr/lib/systemd/system/atom-worker.service; enabled; vendor preset: disabled)
   Active: active (running) since Thu 2018-09-27 14:56:43 UTC; 13s ago
 Main PID: 7400 (php)
   CGroup: /system.slice/atom-worker.service
           └─7400 /usr/bin/php -d memory_limit=-1 -d error_reporting="E_ALL" symfony jobs:worker

php[7400]: 2018-09-27 07:56:45 > New ability: arUpdatePublicationStatusJob
php[7400]: 2018-09-27 07:56:45 > New ability: arFileImportJob
php[7400]: 2018-09-27 07:56:45 > New ability: arInformationObjectXmlExportJob
php[7400]: 2018-09-27 07:56:45 > New ability: arXmlExportSingleFileJob
php[7400]: 2018-09-27 07:56:45 > New ability: arGenerateReportJob
php[7400]: 2018-09-27 07:56:45 > New ability: arActorCsvExportJob
php[7400]: 2018-09-27 07:56:45 > New ability: arActorXmlExportJob
php[7400]: 2018-09-27 07:56:45 > New ability: arRepositoryCsvExportJob
php[7400]: 2018-09-27 07:56:45 > Running worker...
php[7400]: 2018-09-27 07:56:45 > PID 7400

I also got following error when I trying to restart PHP-FPM:
sudo systemctl restart php70-php-fpm
Job for php70-php-fpm.service failed because the control process exited with error code. See "systemctl status php70-php-fpm.service" and "journalctl -xe" for details.

sudo systemctl status php70-php-fpm.service
● php70-php-fpm.service - The PHP FastCGI Process Manager
   Loaded: loaded (/usr/lib/systemd/system/php70-php-fpm.service; disabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Thu 2018-09-27 15:09:22 UTC; 25s ago
  Process: 7444 ExecStart=/opt/remi/php70/root/usr/sbin/php-fpm --nodaemonize (code=exited, status=78)
 Main PID: 7444 (code=exited, status=78)

systemd[1]: Starting The PHP FastCGI Process Manager...
php-fpm[7444]: [27-Sep-2018 15:09:22] ERROR: An another FPM instance seems to alread....sock
php-fpm[7444]: [27-Sep-2018 15:09:22] ERROR: FPM initialization failed
systemd[1]: php70-php-fpm.service: main process exited, code=exited, status=78/n/a
systemd[1]: Failed to start The PHP FastCGI Process Manager.
systemd[1]: Unit php70-php-fpm.service entered failed state.
systemd[1]: php70-php-fpm.service failed.

I think maybe the gearman worker error is related to this php-fpm error? how to fix the php-fpm service error?

Any help appreciated, thanks!

Cindy

Dan Gillean

unread,
Sep 27, 2018, 3:38:10 PM9/27/18
to ICA-AtoM Users
Hi Cindy, 

We have no experience working with Oracle Linux, so the advice I can offer is limited! 

However, I would try restarting the job scheduler, even if it says the service is running: 
  • sudo systemctl restart atom-worker
Regarding the PHP-FPM error, I wonder if you can try the softer reload option, rather than restart? Or perhaps rather than just a restart, try actively sending it a stop command first, and then a start? It looks like the restart won't work because another process is using it, so hopefully stop might abort that thread as well. 

Best of luck, 

Dan Gillean, MAS, MLIS
AtoM Program Manager
Artefactual Systems, Inc.
604-527-2056
@accesstomemory


--
You received this message because you are subscribed to the Google Groups "AtoM Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ica-atom-user...@googlegroups.com.
To post to this group, send email to ica-ato...@googlegroups.com.
Visit this group at https://groups.google.com/group/ica-atom-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/ica-atom-users/b593a375-dcbd-468d-b4f9-cbc764f8f63c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

cindys...@gmail.com

unread,
Sep 27, 2018, 4:58:21 PM9/27/18
to AtoM Users
Hi Dan,

Thank you for your reply.

I've just fixed the php-fpm error by killed pid and changed include = /etc/opt/remi/php70/php-fpm.d/atom.conf  in /etc/opt/remi/php70/php-fpm.conf

systemctl status php70-php-fpm.service -l
● php70-php-fpm.service - The PHP FastCGI Process Manager
   Loaded: loaded (/usr/lib/systemd/system/php70-php-fpm.service; disabled; vendor preset: disabled)
   Active: active (running) since Thu 2018-09-27 20:29:27 UTC; 7s ago
 Main PID: 8864 (php-fpm)
   Status: "Ready to handle connections"
   CGroup: /system.slice/php70-php-fpm.service
           ├─8864 php-fpm: master process (/etc/opt/remi/php70/php-fpm.conf
           ├─8865 php-fpm: pool atom
           ├─8866 php-fpm: pool atom
           ├─8867 php-fpm: pool atom
           ├─8868 php-fpm: pool atom
           └─8869 php-fpm: pool atom

systemd[1]: Starting The PHP FastCGI Process Manager...
systemd[1]: Started The PHP FastCGI Process Manager.

I also restarted nginx, php70-php-fpm, memcached,atom-worker and ran php smyfony cc, I'm getting other errors:

kernel: audit: type=1400 audit(1538076638.781:48): avc:  denied  { read } for  pid=8396 comm="php-fpm" name="plugins" dev="vboxsf" ino=192 scontext=system_Sep 27 19:30:38 kernel: audit: type=1400 audit(1538076638.799:49): avc:  denied  { read } for  pid=8396 comm="php-fpm" name="arElasticSearchPluginConfiguration.class.php"


Any idea?


Thanks,


Dan Gillean

unread,
Sep 27, 2018, 5:05:52 PM9/27/18
to ICA-AtoM Users
Hi Cindy, 

You're making progress! 

All I can offer about the most recent message is that it looks to me like a filesystem permissions issue. With an AtoM installation that follows our recommended instructions, all files and directories in the root AtoM directory need to be owned by the www-data user. I'm not sure if that will be the same in your environment or not, but it might be worth digging around a bit and checking what user owns the files and processes that are listed in this message. 

Regards, 

Dan Gillean, MAS, MLIS
AtoM Program Manager
Artefactual Systems, Inc.
604-527-2056
@accesstomemory

GS

unread,
Sep 28, 2018, 3:19:36 AM9/28/18
to AtoM Users
Hi Cindy
Check for selinux errors or temporarily disable it to see if it is the issue.
(I'm assuming OL7 by default enables selinux).
George

cindys...@gmail.com

unread,
Sep 28, 2018, 12:13:59 PM9/28/18
to AtoM Users
Thank you for the suggestion George.
The selinux is already disabled.
Reply all
Reply to author
Forward
0 new messages