Importing records. Warning : Unable to load dynamic library

185 views
Skip to first unread message

Costanza Lisi

unread,
Feb 1, 2024, 12:23:27 PMFeb 1
to AtoM Users
Hello, I have a little question. I’m loading some data in my Atom Site (archiviconsolari.it). I imported the autority records. The report at the end of the activity give a warning

[info] [2024-01-31 14:08:23] Job 17395 "arFileImportJob": Job started. [info] [2024-01-31 14:08:23] Job 17395 "arFileImportJob": Parameters: {"index":true,"doCsvTransform":false,"skip-unmatched":false,"skip-matched":false,"parentId":null,"objectType":"authorityRecord","importType":"csv","update":"import-as-new","repositorySlug":"","collectionSlug":null,"file":{"name":"000_importazione_accessPointNames_Archivio_6_gen_2024_csv.csv","type":"text\/csv","tmp_name":"\/usr\/share\/nginx\/atom\/uploads\/tmp\/TMP286cbb87.csv","error":0,"size":168933},"name":"arFileImportJob","id":"17395"} [info] [2024-01-31 14:08:23] Job 17395 "arFileImportJob": Importing CSV file: 000_importazione_accessPointNames_Archivio_6_gen_2024_csv.csv. [info] [2024-01-31 14:08:23] Job 17395 "arFileImportJob": Indexing imported records. [info] [2024-01-31 14:08:23] Job 17395 "arFileImportJob": Update type: import-as-new [info] [2024-01-31 14:09:25] Job 17395 "arFileImportJob": php '/usr/share/nginx/atom/symfony' 'csv:authority-import' --index --quiet --source-name='000_importazione_accessPointNames_Archivio_6_gen_2024_csv.csv' '/usr/share/nginx/atom/uploads/tmp/TMP286cbb87.csv' [info] [2024-01-31 14:09:25] Job 17395 "arFileImportJob": PHP Warning: PHP Startup: Unable to load dynamic library 'pdo_mysql' (tried: /usr/lib/php/20190902/pdo_mysql (/usr/lib/php/20190902/pdo_mysql: cannot open shared object file: No such file or directory), /usr/lib/php/20190902/pdo_mysql.so (/usr/lib/php/20190902/pdo_mysql.so: undefined symbol: mysqlnd_allocator)) in Unknown on line 0 [info] [2024-01-31 14:09:25] Job 17395 "arFileImportJob": .......................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................... [info] [2024-01-31 14:09:25] Job 17395 "arFileImportJob": Import complete. [info] [2024-01-31 14:09:25] Job 17395 "arFileImportJob": Job finished.
    Everithing seems ok. I can find the names and sort them. Can I import also the archival descriptions? Or will it cause some problems?

    Thanks for help

    Costanza Lisi

Dan Gillean

unread,
Feb 2, 2024, 8:46:38 AMFeb 2
to ica-ato...@googlegroups.com
Hi Costanza, 

I don't recall seeing that specific error before, so let's investigate a bit further just to be safe. It looks like the application was trying to access an extension (pdo_mysql) and could not. I worry that this means that it was not properly writing all metadata to the database, but hopefully not. Fortunately, there are a number of checks and tasks we can run that might help, and won't harm anything if not. 

First of all, what is the full version number of your AtoM installation, as shown in Admin > Settings? Have you upgraded recently?

pdo_mysql typically requires the PHP extension php-mysql to be installed. Normally this is installed as one of several PHP extensions during installation, here: 
Let's just make sure that extension is installed. If you are running AtoM 2.7 or 2.8 with PHP 7.4, you can confirm this with: 
  • sudo apt install php7.4-mysql
Then we will quickly clear the application cache, restart PHP-FPM and reload Nginx: 
  • php symonfy cc
  • sudo systemctl restart php7.4-fpm
  • sudo systemctl reload nginx
I don't think this was the case, but let's also ensure that the filesystem permissions are properly configured for your installation. AtoM typically expects all files and directories below the root installation directory to be own by the www-data user. We can ensure this is set with: 
Now, let's also run a few common maintenance tasks that can resolve common issues with partial data - namely, we will build the nested set, and generate any missing slugs. Like all Symfony commands (including the clear cache command above), these should be run from AtoM's root installation directory (typically /usr/share/nginx/atom if you have followed our recommended installation instructions). Try:

