VirtServer uses a separate installation package from ReadyAPI. You can install it on Windows, Linux and macOS. The ways to install the product on these operating systems are very similar. There are differences in installing the product on Linux headless (GUIless) machines. This topic provides detailed information on installation steps for both cases.
Before installing
To run VirtServer, your computer must meet certain system requirements.
Also, you will need either a VirtServer trial license or a commercial VirtServer license. To get a license, contact your sales representative or write to sales@smartbear.com.
You install a license during the first VirtServer run.
Installing VirtServer With the Installation Wizard (Typical)
Follow these steps:
-
Download the VirtServer installer for your platform (Windows, Linux or macOS, 32- or 64-bit) from the SmartBear web site.
Note: If you use Linux, check that the installer has correct permissions and is executable. -
Run the downloaded installation package.
-
Follow the installation wizard instructions:
-
Specify the installation directory. If you are upgrading to 3.13.0, we recommend installing VirtServer into a new folder location and manually deleting the folder for the previous version. We do this to enable a cleaner installation and to avoid possible issues following our recent upgrades to Java 17.0.4.
-
On one of the steps, the wizard will ask you to select additional components to be installed:
-
-
After selecting the desired components, click Finish to finish the installation.
-
If you prefer running the installer in unattended mode
-q
, you can configure using system properties-Dservice.install
and-Dservice.autostart
. See examples:-
VirtServer-x64-3.14.0-SNAPSHOT.sh -q -Dservice.install=true
will install the service, requires that the user is root. -
VirtServer-x64-3.14.0-SNAPSHOT.sh -q -Dservice.autostart=true
will install the service and configure it to autostart when the operating system boots.
-
After Installation Is Over
After the installation is over, run VirtServer, create a user on it and activate the VirtServer license. These actions are rather simple. Just follow the instructions you will see on the screen.
After installing VirtServer, you may want to replace the SSL certificates it uses or change the VirtServer port number.
![]() |
VirtServer stores all the information (added virtual services, users, and so on) in a database file. We recommend that you periodically back up that database file. |
How to schedule creating a backup
Windows
-
Create a .bat script file that copies the database file:
copy /Y %HOMEPATH%\.readyapi\virt-server\virt-server.h2.h2.db <Path to the backup folder>
-
Open Task Scheduler and click Create Basic Task from the right toolbar:
-
In the subsequent dialog, specify the name and description of the task. Click Next.
-
At the Trigger step, specify when you want to back up the database. For example, to back it up once a week, select Weekly and select a day on which you want to copy the file:
-
At the Action step, select Start a program and click Next.
-
At the next step, in the Program/Script field, specify the path to the created script. Click Next:
Linux/macOS
-
Create an .sh script file that copies the database file:
cp ~/.readyapi/virt-server/virt-server.h2.h2.db <Path to the backup file> -
Open the terminal and enter the following command:
crontab -eIt opens the text editor where you can schedule a task.
-
At the end of the file, specify the line that commands cron to execute the created script. For example, to perform a backup each Friday, you could specify the following line:
0 0 * * 5 <Path to your script>To learn more about the cron syntax, you can see the Ubuntu documentation.
Upgrading VirtServer
When upgrading or resinstalling VirtServer, please follow the same steps as defined above for installation. We recommend you perform a backup of your database using the steps defined below before you upgrade. This is a precautionary step. If you are upgrading VirtServer on the same machine as the original installation and have a license activated, this should be picked up when you restart VirtServer.
Installing on Docker and Kubernetes
For users deploying VirtServer in Docker, please refer to the following page for guidance.
SmartBear have also launched a HelmChart for Kubernetes deployment. This is a starting point for running VirtServer in Kubernetes utilizing helm charts. User may need to modify it to their needs.
Installing on Headless Machines
-
Download the VirtServer installer from the SmartBear web site.
-
Make sure the installer has appropriate permissions for execution. You can use ‘chmod’ for linux.
-
Run the installer with the
-c
argument in its command line. Here is an example for running a 64-bit installer of VirtServer 3.14.0:sh VirtServer-x64-3.14.0.sh -cNote: On Windows computers, use the following command: start /wait VirtServer-x64-3.14.0.exe -c
The installer will unpack files and then will continue the installation in the command-line mode.
-
The installer will ask you to perform the same actions that you perform in the GUI installer: specify the installation folder, choose the components to be installed, and so on. Follow the instructions you will see on the screen.
-
After the installation is over, run VirtServer, create a user, and activate the license (see above).
An alternative approach is to download the Platform Independent zip and extract files from it manually. However, in this case, you may have to install latest versions of JDBC drivers and Java. Please contact support if you require assistance.