> Hello,
>
> I've got a Windows 2000 machine that I'm using as a web server. As a
> safeguard, I've got a redhat 9 machine that I want to mirror all the web
> sites on. I manually copied all the sites over, and setup apache. My
> question is, I'd like to set up a cron job to once a week copy the
> contents of folders on the windows system and replace the content in the
> same folders on the redhat server. Is that possible?

The easiest solution would probably be the following:

Go to http://www.chiark.greenend.org.uk/~sgtatham/putty/ and get the
pscp.exe package.  It is a secure copy client for windows, and it is
strictly command-line.  You should be able to write a batch file to call it
and copy your files to the redhat box.

NOTE:  You'll have to authenticate from the windows box to the redhat box.
This means either that you will have to store the redhat account password in
the windows box or a certificate.  Storing the password is dangerous,
because if somebody compromises your windows box, they'll have your redhat
password.  However, I do not know how to do the stored certificate thing, so
maybe somebody else here can help with that one.

Anyway, once you have written the batch file, use the windows "AT" command
to set it up to run at a specific time each week, and you're done.

To implement a bit more safety, I'd set up a non-priviledged account that
was chrooted to a directory in /tmp and use that to copy the files over.
Then have a cron job on the redhat box that will check the next day for any
files in that directory and copy them to the appropriate place on the redhat
server.  You can still get hacked if somebody compromises your windows box,
but it would be a bit more difficult.

Ben


-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list

Reply via email to