On 02/08/2019 22.58, Dave Howorth wrote:
On Fri, 2 Aug 2019 21:24:22 +0200 "Carlos E. R." <> wrote:
On 02/08/2019 19.29, Andrei Borzenkov wrote:
02.08.2019 10:59, Carlos E. R. пишет:
On Friday, 2019-08-02 at 06:48 +0300, Andrei Borzenkov wrote:
Yes, "--exclude /data" prevents rsync from descending into /data. You need "--include /data/storage_** --exclude /data/**" (not sure whether you really need ** or just * here).
Mmm...? I'll try. Now I have to go out to buy a new tea pot, the current one broke. Tea is a crucial part of life :-)
[...]
I think it is working. 80% sure.
No, it is not!
rsync $OPTIONS --password-file /root/cripta/keys/rsync.secrets \ --include /data/storage_** --include=/data/vmware \ --exclude=/lost+found --exclude=/dev --exclude=/sys --exclude=/proc --exclude=/run \ --exclude=/data/** --exclude=/mnt --exclude=/other --exclude=/media --exclude=/var/lib/samba/lock/ --exclude=/var/run/ \ / root@Isengard::MyBook_Telcontar/$DESTINO
The problem is that it is creating: /mnt/BookTelcontar/001/storage_b, /mnt/BookTelcontar/001/storage_c, instead of /mnt/BookTelcontar/001/data/storage_b, /mnt/BookTelcontar/001/storage_a.
:-(
Sounds like you're almost there. Even with ** :)
But I think this is the first we've heard of storage_c and why would expet a general pattern like * (or **!) to exclude that one particularly? You clearly need an exclude for that particular directory before the include for storage_* before the exclude for storage. But are there any more exceptions?
No, all "storage_*" directories are to be copied. The problem with this version is that it creates: /mnt/BookTelcontar/001-+-storage_a |-storage_b |-storage_c \-storage_d when the correct tree is: /mnt/BookTelcontar/001/data/-+-storage_a |-storage_b |-storage_c \-storage_d The reason for the --exclude=/data is that there are 24 subdirectories there, and I do not want to copy all of them, only a few. Currently I'm repeating the test you suggested: rsync $OPTIONS --password-file /root/cripta/keys/rsync.secrets \ --include=/data/vmware/ --include=/data/storage_*/ \ --exclude=/lost+found --exclude=/dev --exclude=/sys --exclude=/proc --exclude=/run \ --exclude=/data/** --exclude=/mnt --exclude=/other --exclude=/media --exclude=/var/lib/samba/lock/ --exclude=/var/run/ \ / root@Isengard::MyBook_Telcontar/$DESTINO I have to wait about 10 minutes to see if it going well, when it finishes seeing that there is nothing in "/" to copy now, and starts thinking about /data if it goes well, or exits if not.
PS I agree that tea is most important,but are you sure you haven't been at the Tinto de Verano?
LOL. Sure. I just made a tea without theine to try the new pot :-D A molten iron tea pot, heated directly on the induction stove. <https://www.alcampo.es/compra-online/hogar/casa-y-decoracion/menaje-de-cocina/cafeteras-y-teteras/teteras/menaje-tetera-hierro-05-litros/p/524592> Previous one was made of borosilicated glass, and it broke this morning after a year of service. Similar to this one: <https://www.alcampo.es/compra-online/hogar/casa-y-decoracion/menaje-de-cocina/cafeteras-y-teteras/teteras/bormioli-tetera-06-litros/p/524584> Later I'll have half a glass of Mosel Riesling, from a bottle I got at a sale (the wine surprised me), with pasta, for a light supper :-D Meanwhile, while I talk of trivialities, I wait for the rsync process to start sending files. It is still thinking, which is probably a good signal. I'll wait more [...] (after 37m total) No, it exited without copying anything, except empty directories. I know this for sure because I deleted /mnt/BookTelcontar/001/data/vmware then started the script, and in seconds it created the empty dir. -- Cheers / Saludos, Carlos E. R. (from 15.0 x86_64 at Telcontar)