Migrating the database and services to new servers
Who is this article for?
IT Administrators migrating the application to new servers.
No special access or permissions are required.
It can be necessary to move the back end to new servers, for example if moving to a new version of Windows server.
This article provides a checklist of steps to take and a worked example.
1. Preparation
1.1. Assumptions
This guide assumes:
- You have a working Internal Audit system (with or without Retain).
- You can use App Manager.
- You have admin access to your IIS server and permission to restore databases and add logins on SQL Server.
- The new application URL is different from the old one.
- Both new and old servers are in the same Windows domain.
- You are using the same application version.
1.2. Prerequisites
Before beginning the migration, ensure the following is in place:
- IIS and required modules are installed on the application server (as per the install guide).
- SQL Server is installed on the database server.
- Infrastructure updates are complete (URLs whitelisted, antivirus exceptions set).
- App Manager instances are set up and accessible.
- All users have checked in their data (no audits or documents are reserved).
- All client applications have been closed by users.
1.3. Process overview
To summarise, the process involves:
- gathering information about the current system.
- migrating the data and setting up an app instance in test.
- verifying the test system is working.
- reproducing the migration/install steps for the live system.
2. Gathering information
Before starting the migration, collect the following information from the existing system:
2.1. Service configuration
- Open IIS Manager on the old application server
- For each service (Service, FBA, Web Service, WebUI, and optional API and SamlMvc), check the advanced settings to identify which application pool is in use
- Navigate to Application Pools and check the identity for each app pool in use
- Record the service account usernames (e.g., domain\PentanaService)
2.2. Robot service configuration
- Open Services (services.msc)
- Locate the Pentana Robot service
- Note the "Log On As" account being used
2.3. Database connection
- Launch App Manager Config tab, select the Service tab
- Check the service configuration to verify the connection string
- Note whether integrated security or a SQL Server account is being used
2.4. Authentication method
If you don’t already know the authentication methods used by the desktop client and WebUI, you can check using these steps:
2.4.1. Desktop client
- In the App Manager Config tab, select the Client tab.
- Check the configSections area
- If Pentana.TNG.ServiceInspectors section is not present: Windows authentication is in use
- If Pentana.TNG.ServiceInspectors section is present: Check for the forgot password link section key
- If not active: Single Sign-On via SAML is in use
- If active: FBA is in use
2.4.2. WebUI
- Open the WebUI configuration file
- Look for the pentana.TNG.UI.Web.FBA section
- Check if useSSO is commented out or active
- If commented out: FBA is in use
- If active: Single Sign-On via SAML is in use
- If FBA section is missing entirely: Windows authentication is in use
2.5. File attachments storage
File attachments are almost always stored in the database, but check:
- In the App Manager Config tab, select the Service tab.
- Look for the file storage path section Pentana.Tng.UI.FileService
- Normally the PhysicalPath key is commented out, and this means that all of the file data is held in the database.
- If the PhysicalPath key is in use and has a UNC path specified, then the attachments are stored at that path and may need migrating too.
2.6. Mail server settings
- In the App Manager Config tab, select the Service tab.
- Record mail server settings from the FBA section at the top
- Check for a system.net section (usually at the end) for complex mail configurations
- Repeat this check in Robot, FBA, and WebUI tabs
2.7. Password rules
- Check the App Manager Service, FBA, WebService, and WebUI tabs
- Look for the Pentana.TNG.UI.Web.FBA section
- Note any custom password rules that differ from defaults
2.8. Retain synchronization
- Navigate to the Robot tab in App Manager
- Connect to the robot service
- Check if Retain synchronization is enabled (boxes will be ticked if in use)
If Retain is used then there may be work to do to migrate Retain. That is outside the scope of this article, please contact Support for further guidance.
2.9. Client Deployment Method
- On a client PC, launch the application
- Open Task Manager
- Locate the running Pentana client process (right click on the process and Open file location)
- Check the folder path:
- If it is some obscure path like \AppData\Local\Apps\2.0\[random text] then the client is installed using ClickOnce
- If the path is Program Files: MSI or other deployment method is used
3. Taking old system offline
- Ensure your users have any checked out work or reserved documents checked in
- Close App Manager
- Verify the message queue is empty
- Stop the Robot service and set it to Disabled
- If Retain is in use, stop the Retain services
- Stop all Pentana application pools in IIS Manager
4. Migrating the database
4.1. Preparation and backup
- Connect to the old database server
- Back up the Pentana database
- Take the old database offline to prevent any data changes
4.3. Restoring on new server
- Copy the backup file to the new database server
- Restore the database from the backup file
- Verify the correct login is in place, and that it is mapped to the user in the database
5. Setting up application server
5.1. Transfering installation files
- On the old application server, locate the folder containing:
- App Manager instances
- Installation files
- Any custom DLLs / a CustomerFiles folder
- Zip the entire folder
- Transfer to the new application server
- Unzip the files
5.2. Configuring App Manager
- Launch App Manager on the new server
- When prompted, browse to the transferred App Manager instances folder
- Select the appropriate instance (UAT or Production)
- Check the Install Files section is pointing to the correct path for the installation set
- Update all configuration pointing to old locations. Expand each section in turn and update relevant text:
5.2.1. Variables
- Expand the configuration variables section
- Update the SQL server instance name
- Update the site address
- Update the help URLs
- Review machine keys (can keep the same for convenience or change per installation guide)
5.2.2. Main service
- In the Main Service section, update the main service connection string
- Update the authentication database connection string
- Update the WebUI connection string
5.2.3. WebUI
- Update the authentication database connection string
5.3. Saving and reconnecting
- Save the configuration
- Close and reopen App Manager to establish connection to the new database
- Verify the connection indicator shows green
5.4. Setting up message queue
- Open Computer Management
- Navigate to Message Queuing
- Create a new private queue with an appropriate name (e.g., PentanaUAT). Ensure Transactional is ticked
- Set permissions:
- Grant the Pentana service user full control
- Grant the Pentana Robot user full control
5.5. Installing components
In App Manager, go to the Config tab:
- In the Main Service section, click Install
- Go to the Robot section and Install
- Go to the Web Application section and Install
- Go to the Client section, and Install
5.6. Configuring IIS application pools
- Open IIS Manager
- Locate the Pentana application pools created by App Manager
- For each Pentana application pool, change the identity to the correct service account
5.7. Configuring Robot service
- Open Services (services.msc)
- Locate the Pentana Robot service
- Change the "Log On As" account to the correct robot service account
- Set startup type to "Automatic (Delayed Start)"
5.8. Setting folder permissions
5.8.1. Robot service folder
- Navigate to C:\Program Files (x86)\[Robot folder]
- Grant the robot service account Modify permissions (for log file writing)
5.9. Web service folders
- Navigate to C:\inetpub\wwwroot\[Pentana UAT instance]
- For each service folder (Service, WebService, WebUI), grant the Pentana service account Modify permissions (for log file writing)
5.10. Copying additional files
5.10.1. License file
- On the old server, navigate to c:\inetpub\wwwroot\[pentana instance]\Service.
- Copy the license file.
- On the new server, paste it into the service folder.
5.10.2. Help files
- On the old server, locate the Help and Web Help folders.
- Copy both folders.
- On the new server, paste them into the matching location.
5.11. Configuring authentication
The default configuration uses:
- Windows authentication for desktop client
- FBA for WebUI
If using SAML or different authentication methods, update configurations according to the documentation at this stage.
5.12. Configuring message queue
- In App Manager, navigate to the Config > Service tab.
- Locate the section <Pentana.Tng.Notification> (will be commented out by default).
- Remove the comment markers.
- Update the queue name to match your queue (e.g., replace visionqueue with PentanaUAT).
- Save the configuration.
5.13. Configuring additional elements
If needed, configure:
- Additional password requirements
- Complex mail server configurations
- File store configurations
5.14 Configuring SSO via SAML (Optional)
5.14.1. Desktop
If your desktop client authenticates using SSO via SAML:
- Go to the old server.
- Navigate to c:\inetpub\wwwroot\[pentana instance].
- Copy the folder SamlMvc.
- Paste to the corresponding location in the new server.
- In IIS Manager, convert the new folder to application, and ensure the correct app pool is specified.
- In App Manager, in the Config > Service tab, locate the section <Pentana.Tng.Service>.
- Uncomment the key UseSAMLAuthentication.
This brings across all the certificates and most config settings.
You will also need to update the client config file vision.exe.config.
5.14.2. WebUI
If your WebUI authenticates using SSO via SAML:
- Go to the old server.
- Navigate to c:\inetpub\wwwroot\[pentana instance]\WebUI.
- Copy the folder Certificates.
- Paste to the corresponding location in the new server.
- In App Manager, in the Config > WebUI tab, locate the section <Pentana.Tng.UI.Web.Vision>.
- Uncomment that section.
You will also need to change your Idp where it references the app server URLs.
5.15. Moving API (Optional)
If you are moving the API to the new server:
- Go to the old server.
- Copy the API and any secondary ServiceAPI folder.
- Paste to the corresponding location on the new server.
- In IIS Manager, convert the new folder(s) to application, and ensure the correct app pool is specified.
- Open API\Web.config in Notepad and update the connection string and site address values.
- Save.
- Open ServiceAPI\Web.config (if present) and update the connection strings and site address values.
- Save.
- Open Edge.
- Open the following URL: https://server.domain.com/[pentana instance]/API/auth/ResetKeys.
- Then, open https://server.domain.com/[pentana instance]/API/auth/GetPublicKey.
This copies across all configuration, and creates the certificates required by the API service.
6. Testing and validation
6.1. Testing service connectivity
From a client PC, browse to the service endpoint, e.g. URL https://server.domain.com/PentanaUAT/Service/TngService.svc.
This verifies that the service is running and can connected to the database.
6.2. Starting Robot service
On the application server, start the Robot service and verify it starts without errors.
6.3. Testing Desktop client
From a client PC:
- Navigate to the client URL
- If an old client is installed, uninstall it via Add/Remove Programs
- Install the new client. If you are using ClickOnce, the URL will be like https://server.domain.com/PentanaUAT/Client.
- Launch the client, verify it opens successfully and that you can login
- Test the help pages by clicking Help
- Test mail server connectivity by e.g. triggering a password reset email (right-click a user, select Add FBI Identity, Reset Password)
- Have real users log in from their locations to verify access
6.4. Testing WebUI
From any device:
- Navigate to the WebUI URL (e.g. https://server.domain.com/PentanaUAT/WebUI).
- Log in with valid credentials.
- Verify the help links work correctly.
6.5. Testing optional components
If applicable, verify:
- API functionality
- Excel Importer functionality
7. Go-live
When you're ready for go live:
- Schedule the production migration.
- Repeat all steps for the production environment.
- If specifying different application names between old and new installations, client reinstallation will not be necessary.
Considerations:
- Always take the old database offline after backup to prevent accidental data additions
- Keep the same folder paths between servers when possible to minimize configuration changes
- This process assumes you're maintaining the same application version
8. Walkthrough
Each of the links below shows you a video demonstration of each of the steps described above: