White paper Backing Up and Restoring HP Systems Insight Manager 7.2 or Greater Data Files in an HP-UX and Linux Environment HP Systems Insight Manager 7.
White paper | HP Systems Insight Manager 7.2 Table of Contents Introduction .................................................................................... 3 Backing up and restoring data files for a PostgreSQL database ............ 4 Backing up data files for a PostgreSQL database .............................................. 4 Restoring data files for use with PostgreSQL ..................................................... 6 Backing up and restoring data files for an Oracle database .............
White paper | HP Systems Insight Manager 7.2 Introduction HP Systems Insight Manager (Systems Insight Manager) uses a PostgreSQL server database to store collected information about the systems on your network. Always back up your database using an appropriate backup schedule. In the event of a catastrophic database problem, this backup can be restored to return Systems Insight Manager to operation.
White paper | HP Systems Insight Manager 7.2 Backing up and restoring data files for a PostgreSQL database Backing up data files for a PostgreSQL database Backing up the database with PostgreSQL requires changing the Systems Insight Manager database user password and saving the database and associated files. 1. If Systems Insight Manager is running, enter mxstop in the command line to stop the Systems Insight Manager daemons. 2.
White paper | HP Systems Insight Manager 7.2 Note: The file permissions must be prepared during the backup process. The tape archive (tar) utility preserves file permissions. 4. Save any existing user-supplied (custom) files contained in the Systems Insight Manager directory tree, such as tool definition files (TDEFs), Management Information Base files (MIBs), login prompt, and actions. 5. Open the /etc/opt/mx/config/database.props file and check the property value for hp.Database.username.
White paper | HP Systems Insight Manager 7.2 -p = Port number To find the port number, open the /etc/opt/mx/config/database.props file and find the property value for the hp.Database.portNumber property. insight_v1_0 = Systems Insight Manager database name To find the database name, open the /etc/opt/mx/config/database.props file and find the property value for the hp.Database.databaseName property. saveHPSIMdb = Any file name to save the database 9.
White paper | HP Systems Insight Manager 7.2 4. For Linux systems: a. To verify that the postmaster is running, enter the following command: ps –ef | grep postmaster If the postmaster is running, stop the service by entering the following command: kill -9 b. Uninstall hpsmdb by entering the following: rpm –qa | grep hpsmdb| xargs rpm –e rm –rf /opt/hpsmdb /var/opt/hpsmdb c.
White paper | HP Systems Insight Manager 7.2 7. Create a user named mxadmin by entering the following command: ./createuser –h 127.0.0.1 –p 50006 –U hpsmdb mxadmin Note: For the mxadmin user, set the role to superuser without permission to create databases and user accounts. 8. Copy the database named insight_v1_0 by entering the following command: For HP-UX: cd /opt/hpsmdb/pgsql/bin ./psql –q –h 127.0.0.1 –U mxadmin –p 50006 –f /tmp/saveHPSIMdb –d insight_v1_0 For Linux: cd /opt/hpsmdb/bin .
White paper | HP Systems Insight Manager 7.2 Note: To move HP Systems Insight Manager data from one Linux operating system to another, use the same steps listed above with the following command: scp Linuxsys1 (data file and configuration files) Linuxsys2:/path To restore HP Systems Insight Manager data on a different LINUX operating system, follow the restore procedure in this section.
White paper | HP Systems Insight Manager 7.2 Backing up and restoring data files for an Oracle database The following procedures describe saving (backing up) and restoring data files for a system using an Oracle database that is using Systems Insight Manager. Important: Only a user with Oracle Database Administration (DBA) privileges can conduct the backup and restore procedures. Saving data files for use with Oracle 1.
White paper | HP Systems Insight Manager 7.2 Note: The file permissions must be prepared during the backup process. The tape archive (tar) utility preserves file permissions. 4. Save any existing user-supplied (custom) files contained in the Systems Insight Manager directory tree, such as tool definition files (TDEFs), Management Information Base files (MIBs), login prompts, and actions. 5. Open the /etc/opt/mx/config/database.props file and check the property value for hp.Database.username.
White paper | HP Systems Insight Manager 7.2 2. Create a new database using the name of the backed-up database, and then create a user with DBA privileges with the same user credentials that you created in step 6 of Saving data files for use with Oracle. 3. Install Systems Insight Manager as directed in the HP Systems Insight Manager 7.2 Installation and Configuration Guide, which is available at http://www.hp.com/go/insightmanagement/sim/docs (for Linux and HP-UX).
White paper | HP Systems Insight Manager 7.2 9. Restore the database file from the backup created in step 6 of Saving data files for use with Oracle. 10. At the Oracle server console, enter the following command: set ORACLE_SID= Where is the database created in step 2. 11. Create another user (user2) with the same privileges as user1 by entering the following commands at the SQL prompt: Create user user2 identified by passwd; Grant dba, connect to user2 identified by passwd; Commit; 12.
White paper | HP Systems Insight Manager 7.2 Note: The count of tables, indexes, and views should be the same after export and import. 17. Restart Systems Insight Manager by entering mxstart. Systems Insight Manager restarts, and all data from the backup database is restored.
White paper | HP Systems Insight Manager 7.2 For more information Learn more at http://www.hp.com/go/insightmanagement/sim/docs Product information is available at http://h18004.www1.hp.com/products/solutions/insightdynamics/infolibrary.html Sign up for updates hp.com/go/getupdated Share with colleagues Rate this document © Copyright 2010, 2013 Hewlett-Packard Development Company, L.P. The information contained herein is subject to change without notice.