Web based family history software

Question An unexpected database error occurred during upgrade.

  • craydiver
  • Topic Author
  • Offline
  • New Member
  • New Member
More
1 year 2 months ago #1 by craydiver
Hi there,
I'm trying to recover my webtrees site from a mysql backup after hardware failure.  For now I'm attempting the recovery using docker.
I've recreated the DB from the .sql file, created a db user and from that can determine that the old version is 1.7.8.
I can kick off the set-up wizard (with the server set to the docker container name, to point to my recovered DB), after which I configure myself as a webtrees user.
From there though, things go downhill, with the following error.

SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'multimedia_file_refn' cannot be null (SQL: insert into `wt_media_file` (`m_id`, `m_file`, `multimedia_file_refn`, `multimedia_format`, `source_media_type`, `descriptive_title`) select `m_id`, `m_file`, SUBSTRING(m_filename, 1, 248), SUBSTRING(m_ext, 1, 4), SUBSTRING(m_type, 1, 15), SUBSTRING(m_titl, 1, 248) from `wt_media`)

The detail is below...

I can see that the wt_media_file table is empty, though the wt_media table is not. (in case it matters, right now I do not have the actual media files on-hand - working on that).

Appreciative of any support.
Thanks, Greg.

#0 /var/www/html/vendor/illuminate/database/Connection.php(672): Illuminate\Database\Connection->runQueryCallback('insert into `wt...', Array, Object(Closure))
#1 /var/www/html/vendor/illuminate/database/Connection.php(533): Illuminate\Database\Connection->run('insert into `wt...', Array, Object(Closure))
#2 /var/www/html/vendor/illuminate/database/Query/Builder.php(3046): Illuminate\Database\Connection->affectingStatement('insert into `wt...', Array)
#3 /var/www/html/app/Schema/Migration37.php(84): Illuminate\Database\Query\Builder->insertUsing(Array, Object(Closure))
#4 /var/www/html/app/Services/MigrationService.php(69): Fisharebest\webtrees\Schema\Migration37->upgrade()
#5 /var/www/html/app/Http/RequestHandlers/SetupWizard.php(396): Fisharebest\webtrees\Services\MigrationService->updateSchema('\\Fisharebest\\We...', 'WT_SCHEMA_VERSI...', 45)
#6 /var/www/html/app/Http/RequestHandlers/SetupWizard.php(357): Fisharebest\webtrees\Http\RequestHandlers\SetupWizard->createConfigFile(Array)
#7 /var/www/html/app/Http/RequestHandlers/SetupWizard.php(193): Fisharebest\webtrees\Http\RequestHandlers\SetupWizard->step6Install(Array)
#8 /var/www/html/app/Http/Middleware/ReadConfigIni.php(68): Fisharebest\webtrees\Http\RequestHandlers\SetupWizard->handle(Object(Nyholm\Psr7\ServerRequest))
#9 /var/www/html/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\webtrees\Http\Middleware\ReadConfigIni->process(Object(Nyholm\Psr7\ServerRequest), Object(Fisharebest\webtrees\Http\RequestHandlers\SetupWizard))
#10 /var/www/html/app/Http/Middleware/SecurityHeaders.php(48): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#11 /var/www/html/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\webtrees\Http\Middleware\SecurityHeaders->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#12 /var/www/html/app/Http/Middleware/EmitResponse.php(57): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#13 /var/www/html/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\webtrees\Http\Middleware\EmitResponse->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#14 /var/www/html/vendor/oscarotero/middleland/src/Dispatcher.php(118): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#15 /var/www/html/app/webtrees.php(275): Middleland\Dispatcher->dispatch(Object(Nyholm\Psr7\ServerRequest))
#16 /var/www/html/app/webtrees.php(262): Fisharebest\webtrees\webtrees::dispatch(Object(Nyholm\Psr7\ServerRequest), Array)
#17 /var/www/html/index.php(51): Fisharebest\webtrees\webtrees->httpRequest()
#18 {main}

Please Log in or Create an account to join the conversation.

  • bertkoor
  • Offline
  • Platinum Member
  • Platinum Member
  • Greetings from Utrecht, Holland
More
1 year 2 months ago - 1 year 2 months ago #2 by bertkoor
Of which webtrees version have to taken the .php files to set up the webtrees server?

If the webtrees version was 1.7.x, then I would start with that exact version. Only if you get that up & running, do a gradual upgrade of webtrees.
You can download it from here:  github.com/fisharebest/webtrees/releases?page=8

Be aware:
* webtrees 1.7.x only runs on PHP 5.3 - 7.3
* webtrees 2.0.x only runs on PHP 7.1 - 7.4
* webtrees 2.1.x only runs on PHP 7.4 - 8.2

So start with PHP 7.3 + webtrees 1.7.8, the whole upgrade path is:
* upgrade webtrees to 2.0
* upgrade PHP to 7.4
* upgrade webtrees to 2.1
* upgrade PHP to 8.2

From webtrees.net/upgrade/

webtrees 1.4.0 – 1.7.9
You cannot upgrade directly to webtrees 2.1.17. Instead, you must first upgrade to webtrees 1.7.20.

webtrees 1.7.10 – 1.7.20
There are several important differences between webtrees 1.7 and webtrees 2.0. You should read them before upgrading, as you may need to make changes to your settings, your server configuration, or your workflow.

There is currently no automatic upgrade from webtrees 1.7 to webtrees 2.0, so you will need to follow the instructions for a manual upgrade.
 


stamboom.BertKoor.nl runs on webtrees v2.1.20
Last edit: 1 year 2 months ago by bertkoor.

Please Log in or Create an account to join the conversation.

  • craydiver
  • Topic Author
  • Offline
  • New Member
  • New Member
More
1 year 2 months ago #3 by craydiver
Thanks very much - that detail helps.
Will work to your suggested plan and report back.

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum