Server Error Migrate from OTRS 4

Setting up Zammad worked fine but importing from OTRS via the web interface stalled. Trying again on the command line produces the errors described below. There are similar topics here and on Github, but none that really fit my case or help me solve that problem.
Infos:

Used Zammad version: 2.4.0
Used Zammad installation source: rpm (packager.io)
Operating system: openSUSE Leap 42.3
Browser + version: Firefox 52/57/59
Migration source: OTRS 4

Expected behavior:

Import from OTRS via command line completes successfully.

Actual behavior:

After setting the import variables and starting the import from OTRS as per the Zammad documentation, HTTP 500 and runtime errors occur.

Steps to reproduce the behavior:

standard installation of openSUSE (no GUI)
install dependencies as per the Zammad documentation
set up repositories for Elasticsearch and Zammad, install both
run OTRS import via command line (see below)

Ruby console output:

USER@leap:~> sudo zammad run rails c WARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.9.4 Loading production environment (Rails 5.1.4) irb(main):001:0> Setting.set('import_otrs_endpoint', 'http://FQDN/otrs/public.pl?Action=ZammadMigrator') Setting.reset_change_id: set new cache, 574177317 Setting.set('import_otrs_endpoint', "http://FQDN/otrs/public.pl?Action=ZammadMigrator") => true irb(main):002:0> Setting.set('import_otrs_endpoint_key', 'KEY') Setting.reset_change_id: set new cache, 676340037 Setting.set('import_otrs_endpoint_key', "KEY") => true irb(main):003:0> Setting.set('import_mode', true) Setting.reset_change_id: set new cache, 713646205 Setting.set('import_mode', true) => true irb(main):004:0> Import::OTRS.start thread#-: Start import... thread#-: POST: http://FQDN/otrs/public.pl?Action=ZammadMigrator thread#-: PARAMS: {:Action=>"ZammadMigrator", :Key=>"KEY"} thread#-: loading SysConfig... thread#-: POST: http://FQDN/otrs/public.pl?Action=ZammadMigrator thread#-: PARAMS: {:Subaction=>"Export", :Object=>"SysConfig", :Limit=>"", :Offset=>"", :Diff=>0, :Action=>"ZammadMigrator", :Key=>"KEY"} Setting.reset_change_id: set new cache, 904472499 Setting.set('http_type', "http") Setting.reset_change_id: set new cache, 694726481 Setting.set('organization', "NAME") Setting.reset_change_id: set new cache, 658119837 Setting.set('system_id', "01") Setting.reset_change_id: set new cache, 240125243 Setting.set('ticket_hook', "Ticket#") Setting.reset_change_id: set new cache, 869131259 Setting.set('ticket_number', "Ticket::Number::Date") Setting.reset_change_id: set new cache, 170644133 Setting.set('ticket_number_date', {:checksum=>true}) thread#-: loading DynamicField... thread#-: POST: http://FQDN/otrs/public.pl?Action=ZammadMigrator thread#-: PARAMS: {:Subaction=>"Export", :Object=>"DynamicField", :Limit=>"", :Offset=>"", :Diff=>0, :Action=>"ZammadMigrator", :Key=>"KEY"} thread#-: ERROR: Server Error: #<Net::HTTPInternalServerError 500 Internal Server Error readbody=true>! thread#-: POST: http://FQDN/otrs/public.pl?Action=ZammadMigrator thread#-: PARAMS: {:Subaction=>"Export", :Object=>"DynamicField", :Limit=>"", :Offset=>"", :Diff=>0, :Action=>"ZammadMigrator", :Key=>"KEY"} thread#-: ERROR: Server Error: #<Net::HTTPInternalServerError 500 Internal Server Error readbody=true>! thread#-: POST: http://FQDN/otrs/public.pl?Action=ZammadMigrator thread#-: PARAMS: {:Subaction=>"Export", :Object=>"DynamicField", :Limit=>"", :Offset=>"", :Diff=>0, :Action=>"ZammadMigrator", :Key=>"KEY"} thread#-: ERROR: Server Error: #<Net::HTTPInternalServerError 500 Internal Server Error readbody=true>! RuntimeError: Zammad Migrator returned an error from lib/import/otrs/requester.rb:129:inpost’
from lib/import/otrs/requester.rb:90:in request_json' from lib/import/otrs/requester.rb:77:inrequest_result’
from lib/import/otrs/requester.rb:34:in load' from lib/import/otrs.rb:142:inimport_action’
from lib/import/otrs.rb:73:in import' from lib/import/otrs.rb:157:inbase_objects’
from lib/import/otrs.rb:41:in start' from (irb):4 irb(main):005:0>

