Menu

iTop's Setup can't backup with mysqldump

metafaniel
2015-03-03
2015-04-28
  • metafaniel

    metafaniel - 2015-03-03

    Hi everyone!
    When I try to run the iTop Setup, there ir a problem with mysqldump.
    I check the Backup the iTop database before upgrading option, and the instalation halts at 20% with this message:

    Failed to execute mysqldump: Check the log files '' for more information.
    

    In the file iTop\log\setup.log it's the following message:

    Error - Failed to execute: mysqldump --opt --default-character-set=utf8 --add-drop-database --single-transaction --host="127.0.0.1"  --user=xxxxx --password=xxxxx --result-file="C:\Windows\Temp\itoDC43.tmp" "itop_210" "itop_applicationsolution" "itop_attachment" "itop_brand" "itop_businessprocess" "itop_change" "itop_change_approved" "itop_change_emergency" "itop_change_normal" "itop_change_routine" "itop_connectableci" "itop_contact" "itop_contacttype" "itop_contract" "itop_contracttype" "itop_coverage_windows" "itop_customercontract" "itop_databaseschema" "itop_datacenterdevice" "itop_dbserver" "itop_deliverymodel" "itop_document" "itop_documentfile" "itop_documentnote" "itop_documenttype" "itop_documentweb" "itop_enclosure" "itop_faq" "itop_faqcategory" "itop_farm" "itop_fiberchannelinterface" "itop_functionalci" "itop_group" "itop_holiday_calendar" "itop_holidays" "itop_hypervisor" "itop_iosversion" "itop_ipinterface" "itop_ipphone" "itop_knownerror" "itop_licence" "itop_lnkapplicationsolutiontobusinessprocess" "itop_lnkapplicationsolutiontofunctionalci" "itop_lnkconnectablecitonetworkdevice" "itop_lnkcontacttocontract" "itop_lnkcontacttofunctionalci" "itop_lnkcontacttoservice" "itop_lnkcontacttoticket" "itop_lnkcontracttodocument" "itop_lnkcustomercontracttofunctionalci" "itop_lnkcustomercontracttoprovidercontract" "itop_lnkcustomercontracttoservice" "itop_lnkdatacenterdevicetosan" "itop_lnkdeliverymodeltocontact" "itop_lnkdocumenttoerror" "itop_lnkdocumenttofunctionalci" "itop_lnkdocumenttolicence" "itop_lnkdocumenttopatch" "itop_lnkdocumenttoservice" "itop_lnkdocumenttosoftware" "itop_lnkerrortofunctionalci" "itop_lnkfunctionalcitoospatch" "itop_lnkfunctionalcitoprovidercontract" "itop_lnkfunctionalcitoticket" "itop_lnkgrouptoci" "itop_lnkpersontoteam" "itop_lnkphysicalinterfacetovlan" "itop_lnkservertovolume" "itop_lnkslatoslt" "itop_lnksoftwareinstancetosoftwarepatch" "itop_lnksubnettovlan" "itop_lnkvirtualdevicetovolume" "itop_location" "itop_logicalinterface" "itop_logicalvolume" "itop_middleware" "itop_middlewareinstance" "itop_mobilephone" "itop_model" "itop_nas" "itop_nasfilesystem" "itop_networkdevice" "itop_networkdevicetype" "itop_networkinterface" "itop_organization" "itop_osfamily" "itop_oslicence" "itop_ospatch" "itop_osversion" "itop_othersoftware" "itop_patch" "itop_pc" "itop_pcsoftware" "itop_pdu" "itop_peripheral" "itop_person" "itop_phone" "itop_physicaldevice" "itop_physicalinterface" "itop_powerconnection" "itop_powersource" "itop_printer" "itop_priv_action" "itop_priv_action_email" "itop_priv_action_notification" "itop_priv_app_dashboards" "itop_priv_app_preferences" "itop_priv_async_send_email" "itop_priv_async_task" "itop_priv_auditcategory" "itop_priv_auditrule" "itop_priv_backgroundtask" "itop_priv_change" "itop_priv_changeop" "itop_priv_changeop_create" "itop_priv_changeop_delete" "itop_priv_changeop_links" "itop_priv_changeop_links_addremove" "itop_priv_changeop_links_tune" "itop_priv_changeop_plugin" "itop_priv_changeop_setatt" "itop_priv_changeop_setatt_data" "itop_priv_changeop_setatt_encrypted" "itop_priv_changeop_setatt_log" "itop_priv_changeop_setatt_longtext" "itop_priv_changeop_setatt_pwd" "itop_priv_changeop_setatt_scalar" "itop_priv_changeop_setatt_text" "itop_priv_db_properties" "itop_priv_event" "itop_priv_event_email" "itop_priv_event_issue" "itop_priv_event_loginusage" "itop_priv_event_notification" "itop_priv_event_webservice" "itop_priv_internaluser" "itop_priv_link_action_trigger" "itop_priv_module_install" "itop_priv_query" "itop_priv_query_oql" "itop_priv_shortcut" "itop_priv_shortcut_oql" "itop_priv_sync_att" "itop_priv_sync_att_extkey" "itop_priv_sync_att_linkset" "itop_priv_sync_datasource" "itop_priv_sync_log" "itop_priv_sync_replica" "itop_priv_trigger" "itop_priv_trigger_onobjcreate" "itop_priv_trigger_onobject" "itop_priv_trigger_onportalupdate" "itop_priv_trigger_onstatechange" "itop_priv_trigger_onstateenter" "itop_priv_trigger_onstateleave" "itop_priv_trigger_threshold" "itop_priv_urp_profiles" "itop_priv_urp_userorg" "itop_priv_urp_userprofile" "itop_priv_user" "itop_priv_user_local" "itop_providercontract" "itop_rack" "itop_sanswitch" "itop_server" "itop_service" "itop_servicefamilly" "itop_servicesubcategory" "itop_sla" "itop_slt" "itop_software" "itop_softwareinstance" "itop_softwarelicence" "itop_softwarepatch" "itop_storagesystem" "itop_subnet" "itop_tablet" "itop_tape" "itop_tapelibrary" "itop_team" "itop_telephonyci" "itop_ticket" "itop_ticket_incident" "itop_ticket_problem" "itop_ticket_request" "itop_typology" "itop_vehicle" "itop_view_actionemail" "itop_view_applicationsolution" "itop_view_approvedchange" "itop_view_attachment" "itop_view_brand" "itop_view_businessprocess" "itop_view_change" "itop_view_connectableci" "itop_view_contact" "itop_view_contacttype" "itop_view_contract" "itop_view_contracttype" "itop_view_coveragewindow" "itop_view_customercontract" "itop_view_databaseschema" "itop_view_datacenterdevice" "itop_view_dbserver" "itop_view_deliverymodel" "itop_view_document" "itop_view_documentfile" "itop_view_documentnote" "itop_view_documenttype" "itop_view_documentweb" "itop_view_emergencychange" "itop_view_enclosure" "itop_view_faq" "itop_view_faqcategory" "itop_view_farm" "itop_view_fiberchannelinterface" "itop_view_functionalci" "itop_view_group" "itop_view_holiday" "itop_view_holidaycalendar" "itop_view_hypervisor" "itop_view_incident" "itop_view_iosversion" "itop_view_ipinterface" "itop_view_ipphone" "itop_view_knownerror" "itop_view_licence" "itop_view_lnkapplicationsolutiontobusinessprocess" "itop_view_lnkapplicationsolutiontofunctionalci" "itop_view_lnkconnectablecitonetworkdevice" "itop_view_lnkcontacttocontract" "itop_view_lnkcontacttofunctionalci" "itop_view_lnkcontacttoservice" "itop_view_lnkcontacttoticket" "itop_view_lnkcontracttodocument" "itop_view_lnkcustomercontracttofunctionalci" "itop_view_lnkcustomercontracttoprovidercontract" "itop_view_lnkcustomercontracttoservice" "itop_view_lnkdeliverymodeltocontact" "itop_view_lnkdocumenttoerror" "itop_view_lnkdocumenttofunctionalci" "itop_view_lnkdocumenttolicence" "itop_view_lnkdocumenttopatch" "itop_view_lnkdocumenttoservice" "itop_view_lnkdocumenttosoftware" "itop_view_lnkerrortofunctionalci" "itop_view_lnkfunctionalcitoospatch" "itop_view_lnkfunctionalcitoprovidercontract" "itop_view_lnkfunctionalcitoticket" "itop_view_lnkgrouptoci" "itop_view_lnkpersontoteam" "itop_view_lnkphysicalinterfacetovlan" "itop_view_lnksantodatacenterdevice" "itop_view_lnkservertovolume" "itop_view_lnkslatoslt" "itop_view_lnksoftwareinstancetosoftwarepatch" "itop_view_lnksubnettovlan" "itop_view_lnktriggeraction" "itop_view_lnkvirtualdevicetovolume" "itop_view_location" "itop_view_logicalinterface" "itop_view_logicalvolume" "itop_view_middleware" "itop_view_middlewareinstance" "itop_view_mobilephone" "itop_view_model" "itop_view_nas" "itop_view_nasfilesystem" "itop_view_networkdevice" "itop_view_networkdevicetype" "itop_view_networkinterface" "itop_view_normalchange" "itop_view_organization" "itop_view_osfamily" "itop_view_oslicence" "itop_view_ospatch" "itop_view_osversion" "itop_view_othersoftware" "itop_view_patch" "itop_view_pc" "itop_view_pcsoftware" "itop_view_pdu" "itop_view_peripheral" "itop_view_person" "itop_view_phone" "itop_view_physicaldevice" "itop_view_physicalinterface" "itop_view_powerconnection" "itop_view_powersource" "itop_view_printer" "itop_view_problem" "itop_view_providercontract" "itop_view_rack" "itop_view_routinechange" "itop_view_sanswitch" "itop_view_server" "itop_view_service" "itop_view_servicefamily" "itop_view_servicesubcategory" "itop_view_sla" "itop_view_slt" "itop_view_software" "itop_view_softwareinstance" "itop_view_softwarelicence" "itop_view_softwarepatch" "itop_view_storagesystem" "itop_view_subnet" "itop_view_tablet" "itop_view_tape" "itop_view_tapelibrary" "itop_view_team" "itop_view_telephonyci" "itop_view_ticket" "itop_view_triggeronobjectcreate" "itop_view_triggeronportalupdate" "itop_view_triggeronstateenter" "itop_view_triggeronstateleave" "itop_view_triggeronthresholdreached" "itop_view_typology" "itop_view_userrequest" "itop_view_vehicle" "itop_view_virtualdevice" "itop_view_virtualhost" "itop_view_virtualmachine" "itop_view_vlan" "itop_view_webapplication" "itop_view_webserver" "itop_view_workorder" "itop_virtualdevice" "itop_virtualhost" "itop_virtualmachine" "itop_vlan" "itop_webapplication" "itop_webserver" "itop_workorder". The command returned:1
    

    If I run that exact command in a console, changing xxxxx with my actual user and password for the iTop DB, the command doesn't return any error, and the dump is done correctly.
    In iTop's configuration file, the variables db_user and db_pwd are set correctly, so I don't understand why the log has those xxxxx there, and why the command fails if it runs correctly in the console.

    I can't backup iTop with the given option in SETUP. In order to proceed, I disable the Backup the iTop database before upgrading option to continue. My installation finishes without any errors, so it has nothing to do with any extension or the data model or something.

    What can fix this issue?

    THANKS

    (PS I intended to post this message under "Installing and using iTop" and not under "Customizing iTop" SORRY! A moderate can fix this certainly)

     

    Last edit: metafaniel 2015-03-03
  • John Delgro

    John Delgro - 2015-04-28

    Hi metafaniel,

    Got the same problem. The reason you see xxxx at username and password is because in the code it's showing you something else. See below.

    \setup\backup.class.inc.php:

    $sCommand = "$sMySQLDump --opt --default-character-set=utf8 --add-drop-database --single-transaction --host=$sHost $sPortOption --user=$sUser --password=$sPwd --result-file=$sTmpFileName $sDBName $sTables 2>&1";
    $sCommandDisplay = "$sMySQLDump --opt --default-character-set=utf8 --add-drop-database --single-transaction --host=$sHost $sPortOption --user=xxxx --password=xxxx --result-file=$sTmpFileName $sDBName $sTables";
    

    I tested the command below and it created the backup succesfull.

    mysqldump --opt --default-character-set=utf8 --single-transaction --add-drop-database -u "MyUser" --password="MySecretPassword" "itop_db" > "c:\test.txt"
    

    When I pasted this command to the $sCommand variable it didn't work. So this is how far I got.

     

    Last edit: John Delgro 2015-04-28

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.