*Purpose

 This page will help you solve problems related to using CSS tools for database restoration (cssrestore or pg_dump).

Restore is a component of CAST AIP that will help you to restore your Cast Storage Service (CSS) databases using the tools cssrestore or pg_dump.

For more information, refer to: CAST Storage Service - Maintenance activities

Online-help - pgadmin:  Help->Help Contents, then enter keyword 'Restore'

*Observed in CAST AIP

 

Release
Yes/No
8.3.x(tick)
*Observed on RDBMS
RDBMS
Yes/No
CSS (tick)
Action Plan
  1. For restoration of dump files:

    1. For *.cssdmp files (files generated from CSSbackup) :Please see the official documentation: CAST Storage Service - Maintenance activities

    2. For other files than *.cssdmp (normally backup files from pgadmin or pg_restore, also if this is a text format backup then you should consult this page as well: CSS Tools - Restore - Non Fatal Error - The input file seems to be a backup in text format):

      1. Before running any command, make sure that the schema does not exist yet.

        1. You can see what the schema being restored is named with the pg_restore command below on the postgres dump:

          1. C:\Program Files (x86)\CAST\CASTStorageService\bin\pg_restore.exe -l "<path to the folder>\file.backup" >%temp%\metadata_file.txt

        2. Open %temp%\metadata_file.txt, search for schema name and compare it with existing schemas on the server.

        3. If the schema currently exists on the server, then you would either need to rename it to a new unique name or you would have to delete it.

          1. To rename, you can use the command in pgadmin "alter schema <schema_name> rename to <new_schema_name>;".

          2. To delete, you can use the command in pgadmin "drop schema <schema_name> cascade;"

        4. If you don't drop or rename the current schema, when you restore the schema it will append the data to what is currently there in the existing schema, effectively corrupting the schema with data duplications.

      2. To restore using the command prompt and the postgres utility pg_restore:

        1. Run the command:

          1. C:\Program Files (x86)\CAST\CASTStorageService\bin\pg_restore.exe --host localhost --port 2278 --username "operator" --dbname postgres --schema "<schema_name>" --verbose "<path to the folder>\file.backup"

        2. Rename the schema if so desired with "alter schema <schema_name> rename to <new_schema_name>;"

      3. To restore using PGAdmin:

        1. Open PGadmin, connect to the server, then on the database level of 'postgres', right-click and select the restore option, then select the provided .backup file and any other options

  1. For other problems with restoration on CSS, select the section you are interested in:
  2. If you do not find the information you are looking for or a solution for your problem, in this page, contact CAST Technical Support and provide the below relevant input to help CAST Support team investigate your problem or procure the required information.

Relevant input

  • For any graphical output or operations, please provide screenshots with clear view of the entire screen so that we may understand the problem better
  • For command line operations, please provide the entire command line you are using so that we can see all the options you are using
  • The logfiles from the operation you were performing (see the section 'Check the logs to see the messages and possible errors' for more details on this)
Notes/comments


Related Pages