Search Engine: Elastic

Article ID: 130860, created on May 23, 2017, last review on May 7, 2018

  • Applies to:
  • Operations Automation 7.0
  • Operations Automation 7.1
  • Operations Automation 7.2


An Odin Automation Management Node oss database dump was created with pg_dump or pg_dumpall utility.

When it gets restored with pg_restore, the process takes unreasonably huge amount of time (up to few days), depending on the amount of records in aps_resource_link table.


Since OA 7.0, there is an additional integrity check that verifies APS resource links consistency upon their modification. This check slows down the database restoration greatly.


Use the following SQL query before backing up oss database:

INSERT INTO aps_disable_link_check_consistency VALUES (1);

Once the dump is created, delete the entry:

DELETE FROM aps_disable_link_check_consistency;

This will increase the speed of database restoration.

Alternatively, if the database backup operations are performed several times a day and it is not acceptable to disable consistency checks so frequently, it is possible to create the table before performing the restoration.

The action sequence is:

  1. Manually drop and recreate the database:

  2. Create the table:

    CREATE UNLOGGED TABLE aps_disable_link_check_consistency (
        pk integer NOT NULL
    ALTER TABLE public.aps_disable_link_check_consistency OWNER TO oss;
    INSERT INTO aps_disable_link_check_consistency VALUES (1);
  3. Restore the dump without '-Fc' option:

    # pg_restore -j 8 --disable-triggers -d oss osscore.dump

5356b422f65bdad1c3e9edca5d74a1ae caea8340e2d186a540518d08602aa065 e12cea1d47a3125d335d68e6d4e15e07 0871c0b47b3b86ae3b1af4c2942cd0ce 1941880841f714e458ae4dc3d9f3062d 31987597efff5a3a9ce779cc203bbe5e 8c199f0ee4305da1a577740620df4a51

Email subscription for changes to this article
Save as PDF