How to rebuild QMS in a cluster environment

  • 7020768
  • 04-May-2009
  • 07-Aug-2017

Environment



GWAVA 4 (build 103+)
NETWARE 6.5.x, 6.0.x, 5.1.x
LINUX OES, SLES9.3, SLES10.x

Situation

No mail in Quarantine back to a certain date Error in QMS log or on console, "Database is malformed…" Error in QMS log or on console, "DB Error: file is encrypted or is not a database" Error in QMS log or on console, "Failed to Write Records: Error 9" No message envelope when trying to release a quarantined message.

Resolution



** Before you start, make sure that GWAVA is properly configured to run within a cluster environment. **

For NetWare:  http://support.gwava.com/kb/?View=entry&EntryID=343

For Linux:  http://support.gwava.com/kb/?View=entry&EntryID=344 

The below method of rebuilding the quarantine database will allow the QMS rebuild to occur while mail continues to flow uninterrupted.
NOTE:  All quarantine access will be disabled during rebuild.  However, any quarantined mail received during the rebuild will not be lost. 

INSTRUCTIONS FOR REBUILDING THE QMS DATABASE


NETWARE:

1.) Unload QMS2.  Type "unload address space=gwava4qms" at the system console. 



Wait for QMS to unload...



2)  Load GWAVAQMS manually from the command line, then type:
load address space=gwava4qms qms2 /recovery=rebuild /consolelog /gmanAddress=(clusterIP)

Example:

load address space=gwava4qms qms2 /recovery=rebuild /consolelog /gmanAddress=10.1.19.2

*************************************************************** NOTE **************************************************************************
if using GWAVA4 version 1.03 or earlier, use:
load address space=gwava4qms gwavaqms /recovery=rebuild /consolelog /gmanAddress=(clusterIP)
************************************************************************************************************************************************

There's an optional switch that may be used at the end, /recoverdays=x.  Replace the x with the number of days you would like to recover from your quarantine.  For example:

load address space=gwava4qms qms2 /recovery=rebuild /consolelog /gmanAddress=10.1.19.2 /recoverdays=7

will perform the rebuild, and recover the last 7 days worth of email from the QMS.  This switch is useful for speeding up the rebuild process and reducing the size of the database. 

3)  Take a look on the GWAVAQMS2 server console to see if the rebuild is in process.  Depending on the size of the QMS database, the rebuild process make take from minutes up to several hours to complete.



Then wait for the rebuild to complete:



4)  Upon completion unload GWAVA4 by typing gwavadn at the system console.

 5) Then start GWAVA4 back up using gwavaup

 



LINUX:

1)  Unload GWAVAQMS.  Type "rcgwavaman stop gwavaqms" at the terminal




2)   Change directory to /opt/beginfinite/gwava/assets/bin



3)  Run GWAVAQMS with rebuild switch.  Type ./qms2 /recovery=rebuild /consolelog /gmanAddress=(clusterIP) at the terminal.  (Do this process while GWAVA is running to maintain mail flow during rebuild)

Example:

./qms2 /recovery=rebuild /consolelog /gmanAddress=10.1.1.32

*************************************************************** NOTE **************************************************************************
If using GWAVA4 version 1.03 or earlier, use ./gwavaqms /recovery=rebuild /consolelog /gmanAddress=(clusterIP) instead.
*************************************************************************************************************************************************

There's an optional switch that may be used at the end, /recoverdays=x.  Replace the x with the number of days you would like to recover from your quarantine.  For example:

./qms2 /recovery=rebuild /consolelog /gmanAddress=10.1.1.32 /recoverdays=7

will perform the rebuild, and recover the last 7 days worth of email from the QMS.  This switch is useful for speeding up the rebuild process and reducing the size of the database. 

Depending on the size of the QMS database, the rebuild process make take from minutes up to several hours to complete.

4) Wait for the rebuild to complete.



5)  After the rebuild GWAVAQMS will unload itself.  Go ahead and shutdown the rest of GWAVA.  Type rcgwavaman stop at the terminal.



6)   Type rcgwavaman start to start GWAVA with a newly repaired QMS database.

For information on how to minimize future database corruptions:
http://support.gwava.com/kb/?View=entry&EntryID=421

For information on how to do a rebuild for GWAVA QMS running in a non-cluster environment:
http://support.gwava.com/kb/?View=entry&EntryID=235

Additional Information

This article was originally published in the GWAVA knowledgebase as article ID 1235.

Feedback service temporarily unavailable. For content questions or problems, please contact Support.