If you wish to use a MySQL server installed locally rather than using the default Built-In database then you should install and configure the MySQL database prior to installing and Configuring Hypersocket. If you are using Windows then you'll need to download and install MySQL, go to http://dev.mysql.com/downloads/ and download the MySQL database that works best for you.
During the installation you must select the type of SQL server to install, the minimum requirement is SQL Server level, for the easiest configuration you will also want to install the SQL Workbench.
During installation you'll need to set the password for the root user, after this you can then create a new user, name the new user hypersocket and set its password to the same. Complete the installation.
MySQL should now be running as a Windows service, open the Workbench client and login with the root user enter the password set for the root user.
In the Query field enter the following three lines and then execute the arguments:
create database hypersocket; grant all privileges on hypersocket.* to hypersocket@localhost identified by 'hypersocket'; flush privileges;
The Hypersocket table has now been created, now install Hypersocket.
For a Windows installation the user will automatically be prompted to setup their database as one of the final parts of the configuration. The user must set Hypersocket's operational ports and then the database to be used, here they will be able to select the MySQL option and then provide the hostname and port of the server, the database name, and authentication details, if you followed the earlier example these would be:
Hostname – localhost Port – 3306 Database – hypersocket Username – hypersocket Password - hypersocket
Finishing this configuration will complete the installation and you will be able to start the Hypersocket service.
If you are having difficult with the Installer, or do not wish run it you can also manually change the configuration files to set the database in use. After installation completes and before the service is started you will need to go to the Hypersocket conf directory. Open the database.properties file as root in order to edit the content.
Delete the existing contents of the file and enter the following replacing the 5 variable entries with the relevant details for the MySQL server,
jdbc.driver.className=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql://${installer:databaseHost}:${installer:databasePort}/$installer:databaseName}?autoReconnectForPools=true&useUnicode=true&characterEncoding=UTF-8 jdbc.username=${installer:databaseUser} jdbc.password=${installer:databasePassword} jdbc.hiberate.dialect=org.hibernate.dialect.MySQLDialect
The file will contain a number of placeholder values that need to be updated, each of these entries will need to be changed to use the actual details of the SQL database that Hypersocket will connect to:
If you used the earlier example then the text should now look like this:
jdbc.driver.className=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql://localhost:3306/hypersocket?autoReconnectForPools=true&useUnicode=true&characterEncoding=UTF-8 jdbc.username=hypersocket jdbc.password=hypersocket jdbc.hiberate.dialect=org.hibernate.dialect.MySQLDialect
Save the changes to the file and start the service, Hypersocket should now begin using the MySQL database.