Re: [ILUG] how do i....

From: John P. Looney (john at domain antefacto.com)
Date: Wed 06 Jun 2001 - 13:00:14 IST


On Wed, Jun 06, 2001 at 12:32:00PM +0100, Gerard J Keating mentioned:
> i want to run a linux application from an ms-dos command batch file.

 I reckon the handiest way is to get the batch file to create a flag file
on a shared filesystem, and have a cronjob on the linux box checking for
it.

 If the file exists, then the cronjob deletes it, and runs the application
in question. Afterwards, it creates an "I'm done" flag file.

 testing...

bartender [0] touch /tmp/flag
bartender [0] if [ -e /tmp/flag ] ; then echo yes ; else echo no ; fi
yes
bartender [1] rm /tmp/flag
bartender [0] if
no

 The cronjob would be something like;

*/15 * * * * if [ -e /mnt/ntshare/flag ] ; then /usr/local/bin/program ; touch /mnt/ntshare/flag ; rm /mnt/ntshare/flag ; fi

 How to do that on the NT end...is left as an exercise for the reader.

Kate

-- 
 When I say 'free', I mean 'free': free from bond, of chain or command: 
to go where you will, even to Mordor, Saruman, if you desire. " 
    -- Gandalf, paraphrasing the choice between Free and Non-free software


This archive was generated by hypermail 2.1.6 : Thu 06 Feb 2003 - 13:10:34 GMT