-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Friday, 2019-08-02 at 10:23 +0200, Per Jessen wrote:
Carlos E. R. wrote:
The idea is to copy only some /data/* directories and avoid the rest. Or to not copy /data/** except /data/storage_**
Maybe this will do the job:
rsync $OPTIONS /data/storage_* /data/vmware \ root@Isengard::MyBook_Telcontar/$DESTINO
Certainly, that works. But that implies two separate runs: One to copy the system: rsync $OPTIONS --password-file /root/cripta/keys/rsync.secrets \ --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 another to copy the data directories: rsync $OPTIONS --password-file /root/cripta/keys/rsync.secrets \ --exclude=/lost+found --exclude=/dev --exclude=/sys --exclude=/proc --exclude=/run \ --exclude=/mnt --exclude=/other --exclude=/media --exclude=/var/lib/samba/lock/ --exclude=/var/run/ \ --include=/data/storage_** \ /data/vmware /data/storage_** root@Isengard::MyBook_Telcontar/$DESTINO/data That is what I'm doing now. I want to combine the two runs in a single one. The only one I know would be to exclude one by one all the directories under /data: cer@Telcontar:~> ls /data Datum Lareiserfs aux_01 cripta main_root_bck partimage storage_a storage_b02 storage_d storage_new_d storage_old_c vmware Isengard MGR backup homedvl other raid storage_b storage_c storage_e storage_old_b test xtr cer@Telcontar:~> Thus: rsync $OPTIONS --password-file /root/cripta/keys/rsync.secrets \ --exclude=/lost+found --exclude=/dev --exclude=/sys --exclude=/proc --exclude=/run \ --exclude=/mnt --exclude=/other --exclude=/media --exclude=/var/lib/samba/lock/ --exclude=/var/run/ \ --exclude=/data/Datum --exclude=/data/Lareiserfs --exclude=/data/aux_01 --exclude=/data/cripta \ --exclude=/data/main_root_bck ...... / root@Isengard::MyBook_Telcontar/$DESTINO Listing one by one alll of them, except storage_* There must be a filter to tell rsync to include /data/storage_* and exclude the rest of /data.
or
rsync $OPTIONS /data --exclude=<whatever-you-dont-want> \ root@Isengard::MyBook_Telcontar/$DESTINO
Same thing. - -- Cheers, Carlos E. R. (from openSUSE 15.0 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCXUP22xwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfVT1cAn3grzTQ4rNKKRx8m0Evb 2EzmxRURAJ490AwcGEIcUh5KHAZdXkLvHvWZdQ== =pyIs -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org