Quote:
Originally Posted by AshuTrip
the /root directory is just for example.. it could be anything
|
First look at permissions.
Consider using rsync. Rsync, when given the filename to transfer, will either transfer it or not, depending on if it is there. error messages can be ignored if desired. Rsync uses ssh so it is secure.
It seems you might be expecting to do this repeatedly so consider a cron job to do so.
It would be very easy to use the date command to find the date/time on the client, add an adjustment for the date/time difference on the server, then send the full file name to be retrieved.