[NTLUG:Discuss] shell script help needed

Bug Hunter bughuntr at one.ctelcom.net
Thu Apr 26 18:33:32 CDT 2001


  does the first line of your script start with

#!/bin/bash

  If not, give that a try.  If that does not work, then you can possibly
put a 

while true; do
sleep 1000
 other code
;
done

  or some such number in the file to make it sleep as long as you wish,
and run it from a terminal and detach it:

script &

  this should hold, even if you log out.


  The other place to try running such a script is in 
/etc/rc.d/rc.local

bug


On Thu, 26 Apr 2001, David wrote:

> I forgot to mention the types of clients that I am connecting to.
> The 209.x.x.x is a UNIX machine at a customer site running
> ProFTPD 1.2.0pre9 Server.
> The 10.x.x.x which is routeable from here is running eegghh  
> MS-IIS version of ftp on an NT4 machine.
> 
> I considered rsync but the users on both ends are non-technical.
> 
> The thing that confuses me is that the scripts run perfectly when executed by
> hand ,but when called from the cron (root or user) the script hangs in the
> process table and the local file listing for the purpose of running `diff`
> never happens.
> 
> The main problem seems to be getting the directory listing with the echo 
> command.Transferring the files then is no problem.




More information about the Discuss mailing list