Changing the Database Type

For Windows OS

info

The procedure for starting and stopping Dr.Web Server is described in the Administrator Manual, section Starting and Stopping Dr.Web Server.

1.Stop Dr.Web Server.

2.Run drwcsd.exe with the modexecdb database-export switch to export the content of the database to a file. The complete command (for Windows) looks as follows:

"C:\Program Files\DrWeb Server\bin\drwcsd.exe" -home="C:\Program Files\DrWeb Server" -var-root="C:\Program Files\DrWeb Server\var" -verbosity=trace -log="C:\Program Files\DrWeb Server\var\exportdb.log" modexecdb database-export D:\esbase.es

It is assumed that Dr.Web Server is installed in the C:\Program Files\DrWeb Server folder and the database is exported to the esbase.es file , located in the root directory of disc D.

If the path to a file (or a file name) contains spaces or national characters, the path should be put in quotation marks:

"D:\<long name>\esbase.es"

3.Start Dr.Web Server, connect Dr.Web Security Control Center to Dr.Web Server and configure Dr.Web Server to use a different DB. Cancel the prompt to restart Dr.Web Server.

4.Stop Dr.Web Server.

5.Move the database file to a temporary directory until you are sure that changing the database type was successful.

6.Run drwcsd.exe with the modexecdb database-init switch to initialize a new database. The command line will look as follows:

"C:\Program Files\DrWeb Server\bin\drwcsd.exe" -home="C:\Program Files\DrWeb Server" -var-root="C:\Program Files\DrWeb Server\var" -verbosity=all -log="C:\Program Files\DrWeb Server\var\initdb.log" modexecdb database-init

It is assumed that Dr.Web Server is installed in the C:\Program Files\DrWeb Server folder.

7.Run drwcsd.exe with the modexecdb database-import switch to import the database from the file. The command line will look as follows:

"C:\Program Files\DrWeb Server\bin\drwcsd.exe" -home="C:\Program Files\DrWeb Server" -var-root="C:\Program Files\DrWeb Server\var" -verbosity=trace -log="C:\Program Files\DrWeb Server\var\importdb.log" modexecdb database-import D:\esbase.es

8.Start Dr.Web Server.

For UNIX OS

1.Stop Dr.Web Server using the script

for Linux OS:

/etc/init.d/drwcsd stop

for FreeBSD OS:

/usr/local/etc/rc.d/drwcsd stop

or using Dr.Web Security Control Center.

2.Start Dr.Web Server with the modexecdb database-export switch to export the database to a file. The command line initiated from the Dr.Web Server installation folder will look as follows:

for Linux OS:

/etc/init.d/drwcsd modexecdb database-export /var/esbase.es

for FreeBSD OS:

/usr/local/etc/rc.d/drwcsd modexecdb database-export /var/drwcs/esbase.es

It is assumed that the database is exported to esbase.es, which is located in the specified folder.

3.Start Dr.Web Server using the script

for Linux OS:

/etc/init.d/drwcsd start

for FreeBSD OS:

/usr/local/etc/rc.d/drwcsd start

connect Dr.Web Security Control Center to Dr.Web Server and configure Dr.Web Server to use a different database through Dr.Web Security Control Center menu: Administration → Dr.Web Server configuration → Database tab.

info

You can also reconfigure Dr.Web Server to use a different database by editing the Dr.Web Server configuration file drwcsd.conf directly. To do this, you should comment out/delete the entry about the current database and enter the new database (for more details see F1. Dr.Web Server Configuration File).

You will be prompted to restart Dr.Web Server. Cancel the restart prompt.

4.Stop Dr.Web Server (see step 1).

5.Move the database file to a temporary directory until you are sure that changing the database type was successful.

6.Run drwcsd with the modexecdb database-init switch to initialize a new database. The command will look as follows:

for Linux OS:

/etc/init.d/drwcsd modexecdb database-init

for FreeBSD OS:

/usr/local/etc/rc.d/drwcsd modexecdb database-init

7.Run drwcsd using the modexecdb database-import switch to import the database from a file. The command will look as follows:

for Linux OS:

/etc/init.d/drwcsd modexecdb database-import /var/esbase.es

for FreeBSD OS:

/usr/local/etc/rc.d/drwcsd modexecdb database-import /var/esbase.es

8.Start Dr.Web Server (see step 3).

info

If you want to change the Dr.Web Server start-up parameters (for example, specify the Dr.Web Server installation folder, change the log level, etc.), you will have to edit the start-up script:

for FreeBSD OS:

/usr/local/etc/rc.d/drwcsd

for Linux OS:

/etc/init.d/drwcsd