Announcement

Collapse
No announcement yet.

Problem with restore : Exception received : SQLSTATE[42S22]

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problem with restore : Exception received : SQLSTATE[42S22]

    hi,
    I have tested a disaster recovery plan.
    I have backuped files and sql data from my old Centreon 2.7.4 (CES 3.3) and I would like restore to my new Centreon 2.7.4 (CES 3.4).

    Procedure:

    backup CES :
    tar -czvf /tmp/etc_centreon.tar.gz /etc/centreon/
    tar -czvf /tmp/etc_centreon-engine.tar.gz /etc/centreon-engine/
    tar -czvf /tmp/etc_centreon-broker.tar.gz /etc/centreon-broker/
    tar -czvf /tmp/var_lib_centreon.tar.gz /var/lib/centreon/
    tar -czvf /tmp/var_lib_nagios_plugins.tar.gz /usr/lib/nagios/plugins/
    tar -czvf /tmp/etc_httpd_confd.tar.gz /etc/httpd/conf.d/
    tar -czvf /tmp/etc_logrotated.tar.gz /etc/logrotate.d/
    tar -czvf /tmp/var_log_centreon.tar.gz /var/log/centreon/
    tar -czvf /tmp/var_log_centreon-engine.tar.gz /var/log/centreon-engine/
    tar -czvf /tmp/var_log_centreon-broker.tar.gz /var/log/centreon-broker/
    tar -czvf /tmp/usr_local_nagvis /usr/local/nagvis/

    mysqldump -u root centreon > /tmp/backup_centreon.sql
    mysqldump -u root centreon_status > /tmp/backup_centreon_status.sql
    mysqldump -u root centreon_storage > /tmp/backup_centreon_storage.sql
    mysqldump -u root mysql > /tmp/backup_mysql.sql

    Restore:

    copy old files to new servers

    +

    # /etc/init.d/centstorage stop
    # mysql
    mysql> drop database centreon;
    mysql> drop database centreon_storage;
    mysql> CREATE database centreon;
    mysql> CREATE database centreon_storage;
    mysql> GRANT ALL ON centreon.* TO 'centreon'@'adresseipserveurcentreon' IDENTIFIED BY 'password' ;
    mysql> GRANT ALL ON centreon_storage.* TO 'centreon'@'adresseipserveurcentreon' IDENTIFIED BY 'password' ;
    mysql> exit;
    # gzip -d AAAA-MM-JJ-centreon.sql.gz
    # mysql centreon < AAAA-MM-JJ-centreon.sql
    # gzip -d AAAA-MM-JJ-centreon_storage.sql.gz
    # mysql centreon_storage < AAAA-MM-JJ-centreon_storage.sql
    # /etc/centstorage start

    When I want restart Centreon I have this error:

    Preparing environment... OK
    Generating files... NOK (Exception received : SQLSTATE[42S22]: Column not found: 1054 Unknown column 'host_recovery_notification_delay' in 'field list' [file: /usr/share/centreon/www/class/config-generate/host.class.php] [line: 217] )
    Aborted.


    I restart Centreon but always the same problem...
    I am on Centos 6.8.

    Thanks,

    seta
Working...
X