Hello,
        I've inherited a really old install of koha (3.18.11) and I'm trying to 
get it migrated to current stable. I've figured out most of the database 
upgrade issues along the way thanks to the mailing list archives and old bug 
entries, but now I've run into something I can't find a solution for.

Relevant versions:
OS: Ubuntu 22.04
Koha: 23.11.04-4
MySQL: 8.0.36-0ubuntu0.22.04.1

Issue:
When a user is created via LDAP auth to the OPAC, the updated_on field in the 
borrowers table is set to "0000-00-00 00:00:00" and this makes it fail to 
display in the Intranet interface, showing a 500 error for that page of Patrons 
or if you search directly for the patron. If I have the new patron request a 
change in their record via OPAC and approve it in the Intranet, the updated_on 
field changes to a current value and then things work as expected. That's 
obviously not scalable.

We have LDAP auth configured to connect to our campus active directory with the 
following settings:
   <replicate>1</replicate>
   <update>1</update>
   <auth_by_bind>1</auth_by_bind>
   <mapping>
     <firstname is="givenName"  ></firstname>
     <surname   is="sn"         ></surname>
     <userid    is="sAMAccountName" ></userid>
     <email     is="mail"       ></email>
     <address   is="streetAddress"      ></address>
     <city      is="l"          >Champaign, IL</city>
     <privacy   is=""           >1</privacy>
     <branchcode is=""          >TCC</branchcode>
     <categorycode is=""        >ST</categorycode>
   </mapping>

I've done some slight modification to the logging in Patron.pm and the values 
that are being logged for updated_on don't make much sense to me:
"updated_on" : { "after" : "SCALAR(0x55fff641bca0)", "before" : "2024-05-03 
21:59:40" } }

Any suggestions? Is this a side effect of explicit_defaults_for_timestamp 
changing in MySQL? Does mariadb handle this differently? I had to use mysql to 
get past some foreign key issues early in the database upgrade scripts, but am 
open to migrating to mariadb now that the data can be brought forward.


Thanks,

Corey Betka
Infrastructure Architect

University of Illinois at Urbana-Champaign │ Student Affairs │ Student Affairs 
Technology 
330 Clark Hall │ 1203 S 4th St │ M/C 548 │ Champaign, IL 61820


_______________________________________________

Koha mailing list  http://koha-community.org
Koha@lists.katipo.co.nz
Unsubscribe: https://lists.katipo.co.nz/mailman/listinfo/koha

Reply via email to