Issue
A Power Monitoring Expert (PME) database may need to be moved to another drive especially if one drive is full.
Product Line
ION Enterprise 5.0/5.5/5.6/6.0
StruxureWare Power Monitoring 7.0.x
Power Monitoring Expert 7.2.x
Power Monitoring Expert 8.x
Power Monitoring Expert 9.0
Power Monitoring Expert 2020
Power Monitoring Expert 2021
Power Monitoring Expert 2022
Power Monitoring Expert 2023
Environment
SQL Server Management Studio
Resolution
*Warning: Irreparable database damage can occur. This procedure should only be performed by users familiar with SQL Server Management Studio. Databases should be backed up prior to performing this procedure.*
Use the following steps to move the databases to the new location.This procedure is applicable to both standalone and distributed installations.
- Take backups of the database(s) that need to be moved
- Open SQL Server Management Studio
- Right-click on the database that needs to be moved, select 'Back Up...' under 'Tasks'
- Inside the Back Up Database window under General confirm the Back up Destination is set to Disk and then select 'Add…'
- Finally, provide a location for the backup and add the name of the back such as 'ION_Data230124.bak'
- Stop all ION Services:
- Open Control Panel
- Select Administrative Tools
- Select Services
- Right-click on the service and choose stop. All PME services start with ION as of PME 9.0. It is best to start with the ION Network Router Service and choose yes when it asks if you would also like to stop its dependencies.
- Services will no longer say Running under the status column once they are stopped.
- Detach the database(s).
- Open SQL Server Management Studio
- Right-click on the database that needs to be moved, select 'Detach...' under 'Tasks'
- From the Detach Database screen select 'Drop Connections' and press 'OK'
- Repeat steps a-c for any other database that needs to be detached.
- Restore the database backup:
- Open SQL Server Management Studio
- Right-click the Databases folder > Restore Database
- In the Restore Database window select Device and click the right-hand box labeled '...' to select the desired backup instance
- Click 'Add' and navigate to the location of the .bak file, then select 'OK'
- The Restore Database window should then be populated similarly to the image below.
- In the 'Select a page' menu on the left choose the 'Files' option
- Inside the Files page check 'Relocate all files to folder' and choose the desired location of the .mdf and .ldf
- Select 'OK' to restore the backup.
- Start the ION Services.
- Go to Control Panel > Administrative Tools > Services
- Right Click the automatic services and any others that are normally used and chosen start.
- Change the scheduled backups and archives to point to a new location by following FA23057