
November 3rd, 2006, 09:10 PM
|
|
Contributing User
|
|
Join Date: Sep 2004
Location: Southern Ohio
Posts: 47
Time spent in forums: 11 h 43 m 24 sec
Reputation Power: 0
|
|
|
Help with FTP backup script....
All right, I am trying to put together a batch FTP script that will backup my MP3 collection from my server (Linux) to my local machine (Windows) and right now I have hit a brick wall.
Originally I had done the idea of this script by using a batch script on the Windows machine that would use the net use command to create a temporary networked drive to that folder (I had my MP3 folder set up as a network drive as well) and back it that way. That worked great...but then I thought maybe I should start doing it through FTP instead and honestly, I am beginning to think FTP is making it twice as hard.
This is what I'd hope to accomplish:
-Back up all files, directories, and subdirectories and maintain that integrity when it's transferred to my local machine (Windows) through FTP.
But as I said, I am running into some snags mainly around the directory/subdirectory issue. From what I am seeing at this point, it appears like I am going to have to go through basically each directory to back it up. That, to me, seems like a lot of extra work and might make the script a tad difficult to maintain...especially if I decide to change the directory structure around a tad (which occasionally I do). This is what my directory structure looks like, in a general sense...
M:\MP3
M:\MP3\Artist
M:\MP3\Artist\Album
M:\MP3\Artist\Album\song.mp3
...and so forth.
So am I truly gonna have to change directories in the script to make it work? I originally thought I could use the wild card at the main directory (in this case MP3) but that didn't work....unless I was doing something wrong. But anyways, if anyone has any suggestions let me know. I'd really appreciate it.
|