Novell Home

Script to Copy GWIA Send/Receive Folders Automatically

Novell Cool Solutions: Feature
By Jamie Glendinning

Digg This - Slashdot This

Posted: 22 Jan 2003
 

Problem:

We sometimes get corrupted messages coming in through our incoming GWIA that can abend the server.

If you restart the server and the GWIA loads - the file is still in the receive queue - and is processed again and abends the server.

Solution:

I have created a script that runs when you load gwia.ncf on the server (every time the GWIA is loaded)

This script uses toolbox.nlm to copy the contents of the <gwia>\send and <gwia>\receive folders to <gwia>\send.tmp and <gwia>\receive.tmp as one of these folders contains the corrupted file.

Toolbox then copies a txt file from the <gwia> folder to the <gwia>\receive folder. The file is called 000000.000 which means that it should be the first message to be processed when the gwia comes up.

This file is a simple message addressed to all the NetWare admins (and alerts account) notifying them that the gwia has been restarted and to check the appropriate .tmp folders for corrupted messages.

The script then launches the GWIA (sending out appropriate messages) and we can then look at the corrupted file/files at a later date.

The modified gwia.ncf file looks like:

###########################
search add SYS:\system

#script for loading gwia 
#will move all items in receive queue to receive.tmp
#this should stop the gwia abending on start up if there is a corrupted file
#it should also email various people informing them of the restart.
#to modify the email - look into the 00000.000 file under ..\kvgwia\
#should work. JEG 20020903

#load toolbox
toolbox

wait 5
#authenticate toolbox with groupwise userid
auth uk <nds account with access rights>
<NDS Account Password>

#move current receive queue to tmp folder
move data1:\kvgwia\receive\*.* data1:\kvgwia\receive.tmp\
move data1:\kvgwia\send\*.* data1:\kvgwia\send.tmp\

#send email notifying gwia restart
copy data1:\kvgwia\notify.txt data1:\kvgwia\receive\00000000.000

#logout auth
auth -dy

#start the gwia

load SYS:\system\gwia @gwia.cfg
###########################

and the 0000000.000 file lookes like:

###########################
MAIL FROM:<admin.alerts>
RCPT TO: <jamie.glendinning@darcyww.co.uk>
RCPT TO: <..other admin accounts.@darcyww.co.uk>
RCPT TO: <admin.alerts>
Subject: KVGWIA/ UKEMAIL4 SERVER restarted
To: jamie.glendinning@darcyww.co.uk 

UKEMAIL4 Server has restarted 

Please check kvgwia receive.tmp and send.tmp folders for queued files:
\\ukemail4\data1\kvgwia\receive.tmp 
\\ukemail4\data1\kvgwia\send.tmp 

###########################

This works for us and I know newer versions of the GWIA (we are on GroupWise 5.5.5) are more robust but things can still go wrong.

Jamie Glendinning

For more tips see:

submit a tip

Here's a chance to share your experiences using GroupWise. Just send us a tip about using (or installing, deploying, troubleshooting, etc.) GroupWise, and if it looks like something we can use, we'll send you a Novell t-shirt, post your tip, and make you famous beyond your tamest dreams. Submit your tip here: http://www.novell.com/coolsolutions/forms/submit_a_tip.html


Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com

© 2014 Novell