You can modify the JDBC connection URL parameters in Omnissa Access to update the database server hostname, port number, or database name. This is typically required when migrating to a new database server, changing database ports for security compliance, or updating database configurations.
Prerequisites
- Root access to the Omnissa Access appliance.
- The new database connection parameters, such as hostname, port, and database name.
- Database server accessibility from the Omnissa Access appliance on the new port
Understanding the JDBC URL Structure
The JDBC URL string in Omnissa Access follows the format specific to your database type:
Microsoft SQL Server
jdbc:sqlserver://hostname:port;databaseName=database_name
PostgreSQL
jdbc:postgresql://hostname:port/database_name
Connection Parameter Locations
- hostname: The FQDN or IP address of your database server
- port: The TCP port number
- Default is 1433 for SQL Server.
- Default is 5432 for PostgreSQL.
- database_name: The name of the Omnissa Access database
Example JDBC URLs
- SQL Server with custom port:
jdbc:sqlserver://dbserver.example.com:14330;databaseName=saasdb - PostgreSQL with default port:
jdbc:postgresql://dbserver.example.com:5432/saasdb
Procedure
-
Using an SSH client, log in to the Omnissa Access appliance as the root user.
-
(Optional) Verify database connectivity before making changes:
/usr/local/horizon/bin/dbConnCheck '<jdbc_url>' '<db_username>' '<encrypted_password>'Where:
<jdbc_url>is your current JDBC connection string from the runtime-config.properties file.<db_username>is your database username (typicallyhorizon).<encrypted_password>is the encrypted password from thesecure.datastore.jdbc.passwordparameter.
A successful connection displays:SUCCESS: Connection verified.
-
Open the runtime configuration file for editing.
For example:vi /usr/local/horizon/conf/runtime-config.properties -
Locate the JDBC URL parameter.
The parameter name varies by database type:- For the main datastore:
datastore.jdbc.url= - For the SAAS datastore:
saas.datastore.jdbc.url=
- For the main datastore:
-
Modify the JDBC URL string to update the connection parameters:
- To change the port number:
- Locate the port number after the hostname (Example
:1433). - Replace with your new port number (Example
:14330).
- Locate the port number after the hostname (Example
- To change the hostname:
- Replace the hostname portion with the new server FQDN or IP address.
- Replace the hostname portion with the new server FQDN or IP address.
- To change the database name, update the appropriate database name, as such:
- SQL Server: the
databaseName=parameter - PostgreSQL: the database name after the final
/
Example of Change:
From:
- SQL Server: the
datastore.jdbc.url=jdbc:sqlserver://oldserver.example.com:1433;databaseName=saasdbTo:
datastore.jdbc.url=jdbc:sqlserver://newserver.example.com:14330;databaseName=saasdb - To change the port number:
-
Verify that the complete JDBC URL is correct, including the following details:
- Protocol prefix (
jdbc:sqlserver://orjdbc:postgresql://) - Correct hostname or IP address
- Correct port number
- Correct database name
- Proper syntax for your database type
- Protocol prefix (
-
If you're also changing the database password, update the password parameter in the same file:
secure.datastore.jdbc.password=encrypted_passwordNote: See Manually Update External Database Password and Update the JDBC Password Property in Omnissa Access for password encryption instructions.
-
Save the
runtime-config.propertiesfile. -
Before restarting, verify network connectivity to the new database server and port:
telnet new_hostname new_port_numberOr:
nc -zv new_hostname new_port_number -
Restart the Omnissa Access service to apply changes:
service horizon-workspace restart
-
Verify the service starts successfully by checking the service status:
service horizon-workspace status -
Monitor the log files for any connection errors:
tail -f /opt/vmware/horizon/workspace/logs/horizon.log -
For clustered deployments, repeat all the preceding steps in this procedure on all nodes in your Omnissa Access cluster.
Verification
- Log in to the Omnissa Access admin console.
- Navigate to the Dashboard to verify system health.
- Confirm that database connectivity is working properly.
- Test user authentication and resource access.
Troubleshooting
If the service fails to start after making changes:
- Verify the JDBC URL syntax is correct for your database type.
- Confirm firewall rules allow connectivity on the new port.
- Check that the database server is listening on the specified port.
- Review
/opt/vmware/horizon/workspace/logs/horizon.logfor specific error messages. - Verify database credentials are still valid.
Related Topics
Questa pagina è stata utile?