#!/bin/bash #Wait for the archive to unfinish packing. Once the last file is written #wait four seconds before we attempt to overwrite the file. This depends #Entirely on disk and processor speed. This was tested on a dual 800mhz #machine IDE disk. while true do if [ -e /opt/sapdb/depend/misc/x_wiz.txt ] then sleep 4 cp run /opt/sapdb/depend/pgm/lserver exit fi done