Printer FriendlyEmail Article Link

iTest: How to setup an external database (MySQL) for storing iTest Test Reports

Objective/Summary
  • We can store iTest test reports in a centralized external database (instead of the built-in Database). The external database can be any JDBC-compliant database.
  • Spirent has tested this feature only with MySQL. It should be possible, however, to use other Database servers like MS SqlServer, Oracle, PostGreSql, or Derby.

 

Environment/Versions
  • iTest
  • MySQL Server
Procedure

 Install MySQL server on a workstation or a server (See the MySQL documentation for MySQL server installation instructions)

Spirent recommends at least 2GB of memory and 500 GB of disk space for a server handling a team of 20 users. You may use less or more disk space based on the rate and size of reports.

 

 

To support iTest, perform the following changes to the ‘my.cnf’ file located in the MySQL server

 

Maximum size of a table recordThe MySQL server limit on the size of a table record being transferred from an SQL client (iTest) to the server is 4 MB. Because each step in an iTest test report is a record in a table on the server, you will need to set this size based on the maximum size of a response for a step that you expect in your test cases. We recommend setting this to 32 MB because the default of 4 MB may not be enough for general use. Add the following line to the [mysql] section:

 

 max_allowed_packet = 32M

 

 

 

Text encoding: By default, MySQL server uses the default encoding of the host computer. iTest sends data in UTF8 format, so add following lines to the [mysql] section:

 

default-character-set = utf8

 

character-set-server = utf8

 

 
Non-local users: By default, MySQL server provides access to local users only, that is, it binds itself to “localhost”. Change the bind-address parameter setting so that users from other computers can connect to the server: 

bind-address = <server's_external_ip_address>

 

 

Connections: Increase the number of db connections to around 10,000. (RoT: use 10 connections per instance of iTest) 

 

 max_connections=10000 

 


Restart the MySQL server

 

 

Create a database for test reports on the server and source the iTest schema files

 

To create the database, you can use either the MySQL command line application or MySQL Administrator.

 

The MySqlSchema.sql file mentioned in these instructions appears in the iTest Download section of CSC portal. Please make sure to download and save this file in system where MySQL server is installed.
Start the program using the userID of the administrator that you created while installing the database server. If you are using MySQL command line, submit the following commands:

 

 Commands 1 and 2 create the database:

 

 

1> create database reports;

 

 

2> use reports;

 

  Command 3 allows you to create a login and password pair to be used by iTest to connect to this database. You may want to read about how MySQL credentials are managed in order to have a fully secure database server.

 

 

3> grant all on * to 'some_user'@'%' identified by 'some_password';

 

  Command 4 and 5 creates all tables and indices required by iTest. Latest schema file can be downloaded from our support site @ http://support.spirentcom.com.

 

 

4> source MySqlSchema.sql

 

5> source MySqlUpdate.sql

 

 

Configure iTest to save reports to the external database

 

These instructions apply for MySQL only. For instructions for other database servers, see the online help topic on “Configuring iTest to save test reports to an external database”. 

 

1. Install iTest on a client computer. 

 

2. Start iTest and click Window > Preferences. 

 

3. On the Preferences page, in the Spirent group, navigate to General > Test Reports > Test Report Database. 

 

4. Select Use an external database to store test reports and then specify the following settings. 

 

Database type                                                   -      MySQL 

 

Database server address / Host                    -      Specify the hostname or IP address of the database server. 

 

Database server port Number                       -      Leave the port number as 0 — iTest will use the default TCP port to connect to MySQL server 

 

                                                                                   Change the port number only if you have changed the default port on the server. 

 

Database/Catalog name/SID                           -      Type reports (or the name that you used in the create database command)

 

User ID                                                              -       Type the username that you specified in the grant all command. 

 

Password                                                          -       Type the password that you specified in the grant all command.   

 

JDBC connection string                                 -       Do not change

Driver class                                                      -       Do not change

5. To save and apply the settings, click OK and then exit and restart iTest.

 

Verify iTest connectivity to the server

 

On the Test Report Database page, click Test Connection. If you connect successfully, iTest is ready to save test reports to the database. To read more about test reports, consult the iTest online help.

 

If you get a failure dialog, modify server settings based on the error message until the connection is successful. Some common errors are: 

 

•          The database server is not listening on the correct IP address 

•          The database catalog name is not correct

•          Credentials are not correct

Notes

 

 

Attachments
Attachment

Attachment


Product : Velocity Portfolio,Velocity iTest