Build nested set: 
Finally let's repopulate the search index, just to ensure that everything is up to date. This task may take a while if you have a lot of data in your system, so if this is a production instance, you may want to run it outside of business hours, as your public-facing records will be temporarily unavailable as they are reindexed: 
The last thing I would suggest is that you create a backup of the database. Data corruption can sometimes take a while for its effects to be shown - we have some queries in our documentation for finding and resolving data corruption in archival descriptions (here - which you could try, but may not turn up anything related to this), but currently we don't have much documented to check for corruption in authority records or other entities. So juuuuuust in case there is something we have missed, ensuring you have a backup to load where we can return to the issue at hand is always helpful. See: 
Hopefully this will have covered all our bases! And if the PHP extension was in fact missing then hopefully this will ensure that the error is not repeated in the future. 

Let us know how it goes! 

Cheers, 

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/0126d155-377a-4fb5-b635-df6185b34421n%40googlegroups.com.

Costanza Lisi

unread,
Feb 2, 2024, 9:29:48 AMFeb 2
to ica-ato...@googlegroups.com
Thank you very much! I'll let you know of course

Have a nice day

Costanza

You received this message because you are subscribed to a topic in the Google Groups "AtoM Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ica-atom-users/tsh_WytjMJk/unsubscribe.
To unsubscribe from this group and all its topics, 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/CAC1FhZJ%2BSHG9c_9c%3D8GoztbZ6%2Bhfbfy3XRBjni-4NtOrFCCvUw%40mail.gmail.com.

Costanza Lisi

unread,
Feb 4, 2024, 12:36:19 PMFeb 4
to ica-ato...@googlegroups.com
Hello Dan,

David Soricetti who helps me to manage the software part of the web-site tried your suggestions but unluckily they did not work.

The warning appears not only by importing data but also by using (in the terminal) any ‘php’ command
It is true that commenting ‘extension=pdo_mysql’ in the file ‘php.ini’ the warning disappears but we do not know if:

a) this will compromise the functionality of the system
and/or
b) it will just hide the problem without resolving it
What do you think about that?
I must add that we are using the 2.7 version, with all the components suggested to install the software:
(https://www.accesstomemory.org/en/docs/2.7/admin-manual/installation/ubuntu/#installation-ubuntu)
Thank you again for your help
Costanza Lisi
RispondiInoltra

You received this message because you are subscribed to a topic in the Google Groups "AtoM Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/ica-atom-users/tsh_WytjMJk/unsubscribe.
To unsubscribe from this group and all its topics, 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/CAC1FhZJ%2BSHG9c_9c%3D8GoztbZ6%2Bhfbfy3XRBjni-4NtOrFCCvUw%40mail.gmail.com.

José Raddaoui

unread,
Feb 7, 2024, 12:06:14 PMFeb 7
to AtoM Users
Hi Costanza,

First time I see this error, but looking around I found this question/answers related to that issue:


If your database connection from AtoM is working as expected, commenting out the extension as you did may just be enough. Otherwise, I'd try reinstalling it like it's suggested in some of those answers.

Best,
Radda.

Costanza Lisi

unread,
Feb 8, 2024, 12:44:29 AMFeb 8
to ica-ato...@googlegroups.com
Thank you very much for the help, I'll let you know how it is going

Have a good day

Costanza

Peter Duggan

unread,
Feb 8, 2024, 8:10:04 AMFeb 8
to AtoM Users
Hiya,

I've come across this issue a few times over recent years.
In my experience it is caused by pdo_mysql being defined twice throughout the php fpm config files.
In Ubuntu 20.04 when installing php-mysql it will add the config data to enable it into this file "/etc/php/7.4/fpm/conf.d/20-pdo_mysql.ini" (making no changes to the default php.ini file) and thus if you also enable it in "/etc/php/7.4/fpm/php.ini" it is looking for a module that is already loaded so it cannot load said module hence the confusing error message.


Hope this helps

Costanza Lisi

unread,
Feb 8, 2024, 1:51:45 PMFeb 8
to ica-ato...@googlegroups.com
Thank you, grazie, for your suggestions

Costanza Lisi

Costanza Lisi

unread,
Feb 13, 2024, 9:18:53 AMFeb 13
to AtoM Users
Thanks to Peter. We followed the suggestion. It did work.  No warning anymore!

Many thanks again

Costanza 
Reply all
Reply to author
Forward
0 new messages