HighGo Database Integration Guide

HAP Server uses MySQL as its default relational database. Since v5.4.3, it also supports Xugu. For environments with domestic technology requirements, you can use this database instead of MySQL.
Follow these integration steps:
-
Deploy HighGo Security Edition V4.5 in standalone or cluster mode (enable MySQL compatibility mode).
For HAP standalone deployments or simplified clusters, choose standalone mode. For standard or professional clusters, choose cluster mode.
-
After deploying HighGo, download the HAP database initialization scripts and upload them to the HighGo environment.
-
Initialize the data
Connect to HighGo using psql. See the psql User Guide. The ksql command is available after deploying HighGo.
Run the initialization scripts (adjust the IP address, port, username and SQL file paths for your environment). Enter the password when prompted.
psql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/1_Database_g.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/1_Database_s.sql -d mdprojectpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/1_Database_s.sql -d mdapplicationpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/1_Database_s.sql -d mdcalendarpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/1_Database_s.sql -d mdstructurepsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/1_Database_s.sql -d mdlogpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/2_MDProject.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/3_MDStructure.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/4_MDApplication.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/5_MDCalendar.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/6_MDLog.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/7_Data_MDProject.sqlpsql -h 127.0.0.1 -p 5866 -U sysdba -f /usr/local/init_highgo/8_Data_MDApplication.sql -
Initialize HAP services
Before initializing services, add the following environment variables (replace connection parameter values with actual values):
ENV_RDB_TYPE: "6"ENV_RDB_URI_MDPROJECT: "Server=127.0.0.1;Port=5866;User Id=sysdba;Password=******;Database=mdproject;"ENV_RDB_URI_MDLOG: "Server=127.0.0.1;Port=5866;User Id=sysdba;Password=******;Database=mdlog;"ENV_RDB_URI_MDSTRUCTURE: "Server=127.0.0.1;Port=5866;User Id=sysdba;Password=******;Database=mdstructure;"ENV_RDB_URI_MDCALENDAR: "Server=127.0.0.1;Port=5866;User Id=sysdba;Password=******;Database=mdcalendar;"ENV_RDB_URI_MDAPPLICATION: "Server=127.0.0.1;Port=5866;User Id=sysdba;Password=******;Database=mdapplication;"ENV_STANDALONE_DISABLE_SERVICES: "mysql" -
Complete the remaining system initialization steps.