Here the OTRS APACHE Log
`[Wed Apr 4 15:34:21 2018] OutputFilterZnuny4OTRSRepoAdminPackageManager.pm: Subroutine new redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnuny4OTRSRepoAdminPackageManager.pm line 20.

[Wed Apr 4 15:34:21 2018] OutputFilterZnuny4OTRSRepoAdminPackageManager.pm: Subroutine Run redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnuny4OTRSRepoAdminPackageManager.pm line 29.

[Wed Apr 4 15:34:21 2018] OutputFilterZnunyVerify.pm: Subroutine new redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnunyVerify.pm line 14.

[Wed Apr 4 15:34:21 2018] OutputFilterZnunyVerify.pm: Subroutine Run redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnunyVerify.pm line 29.

[Wed Apr 4 15:34:55 2018] ZZZZZZnuny4OTRSRepo.pm: Subroutine Load redefined at /opt/otrs//Kernel/Config/Files/ZZZZZZnuny4OTRSRepo.pm line 25.

[Wed Apr 4 15:34:55 2018] de_Znuny4OTRSRepo.pm: Subroutine Data redefined at /opt/otrs//Kernel/Language/de_Znuny4OTRSRepo.pm line 16.

[Wed Apr 4 15:35:19 2018] ZZZZZZnuny4OTRSRepo.pm: Subroutine Load redefined at /opt/otrs//Kernel/Config/Files/ZZZZZZnuny4OTRSRepo.pm line 25.
[Wed Apr 4 15:35:19 2018] de_Znuny4OTRSRepo.pm: Subroutine Data redefined at /opt/otrs//Kernel/Language/de_Znuny4OTRSRepo.pm line 16.

[Wed Apr 4 15:35:19 2018] ZammadMigrator.pm: Subroutine new redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 23.
[Wed Apr 4 15:35:19 2018] ZammadMigrator.pm: Subroutine Run redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 33.
[Wed Apr 4 15:35:19 2018] ZammadMigrator.pm: Subroutine _Output redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 109.
[Wed Apr 4 15:35:19 2018] ZammadMigrator.pm: Subroutine _Error redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 158.

[Wed Apr 4 15:35:19 2018] Znuny4OTRSZammadMigratorTicketDiffSet.pm: Subroutine new redefined at /opt/otrs//Kernel/System/Ticket/Event/Znuny4OTRSZammadMigratorTicketDiffSet.pm line 20.
[Wed Apr 4 15:35:19 2018] Znuny4OTRSZammadMigratorTicketDiffSet.pm: Subroutine Run redefined at /opt/otrs//Kernel/System/Ticket/Event/Znuny4OTRSZammadMigratorTicketDiffSet.pm line 33.
[Wed Apr 4 15:35:19 2018] Migrator.pm: Subroutine new redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 19.
[Wed Apr 4 15:35:19 2018] Migrator.pm: Subroutine List redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 29.
[Wed Apr 4 15:35:19 2018] Migrator.pm: Subroutine Export redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 86.

[Wed Apr 4 15:35:19 2018] Migrator.pm: Subroutine _GenericFunctionCaller redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 125.
[Wed Apr 4 15:35:19 2018] Migrator.pm: Subroutine _Error redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 180.
[Wed Apr 4 15:35:19 2018] Customer.pm: Subroutine AttributeName redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 18.
[Wed Apr 4 15:35:19 2018] Customer.pm: Subroutine AttributeColumnName redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 24.
[Wed Apr 4 15:35:19 2018] Customer.pm: Subroutine AttributeModule redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 28.
[Wed Apr 4 15:35:19 2018] Customer.pm: Subroutine AttributeGetFunction redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 34.
[Wed Apr 4 15:35:19 2018] Customer.pm: Subroutine AttributeGetFunctionIDParameter redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 38.
[Wed Apr 4 15:35:19 2018] DynamicField.pm: Subroutine new redefined at /opt/otrs/Kernel/System/Zammad/Migrator/DynamicField.pm line 18.
[Wed Apr 4 15:35:19 2018] DynamicField.pm: Subroutine List redefined at /opt/otrs/Kernel/System/Zammad/Migrator/DynamicField.pm line 28.

[Wed Apr 4 15:35:19 2018] DynamicField.pm: Subroutine Export redefined at /opt/otrs/Kernel/System/Zammad/Migrator/DynamicField.pm line 50.
[Wed Apr 4 15:35:19 2018] GenericBase.pm: Subroutine new redefined at /opt/otrs/Kernel/System/Zammad/Migrator/GenericBase.pm line 32.
[Wed Apr 4 15:35:19 2018] GenericBase.pm: Subroutine List redefined at /opt/otrs/Kernel/System/Zammad/Migrator/GenericBase.pm line 42.
[Wed Apr 4 15:35:19 2018] GenericBase.pm: Subroutine Export redefined at /opt/otrs/Kernel/System/Zammad/Migrator/GenericBase.pm line 50.
[Wed Apr 4 15:35:19 2018] GenericBase.pm: Subroutine _GenericList redefined at /opt/otrs/Kernel/System/Zammad/Migrator/GenericBase.pm line 135.
[Wed Apr 4 15:35:19 2018] GenericBase.pm: Subroutine _GenericGet redefined at /opt/otrs/Kernel/System/Zammad/Migrator/GenericBase.pm line 187.
[Wed Apr 4 15:35:19 2018] GenericColumn.pm: Subroutine _GenericList redefined at /opt/otrs/Kernel/System/Zammad/Migrator/GenericColumn.pm line 20.
[Wed Apr 4 15:35:49 2018] ZZZZZZnuny4OTRSRepo.pm: Subroutine Load redefined at /opt/otrs//Kernel/Config/Files/ZZZZZZnuny4OTRSRepo.pm line 25.
[Wed Apr 4 15:35:49 2018] de_Znuny4OTRSRepo.pm: Subroutine Data redefined at /opt/otrs//Kernel/Language/de_Znuny4OTRSRepo.pm line 16.
[Wed Apr 4 15:35:51 2018] ZZZZZZnuny4OTRSRepo.pm: Subroutine Load redefined at /opt/otrs//Kernel/Config/Files/ZZZZZZnuny4OTRSRepo.pm line 25.
[Wed Apr 4 15:35:51 2018] de_Znuny4OTRSRepo.pm: Subroutine Data redefined at /opt/otrs//Kernel/Language/de_Znuny4OTRSRepo.pm line 16.
[Wed Apr 4 15:37:46 2018] ZZZZZZnuny4OTRSRepo.pm: Subroutine Load redefined at /opt/otrs//Kernel/Config/Files/ZZZZZZnuny4OTRSRepo.pm line 25.
[Wed Apr 4 15:40:54 2018] ZZZZZZnuny4OTRSRepo.pm: Subroutine Load redefined at /opt/otrs//Kernel/Config/Files/ZZZZZZnuny4OTRSRepo.pm line 25.
[Wed Apr 4 15:40:54 2018] de_Znuny4OTRSRepo.pm: Subroutine Data redefined at /opt/otrs//Kernel/Language/de_Znuny4OTRSRepo.pm line 16.
[Wed Apr 4 15:40:54 2018] ZammadMigrator.pm: Subroutine new redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 23.

[Wed Apr 4 15:40:54 2018] ZammadMigrator.pm: Subroutine Run redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 33.
[Wed Apr 4 15:40:54 2018] ZammadMigrator.pm: Subroutine _Output redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 109.
[Wed Apr 4 15:40:54 2018] ZammadMigrator.pm: Subroutine _Error redefined at /opt/otrs//Kernel/Modules/ZammadMigrator.pm line 158.
[Wed Apr 4 15:40:54 2018] OutputFilterZnuny4OTRSRepoAdminPackageManager.pm: Subroutine new redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnuny4OTRSRepoAdminPackageManager.pm line 20.
[Wed Apr 4 15:40:54 2018] OutputFilterZnuny4OTRSRepoAdminPackageManager.pm: Subroutine Run redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnuny4OTRSRepoAdminPackageManager.pm line 29.

[Wed Apr 4 15:40:54 2018] OutputFilterZnunyVerify.pm: Subroutine new redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnunyVerify.pm line 14.
[Wed Apr 4 15:40:54 2018] OutputFilterZnunyVerify.pm: Subroutine Run redefined at /opt/otrs//Kernel/Output/HTML/OutputFilterZnunyVerify.pm line 29.
[Wed Apr 4 15:40:54 2018] Znuny4OTRSZammadMigratorTicketDiffSet.pm: Subroutine new redefined at /opt/otrs//Kernel/System/Ticket/Event/Znuny4OTRSZammadMigratorTicketDiffSet.pm line 20.
[Wed Apr 4 15:40:54 2018] Znuny4OTRSZammadMigratorTicketDiffSet.pm: Subroutine Run redefined at /opt/otrs//Kernel/System/Ticket/Event/Znuny4OTRSZammadMigratorTicketDiffSet.pm line 33.
[Wed Apr 4 15:40:54 2018] Migrator.pm: Subroutine new redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 19.
[Wed Apr 4 15:40:54 2018] Migrator.pm: Subroutine List redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 29.
[Wed Apr 4 15:40:54 2018] Migrator.pm: Subroutine Export redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 86.
[Wed Apr 4 15:40:54 2018] Migrator.pm: Subroutine _GenericFunctionCaller redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 125.
[Wed Apr 4 15:40:54 2018] Migrator.pm: Subroutine _Error redefined at /opt/otrs/Kernel/System/Zammad/Migrator.pm line 180.
[Wed Apr 4 15:40:54 2018] Customer.pm: Subroutine AttributeName redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 18.
[Wed Apr 4 15:40:54 2018] Customer.pm: Subroutine AttributeColumnName redefined at /opt/otrs/Kernel/System/Zammad/Migrator/Customer.pm line 24.`

Hi @daku1 - Looks like you are using mod_perl (right?) have you tried to restart your apache?

Yes we are using mod_perl and Apache has been restarted

And the issue still persists?

Calling the URL directly should cause the same 500 Internal Server error. Could you please verify that via your browser:
http://FQDN/otrs/public.pl?Action=ZammadMigrator&Subaction=Export&Key=KEY&Object=DynamicField&Diff=0&Limit=&Offset=

Please remember to replace FQDN and KEY.

In case the error occurs please re-check you logs. There has to be a more detailed description of the error. Somewhere in /var/log/apache2/error_log or /var/log/httpd/error_log or /var/log/system.log

After running the Diff Worker again today, it also imported something but then came an error message and the migration was finished again on the rails console.

Apache

error_log

Hi @daku1 - ah, this looks “better”. Please reset/reinstall a fresh Zammad and perform the import in completely new/blank system without a diff. And make sure the connection to your systems is good. The error message in your first screenshot shows that there was a timeout while getting a response from the OTRS.

The caching errors are not bad should be more of a notice IMHO. I’ll improve that.

OTRS displays the following in the system log during the migration of a Diff

Hi @daku1 please setup a new/fresh/blank Zammad system and start a new import without the Diff functionality. Thanks!

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.