Atom 2.6.4 - Link Digital Objects - 500 Interal Server Error when linking to remote image URL

134 views
Skip to first unread message

Paul Haynes

unread,
Apr 28, 2022, 12:09:21 PM4/28/22
to AtoM Users

We have an AtoM instance and we are linking external images using the standard /object/addDigitalObject process but upon clicking create we get a "500 Internal Server Error".
http://atomtest.local/index.php/test-0001/object/addDigitalObject

The remote server is presented on port 81 but fault occurs on standard HTTP 80 too. The media is presented via nginx, and content is on a mounted remote cifs volume from a Ubuntu 18.04 server.
http://digitalobjects-test.local:81/private/nro_private_testfile.jpg

i have extracted the logs. the www-data account has access to the content, and can be browsed easily via the site by adding direct path as above, but will not work for linking remote digital object. i have tested linking a random file from wikipedia and that actually worked.

Any comments are welcome to help figure this out. Has anyone experienced this before?

root@SERVER:/etc/nginx/sites-available# sudo tail -f /var/log/nginx/error.log
2022/04/22 11:57:35 [error] 3636#3636: *58 FastCGI sent in stderr: "PHP message: Failed to set permissions on /usr/share/nginx/atom/uploads/r/null/c/6/b/c6b40018db18ef27b6f22a47d91fa5a9c0aa0a9c5b8c01dcaf543ecdf1a174a7/AF_281-001_1_.jpg" while reading response header from upstream, client: 10.120.29.43, server: _, request: "POST /index.php/test-record/informationobject/multiFileUpload HTTP/1.1", upstream: "fastcgi://unix:/run/php7.2-fpm.atom.sock:", host: "atomtest.local", referrer: "http://atomtest.local/index.php/test-record/informationobject/multiFileUpload"
2022/04/22 11:57:58 [error] 3636#3636: *58 FastCGI sent in stderr: "PHP message: Failed to set permissions on /usr/share/nginx/atom/uploads/r/null/c/6/b/c6b40018db18ef27b6f22a47d91fa5a9c0aa0a9c5b8c01dcaf543ecdf1a174a7/AF_281-001_2_.jpg" while reading response header from upstream, client: 10.120.29.43, server: _, request: "POST /index.php/test-record/informationobject/multiFileUpload HTTP/1.1", upstream: "fastcgi://unix:/run/php7.2-fpm.atom.sock:", host: "atomtest.local", referrer: "http://atomtest.local/index.php/test-record/informationobject/multiFileUpload"
2022/04/22 12:02:04 [error] 3642#3642: *165 FastCGI sent in stderr: "PHP message: Empty module and/or action after parsing the URL "/public/IMAGES/kl/kl-c/kl-c_10/kl-c_10-1/kl-c_10-1_img_001.jpg" (/)" while reading response header from upstream, client: 10.116.144.8, server: _, request: "GET /public/IMAGES/kl/kl-c/kl-c_10/kl-c_10-1/kl-c_10-1_img_001.jpg HTTP/1.1", upstream: "fastcgi://unix:/run/php7.2-fpm.atom.sock:", host: "digitalobjects-test.local"
2022/04/22 12:02:39 [error] 3636#3636: *58 FastCGI sent in stderr: "PHP message: Failed to set permissions on /usr/share/nginx/atom/uploads/r/null/c/5/c/c5c38b286eca4994c49c56b9382fabd10a23f3be71d8b53b436b80db9bb965e3/AF_281-001_141.jpg" while reading response header from upstream, client: 10.120.29.43, server: _, request: "POST /index.php/test-record-2/object/addDigitalObject HTTP/1.1", upstream: "fastcgi://unix:/run/php7.2-fpm.atom.sock:", host: "atomtest.local", referrer: "http://atomtest.local/index.php/test-record-2/object/addDigitalObject"
2022/04/22 12:10:10 [error] 3636#3636: *283 open() "/usr/share/nginx/atom/resource/favicon.ico" failed (2: No such file or directory), client: 10.116.144.8, server: digitalobjects-test.local, request: "GET /favicon.ico HTTP/1.1", host: "digitalobjects-test.local:81", referrer: "http://digitalobjects-test.local:81/private/"


2022/04/22 12:14:04 [error] 3636#3636: *339 open() "/usr/share/nginx/atom/resource/public/IMAGES/af/af_281/AF_281-001.jpg" failed (2: No such file or directory), client: 127.0.0.1, server: digitalobjects-test.local, request: "GET /public/IMAGES/af/af_281/AF_281-001.jpg HTTP/1.1", host: "digitalobjects-test.local:81"
2022/04/22 12:14:10 [error] 3636#3636: *343 open() "/usr/share/nginx/atom/resource/public/IMAGES/af/af_281/AF_281-001.jpg" failed (2: No such file or directory), client: 10.120.29.43, server: digitalobjects-test.local, request: "GET /public/IMAGES/af/af_281/AF_281-001.jpg HTTP/1.1", host: "digitalobjects-test.local:81", referrer: "http://atomtest.local/"
2022/04/22 12:14:13 [error] 3636#3636: *343 open() "/usr/share/nginx/atom/resource/public/IMAGES/af/af_281/AF_281-001.jpg" failed (2: No such file or directory), client: 10.120.29.43, server: digitalobjects-test.local, request: "GET /public/IMAGES/af/af_281/AF_281-001.jpg HTTP/1.1", host: "digitalobjects-test.local:81", referrer: "http://atomtest.local/"

2022/04/22 12:14:15 [error] 3636#3636: *319 FastCGI sent in stderr: "PHP message: Failed to set permissions on /usr/share/nginx/atom/uploads/r/null/d/f/e/dfe313f79d235c391af48dc1bc755848230d25a2b2e39f65b0366276c4fd7284/nro_private_testfile_141.jpg" while reading response header from upstream, client: 10.116.144.8, server: _, request: "POST /index.php/test-0001/object/addDigitalObject HTTP/1.1", upstream: "fastcgi://unix:/run/php7.2-fpm.atom.sock:", host: "atomtest.local", referrer: "http://atomtest.local/index.php/test-0001/object/addDigitalObject"
2022/04/22 12:14:43 [error] 3636#3636: *325 FastCGI sent in stderr: "PHP message: Failed to set permissions on /usr/share/nginx/atom/uploads/r/null/5/9/0/59038ab1e737fdfa89446c2881fdc75ff5fe2376b63200d0866d727ff80b3c2b/acc_1997-146-2-8_001.jpg" while reading response header from upstream, client: 10.120.29.43, server: _, request: "POST /index.php/af-281-001-jpg/edit HTTP/1.1", upstream: "fastcgi://unix:/run/php7.2-fpm.atom.sock:", host: "atomtest.local", referrer: "http://atomtest.local/index.php/af-281-001-jpg/edit"

Dan Gillean

unread,
Apr 29, 2022, 8:58:48 AM4/29/22
to ICA-AtoM Users
Hi Paul, 

I will have to check with our team to see if they have further insights on these specific error messages, but first: 

Is the remote server where the digital object is located available on the public web? If not, I suspect that might be the issue. Currently, linking by URL has 3 basic requirements for success: 
  1. The digital object must be available on the public web - no password protections, VPN requirements, etc. Otherwise AtoM will be unable to fetch it, even if it's in your local network. 
  2. The URL must be http or https - no local share drives, FTP links, etc. 
  3. The URL must end in the file extension of the digital object - linking to landing pages that include a digital object will not be enough for AtoM to identify and select the target.
I'm guessing that the link you used in your post is an example placeholder and not the actual link, but nevertheless, as an example, I can't access it - and I or anyone else should be able to if the linking is going to work. Wikipedia on the other hand is publicly accessible. 

If you are trying to save storage space and avoid duplicating the amount of digital objects you maintain locally, one alternative option might be to use the Digital Object Load task, with the --link-source option added in 2.6. When this option is used, the load task behaves like the linking by URL option - once the derivatives have been generated, AtoM will discard the master object that has been fetched, and instead store the path to the original file. See: 
Finally, this is likely not the issue, but you can always try re-applying the filesystem permissions to ensure everything is configured as expected with: 
Hope this helps, 

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


--
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 view this discussion on the web visit https://groups.google.com/d/msgid/ica-atom-users/fbd7a4be-ed05-4449-964c-9bbe1cc833d8n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages