SearchService (EDSS) and Enemy Detection (EDQSS) are optional services requiring certain prerequisites to be in place before they can be configured and installed.
- Setting up the prerequisites for SearchService (EDSS) - Installation of Elasticsearch server
- Setting up the prerequisites for Enemy Detection (EDQSS) - SQL Server database setup for Similarity and Hangfire
Set up the prerequisites for SearchService (EDSS) - Installation of Elasticsearch server
- If not already set, then set the environment variable JAVA_HOME to the Java (JRE) install directory root, which is usually in the form C:\Program Files\Java\jre1.8.0_66 (the trailing numbers depend on the JRE version number).
Download the latest release of Elasticsearch 1.7.2 from https://download.elastic.co/elasticsearch/elasticsearch/elasticsearch-1.7.2.zip.
Extract it to an appropriate folder on your local disk such as D:/Elasticsearch-1.7.2.Want to relocate the Elasticsearch data folder? Click here to learn more...
Navigate to the "bin" subdirectory of this folder.
Locate the above directory in command prompt and run the command “service.bat install” to install Elasticsearch service.
To start the service, either run command “service.bat start”, or locate the service in the Services management console of Windows and start it.
Elasticsearch should now be running on port 9200. Open the ElasticSearch URL http://localhost:9200/.
You will get a response similar to the one above, if your Elasticsearch server is running. You can still proceed further even if you do not see the exact response as above.
Set up the prerequisites for Enemy Detection (EDQSS) - SQL Server database setup for Similarity and Hangfire
Creating new databases for Similarity and Hangfire
Let's see how a new database is created in SQL Server.
Open SQL Server Management Studio and connect to the one being used with ExamDeveloper.Click here to learn how to identify the SQL Server instance to use, when there are many...
- Right-click Database node in Object Explorer and select New Database from the context menu.
- Click the General page and specify the name of the database on the right in the Database name text box. Here, we have specified this as Similarity.
- You may opt to specify a different path for the database files and log files if necessary by clicking the Browse button next to their paths in the Database files listing. This can be done to ensure that there is enough space for the application database on the specified path.
- Click OK to save the database.
- Repeat the above steps to create another database named Hangfire.
The next step is to restore the blank database to Similarity as detailed next.
Restore database files to Similarity
Restore Similarity database with the following steps.
- Extract SimilarityBlankDb.bak from SimilarityBlankDb.7z (this can be obtained by contacting Pearson VUE Tech Support). Use the 7-Zip extraction utility from http://www.7-zip.org/download.html to extract the file to a location such as <SVNFolder>\Database Utility\.
- Right-click Databases in Object Explorer. Click Restore Database from the context menu as shown below.
This opens the Restore Database window.
- In the General page, select Similarity from the To database drop-down of the Destination for restore.
- In Source section of the General page, select Device radio button, and click the Browse button.
- This opens the Specify backup devices window. Click the Add button, browse to select the backup file SimilarityBlankDb.bak located in <SVNFolder>\Database Utility\ as extracted earlier in step 1, and click OK.
- The backup set is added to Backup sets to restore part of the Restore plan section. Ensure that the Restore check box of the backup set is selected. Select Similarity from the Database drop-down of the Destination section.
- Optionally, select the Files page on the left and choose the physical file locations where you would like to restore the database and log files for the Similarity database. This step is optional and can be skipped.
- Select the Options page on the left, and under the Restore options section, select Overwrite the existing database (WITH REPLACE). Click OK.
- You must ensure that the owner of the database is "sa". Open the properties of the Similarity database by right clicking Similarity under Databases and clicking Properties. The Database Properties window opens.
- Select the Files page on the left of the Database Properties window and specify "sa" as the Owner, if that text box is blank. Click OK.
- Click OK.
The next step is to create a user with just enough rights to be able to access the Similarity database for the Enemy Detection feature to function, as detailed next.
SQL Server user management for Similarity and Hangfire
We will create a user having sufficient privileges to use the Similarity database. You can create a new login and assign the required privileges to the user via the following steps:
Start SQL Server Management Studio. You can use SQL Authentication and "sa" account to connect to the server.
Go to Security → Logins, right-click Logins and click New Login as shown below.
Select the General page on the left. Select the SQL Server authentication radio button, enter the Login name and Password, and the same password again in the Confirm password box for confirmation as shown below. (In our example, the username is "Similarity" and password is "P@s$w0rd"). De-select the Enforce password policy check box.
Select the Server Roles page on the left. Select the roles you want to give to the user. Ensure that dbcreator is be selected in order to create the databases (public is selected by default and cannot be deselected).
Click User Mapping tab on the left. Select the Map check box corresponding to the Similarity database. This is used to give individual rights for users for each database. Select the role membership as shown below. The following minimum role memberships are required to use the Simiilarity database from the application: db_datareader, db_datawriter, and dd_ddladmin, ensure that these are selected (public is selected by default and cannot be deselected). Click OK.
- Use the above steps to create a user "Hangfire" with similar access rights for the Hangfire database with access rights: db_datareader, db_datawriter, and dd_ddladmin (the public role is selected by default).
You can use these usernames and passwords to connect to Similarity and Hangfire databases via the Similarity service config files to connect to the databases as detailed next.