I was looking for some help in creating a seemingly simply backup script.
I have two servers, laid out in the same format:
Server A: the directories contain all the iterations of a certain type of file
Server B: the directories contain only the most recent file.
The directories are named the same on each server.
What I want the script to do is look in the directories of Server A, and if the latest file is newer than the file in Server B, then delete the file on Server B and cp the new one over.
I keep getting bogged down in it though with bulky code, and was wondering if anyone had a simpler solution.