cp or rsync??
I am in need of copying file of a specific format (mp3, mp4, png, tiff, jpg, jpeg...) from a folder on one server to another. I need to maintain the folder/file structure so that "somedironSever1"/images/2009/fall/Eventone/file.png is copied to "somedironSever2"/file/myfiles/images/2009/fall/Eventone/file.png.
I don't believe I need to supply anymore details since it shouldn't be distro specific but I will say that they are on the latest Ubuntu Sever version I believe.
I am not quite sure if cp has the power to do what I need or if rsync has the flexibility to do it either.
If someone could provide an example of whatever command or script I would need to do this that would be wonderful. If someone finds a post or forum that may be help thats good also. Also, if someone knows of some tag words that I could use to search for this type of request for say searching on google that would help, besides "cp" and "rsync".
You could use
rsync -avm --del --include='*.png' -f 'hide,! */' /source/ Server2:/destination
This is straight from man rsync.
|All times are GMT -5. The time now is 09:08 PM.|