Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have created two same directories on two different locations. The structure is as shown below.
/web_upload/
/mnt/web_upload/
Now, I want to merge all contents of both "web_upload" directories into one directory. Simply,i want to copy all data & files from "/web_upload" to "/mnt/web_upload/" , without affecting original data on "/mnt/web_upload/"
Distribution: approximately NixOS (http://nixos.org)
Posts: 1,900
Rep:
It is hard to make cp overwrite entire directories - it will just copy corresponding files into it. Of course there can be name conflicts between files. That's why I recommend studying "-i" option (interactive, implies asking on overwrite) and piping "yes n" (infinite stream of "n") to cp (that way you decline all overwrite requests.
do you mean /etc/rsyncd.conf ? I am not aware of any requirement for a plain rsync.conf since most of the options are provided on the command-line or from the ssh config files.
unless you want to run this as a daemon process, you don't need rsyncd.conf.
as for documentation, all i can suggest is man and google , or if you need help with something specific, maybe someone here can help.
"/mnt/web_upload/data_27/" directory contains,
file1
file2
file4
SQL Directory
-------------------------------------------------
So, it is clear that file1,file2 & SQL Directory - common on both directories.
Now, please let me know how to merge all data without overwriting existing files & directories?
Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place.
I have merged your two virtually-duplicate threads into one.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.