Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

Numeric stability is probably not all that important when you're guessing.


computers / alt.os.linux.mint / Re: rsync problem

SubjectAuthor
* rsync problempinnerite
`* Re: rsync problemDan Purgert
 `* Re: rsync problempinnerite
  `* Re: rsync problemDan Purgert
   `* Re: rsync problemDavid Catterall
    `* Re: rsync problemDan Purgert
     `* Re: rsync problempinnerite
      `* Re: rsync problemDan Purgert
       `* Re: rsync problemMark Bourne
        `* Re: rsync problemDan Purgert
         `* Re: rsync problempinnerite
          `- Re: rsync problemDan Purgert

1
rsync problem

<20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6631&group=alt.os.linux.mint#6631

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: pinner...@gmail.com (pinnerite)
Newsgroups: alt.os.linux.mint
Subject: rsync problem
Date: Tue, 8 Aug 2023 21:39:25 +0100
Organization: A noiseless patient Spider
Lines: 22
Message-ID: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Info: dont-email.me; posting-host="da0e655af9f1eb463dea0b232d874ccc";
logging-data="3727824"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+7eiv4/+G9UQWvkRwjiGYNR3DYnNJn+y0="
Cancel-Lock: sha1:zWLI3gPSdienqsQ2A9uXMSHEZYU=
X-Newsreader: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu)
 by: pinnerite - Tue, 8 Aug 2023 20:39 UTC

This looks like the final phase of the problem arising from the
mounting issue I described earlier.

When I backup files using rsync from my work machine to my backup
machine, they all end up with owner (user) as root and group alan
(correctly), having started as alan:alan.

I have been faffing about all evening maling no progress at all.

This is one of the small folders used to test it.

rsync -rlptD --exclude-from=/home/alan/Scripts/exclude.txt --chown=alan:alan --progress /home/clnts_bkkpg/ /spare/churchill/clnts_bkkpg/

I have tried using -a instead of -rlptD even added -g and -o but that just slowed it down to zero movement.

I could live with it if I had to but it is irritating.

TIA

--
Linux Mint 21.1 kernel version 5.15.0-78-generic Cinnamon 5.6.8
AMD Phenom II x4 955 CPU 16Gb Dram 2TB Barracuda

Re: rsync problem

<slrnud5dpk.f45.dan@djph.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6632&group=alt.os.linux.mint#6632

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: dan...@djph.net (Dan Purgert)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Tue, 8 Aug 2023 21:43:02 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 16
Message-ID: <slrnud5dpk.f45.dan@djph.net>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
Injection-Date: Tue, 8 Aug 2023 21:43:02 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="6d4cf9e352c7fccd002f5699a2b8515e";
logging-data="3747375"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19wcKQ7kxLOFnlQNl8RqlaJIyPUXhmQRoE="
User-Agent: slrn/1.0.3 (Linux)
Cancel-Lock: sha1:Mb2/XyfZXNMnT6BKxRzoUfiE9zY=
 by: Dan Purgert - Tue, 8 Aug 2023 21:43 UTC

On 2023-08-08, pinnerite wrote:
> This looks like the final phase of the problem arising from the
> mounting issue I described earlier.
>
> When I backup files using rsync from my work machine to my backup
> machine, they all end up with owner (user) as root and group alan
> (correctly), having started as alan:alan.

Your samba server's share options (and/or mounting options) are the
likely cause of these unwanted ownership changes.

--
|_|O|_|
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: DDAB 23FB 19FA 7D85 1CC1 E067 6D65 70E5 4CE7 2860

Re: rsync problem

<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6633&group=alt.os.linux.mint#6633

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED.host-78-145-94-105.as13285.net!not-for-mail
From: pinner...@gmail.com (pinnerite)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Wed, 9 Aug 2023 11:02:25 +0100
Organization: A noiseless patient Spider
Message-ID: <20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Info: dont-email.me; posting-host="host-78-145-94-105.as13285.net:78.145.94.105";
logging-data="4097460"; mail-complaints-to="abuse@eternal-september.org"
X-Newsreader: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu)
 by: pinnerite - Wed, 9 Aug 2023 10:02 UTC

On Tue, 8 Aug 2023 21:43:02 -0000 (UTC)
Dan Purgert <dan@djph.net> wrote:

> On 2023-08-08, pinnerite wrote:
> > This looks like the final phase of the problem arising from the
> > mounting issue I described earlier.
> >
> > When I backup files using rsync from my work machine to my backup
> > machine, they all end up with owner (user) as root and group alan
> > (correctly), having started as alan:alan.
>
> Your samba server's share options (and/or mounting options) are the
> likely cause of these unwanted ownership changes.
>

Thanks. Eventually I found that I had to run rsync as root.

Regards, Alan

--
Linux Mint 21.1 kernel version 5.15.0-78-generic Cinnamon 5.6.8

Re: rsync problem

<slrnud6pif.f45.dan@djph.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6634&group=alt.os.linux.mint#6634

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED.2603-6010-dc01-2602-123d-1cff-feaf-14b4.res6.spectrum.com!not-for-mail
From: dan...@djph.net (Dan Purgert)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Wed, 9 Aug 2023 10:10:09 -0000 (UTC)
Organization: A noiseless patient Spider
Message-ID: <slrnud6pif.f45.dan@djph.net>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
Injection-Date: Wed, 9 Aug 2023 10:10:09 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="2603-6010-dc01-2602-123d-1cff-feaf-14b4.res6.spectrum.com:2603:6010:dc01:2602:123d:1cff:feaf:14b4";
logging-data="4099132"; mail-complaints-to="abuse@eternal-september.org"
User-Agent: slrn/1.0.3 (Linux)
 by: Dan Purgert - Wed, 9 Aug 2023 10:10 UTC

On 2023-08-09, pinnerite wrote:
> On Tue, 8 Aug 2023 21:43:02 -0000 (UTC)
> Dan Purgert <dan@djph.net> wrote:
>
>> On 2023-08-08, pinnerite wrote:
>> > This looks like the final phase of the problem arising from the
>> > mounting issue I described earlier.
>> >
>> > When I backup files using rsync from my work machine to my backup
>> > machine, they all end up with owner (user) as root and group alan
>> > (correctly), having started as alan:alan.
>>
>> Your samba server's share options (and/or mounting options) are the
>> likely cause of these unwanted ownership changes.
>>
>
> Thanks. Eventually I found that I had to run rsync as root.
>

Yeah, running as root will muck up ownership too ...

--
|_|O|_|
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: DDAB 23FB 19FA 7D85 1CC1 E067 6D65 70E5 4CE7 2860

Re: rsync problem

<ub05q0$3v9gc$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6635&group=alt.os.linux.mint#6635

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED.78.152.192.74!not-for-mail
From: djc...@eircom.net (David Catterall)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Wed, 9 Aug 2023 14:54:08 +0100
Organization: A noiseless patient Spider
Message-ID: <ub05q0$3v9gc$1@dont-email.me>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Wed, 9 Aug 2023 13:54:08 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="78.152.192.74";
logging-data="4171276"; mail-complaints-to="abuse@eternal-september.org"
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101
Thunderbird/102.4.2
Content-Language: en-GB
In-Reply-To: <slrnud6pif.f45.dan@djph.net>
 by: David Catterall - Wed, 9 Aug 2023 13:54 UTC

On 09/08/2023 11:10, Dan Purgert wrote:
> Yeah, running as root will muck up ownership too ...

Even with -a option?

David

Re: rsync problem

<slrnud7dil.f45.dan@djph.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6636&group=alt.os.linux.mint#6636

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED.2603-6010-dc01-2602-123d-1cff-feaf-14b4.res6.spectrum.com!not-for-mail
From: dan...@djph.net (Dan Purgert)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Wed, 9 Aug 2023 15:51:34 -0000 (UTC)
Organization: A noiseless patient Spider
Message-ID: <slrnud7dil.f45.dan@djph.net>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net> <ub05q0$3v9gc$1@dont-email.me>
Injection-Date: Wed, 9 Aug 2023 15:51:34 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="2603-6010-dc01-2602-123d-1cff-feaf-14b4.res6.spectrum.com:2603:6010:dc01:2602:123d:1cff:feaf:14b4";
logging-data="7683"; mail-complaints-to="abuse@eternal-september.org"
User-Agent: slrn/1.0.3 (Linux)
 by: Dan Purgert - Wed, 9 Aug 2023 15:51 UTC

On 2023-08-09, David Catterall wrote:
> On 09/08/2023 11:10, Dan Purgert wrote:
>> Yeah, running as root will muck up ownership too ...
>
> Even with -a option?

Yes, -a is the equivalent of -rlptgoD, which should preserve the
ownership details:

-r (recursive)
-l (copy symlinks)
-p (preserve permissions)
-t (preserve modification time)
-g (preserve group)
-o (preserve owner (superuser only))
-D (--devices and --specials)

Just so we're on the same page though, the original set of options was
only "-rlptD", so coupled with a CIFS share (and other things we don't
know, such as invoking the initial transfer with sudo), chances are
pretty high that the ownership (and group) information woud be changed.

Note that there are probably many cases where not using -o (-g) leaves
things perfectly "fine".

--
|_|O|_|
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: DDAB 23FB 19FA 7D85 1CC1 E067 6D65 70E5 4CE7 2860

Re: rsync problem

<20230809212128.d44e3c6184159fd93315897c@gmail.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6637&group=alt.os.linux.mint#6637

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED.host-78-145-94-105.as13285.net!not-for-mail
From: pinner...@gmail.com (pinnerite)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Wed, 9 Aug 2023 21:21:28 +0100
Organization: A noiseless patient Spider
Message-ID: <20230809212128.d44e3c6184159fd93315897c@gmail.com>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net>
<ub05q0$3v9gc$1@dont-email.me>
<slrnud7dil.f45.dan@djph.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Info: dont-email.me; posting-host="host-78-145-94-105.as13285.net:78.145.94.105";
logging-data="78789"; mail-complaints-to="abuse@eternal-september.org"
X-Newsreader: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu)
 by: pinnerite - Wed, 9 Aug 2023 20:21 UTC

Just so it is clear, today completed a full backup of my work machine.
It took many hours. The result was perfect.

So this is an example of the mount statement and the rsync statememt.
I have five of each running from the script that is executed from a sudo:

mount -t cifs -o rw,noperm,user=alan,password=<my_password>,domain=ASANDCO,vers=1.0 //192.168.1.66/alan/ /spare/churchill/alan/

rsync -avz --exclude-from=/home/alan/Scripts/exclude.txt --chown=alan:alan --progress /home/alan/ /spare/churchill/alan/

Thr only niggle remaining is that I cannot get it to run from a desktop icon.
I'll return to that when I have time.
--
Linux Mint 21.1 kernel version 5.15.0-78-generic Cinnamon 5.6.8

Re: rsync problem

<slrnuda37a.f45.dan@djph.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6639&group=alt.os.linux.mint#6639

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: dan...@djph.net (Dan Purgert)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Thu, 10 Aug 2023 16:13:16 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 35
Message-ID: <slrnuda37a.f45.dan@djph.net>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net> <ub05q0$3v9gc$1@dont-email.me>
<slrnud7dil.f45.dan@djph.net>
<20230809212128.d44e3c6184159fd93315897c@gmail.com>
Injection-Date: Thu, 10 Aug 2023 16:13:16 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="22143341316e4b73cb6fc3f4eebec651";
logging-data="459453"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18+HKxN3Z5IEM+2dup+aOoKI7xxdp4qWck="
User-Agent: slrn/1.0.3 (Linux)
Cancel-Lock: sha1:Lv6jvA3xc7fPn+ZaBGPg82EyXug=
 by: Dan Purgert - Thu, 10 Aug 2023 16:13 UTC

On 2023-08-09, pinnerite wrote:
> Just so it is clear, today completed a full backup of my work machine.
> It took many hours. The result was perfect.
>
> So this is an example of the mount statement and the rsync statememt.
> I have five of each running from the script that is executed from a sudo:
>
> mount -t cifs -o
> rw,noperm,user=alan,password=<my_password>,domain=ASANDCO,vers=1.0
> //192.168.1.66/alan/ /spare/churchill/alan/
>
> rsync -avz --exclude-from=/home/alan/Scripts/exclude.txt
> --chown=alan:alan --progress /home/alan/
> /spare/churchill/alan/

huh, you shouldn't need the '--chown' switch here, with the '-a' flag
used. Furthermore, since you're sending it to a CIFS share, I'm
somewhat surprised it's retaining any of the unix ownership and mode
bits (normally, SMB/CIFS shares don't).

execution of the script itself as root would explain why "root" becomes
the owner though. Better to slap the 'sudo' into the command(s) that
need it in the script, rather than running the whole script with sudo.

>
> Thr only niggle remaining is that I cannot get it to run from a
> desktop icon.

Shell scripts are problematic at best when trying to run "from a desktop
icon".

--
|_|O|_|
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: DDAB 23FB 19FA 7D85 1CC1 E067 6D65 70E5 4CE7 2860

Re: rsync problem

<ub3cg3$fl78$1@dont-email.me>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6640&group=alt.os.linux.mint#6640

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: nntp.mbo...@spamgourmet.com (Mark Bourne)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Thu, 10 Aug 2023 20:06:42 +0100
Organization: A noiseless patient Spider
Lines: 39
Message-ID: <ub3cg3$fl78$1@dont-email.me>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net> <ub05q0$3v9gc$1@dont-email.me>
<slrnud7dil.f45.dan@djph.net>
<20230809212128.d44e3c6184159fd93315897c@gmail.com>
<slrnuda37a.f45.dan@djph.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Thu, 10 Aug 2023 19:06:43 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="9b799e6ed0269de45bdbc13c0862cfde";
logging-data="513256"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/+HigwXO+Eja0vtSmATIHq"
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101
SeaMonkey/2.53.16
Cancel-Lock: sha1:1nNZDPAJs1ZSki1DzXtz/ftvX50=
In-Reply-To: <slrnuda37a.f45.dan@djph.net>
 by: Mark Bourne - Thu, 10 Aug 2023 19:06 UTC

Dan Purgert wrote:
> On 2023-08-09, pinnerite wrote:
>> Just so it is clear, today completed a full backup of my work machine.
>> It took many hours. The result was perfect.
>>
>> So this is an example of the mount statement and the rsync statememt.
>> I have five of each running from the script that is executed from a sudo:
>>
>> mount -t cifs -o
>> rw,noperm,user=alan,password=<my_password>,domain=ASANDCO,vers=1.0
>> //192.168.1.66/alan/ /spare/churchill/alan/
>>
>> rsync -avz --exclude-from=/home/alan/Scripts/exclude.txt
>> --chown=alan:alan --progress /home/alan/
>> /spare/churchill/alan/
>
> huh, you shouldn't need the '--chown' switch here, with the '-a' flag
> used. Furthermore, since you're sending it to a CIFS share, I'm
> somewhat surprised it's retaining any of the unix ownership and mode
> bits (normally, SMB/CIFS shares don't).
>
> execution of the script itself as root would explain why "root" becomes
> the owner though. Better to slap the 'sudo' into the command(s) that
> need it in the script, rather than running the whole script with sudo.

You need to run as root if you want to be able to set the ownership,
either to match the original files. Otherwise, all files will end up
owned by whichever user runs the command. Non-root users can't set the
owner/group of files - IIRC I think that's to prevent unprivileged users
from running arbitrary commands as root by just creating a script,
making it "setuid root" and running it (possibly some other
considerations as well).

>> Thr only niggle remaining is that I cannot get it to run from a
>> desktop icon.
>
> Shell scripts are problematic at best when trying to run "from a desktop
> icon".
>

Re: rsync problem

<slrnudc675.f45.dan@djph.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6644&group=alt.os.linux.mint#6644

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: dan...@djph.net (Dan Purgert)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Fri, 11 Aug 2023 11:16:38 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 38
Message-ID: <slrnudc675.f45.dan@djph.net>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net> <ub05q0$3v9gc$1@dont-email.me>
<slrnud7dil.f45.dan@djph.net>
<20230809212128.d44e3c6184159fd93315897c@gmail.com>
<slrnuda37a.f45.dan@djph.net> <ub3cg3$fl78$1@dont-email.me>
Injection-Date: Fri, 11 Aug 2023 11:16:38 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="7e0e773345d3851b77f7a5f66c66b355";
logging-data="877975"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/AV/oQ+qZxrmygv8bK5hrjtL/HICQA8kA="
User-Agent: slrn/1.0.3 (Linux)
Cancel-Lock: sha1:L4oMO1+pVqW1E+znKWo1zj2Riyc=
 by: Dan Purgert - Fri, 11 Aug 2023 11:16 UTC

On 2023-08-10, Mark Bourne wrote:
> Dan Purgert wrote:
>> On 2023-08-09, pinnerite wrote:
>>> Just so it is clear, today completed a full backup of my work machine.
>>> It took many hours. The result was perfect.
>>>
>>> So this is an example of the mount statement and the rsync statememt.
>>> I have five of each running from the script that is executed from a sudo:
>>>
>>> mount -t cifs -o
>>> rw,noperm,user=alan,password=<my_password>,domain=ASANDCO,vers=1.0
>>> //192.168.1.66/alan/ /spare/churchill/alan/
>>>
>>> rsync -avz --exclude-from=/home/alan/Scripts/exclude.txt
>>> --chown=alan:alan --progress /home/alan/
>>> /spare/churchill/alan/
>>
>> huh, you shouldn't need the '--chown' switch here, with the '-a' flag
>> used. Furthermore, since you're sending it to a CIFS share, I'm
>> somewhat surprised it's retaining any of the unix ownership and mode
>> bits (normally, SMB/CIFS shares don't).
>>
>> execution of the script itself as root would explain why "root" becomes
>> the owner though. Better to slap the 'sudo' into the command(s) that
>> need it in the script, rather than running the whole script with sudo.
>
> You need to run as root if you want to be able to set the ownership,
> either to match the original files. Otherwise, all files will end up

Sure, but if he's "alan" on both hosts, then we're right back to "you
don't need to run as root". (And ownership/permission capabilities
of smb/cifs anyway).

--
|_|O|_|
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: DDAB 23FB 19FA 7D85 1CC1 E067 6D65 70E5 4CE7 2860

Re: rsync problem

<20230812230943.ed1f236ff05481db47d00456@gmail.com>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6645&group=alt.os.linux.mint#6645

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: pinner...@gmail.com (pinnerite)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Sat, 12 Aug 2023 23:09:43 +0100
Organization: A noiseless patient Spider
Lines: 41
Message-ID: <20230812230943.ed1f236ff05481db47d00456@gmail.com>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net>
<ub05q0$3v9gc$1@dont-email.me>
<slrnud7dil.f45.dan@djph.net>
<20230809212128.d44e3c6184159fd93315897c@gmail.com>
<slrnuda37a.f45.dan@djph.net>
<ub3cg3$fl78$1@dont-email.me>
<slrnudc675.f45.dan@djph.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Info: dont-email.me; posting-host="3ce9c092548e02b4d9a91e3c750ec159";
logging-data="1605409"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19DIOIJnAK67NsEpnNhYnRooFdAnp/+PgU="
Cancel-Lock: sha1:vZ94v4/EbfhF/wna41pxQ3RE/YY=
X-Newsreader: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu)
 by: pinnerite - Sat, 12 Aug 2023 22:09 UTC

On Fri, 11 Aug 2023 11:16:38 -0000 (UTC)
Dan Purgert <dan@djph.net> wrote:

> On 2023-08-10, Mark Bourne wrote:
> > Dan Purgert wrote:
> >> On 2023-08-09, pinnerite wrote:
> >>> Just so it is clear, today completed a full backup of my work machine.
> >>> It took many hours. The result was perfect.
> >>>
> >>> So this is an example of the mount statement and the rsync statememt.
> >>> I have five of each running from the script that is executed from a sudo:
> >>>
> >>> mount -t cifs -o
> >>> rw,noperm,user=alan,password=<my_password>,domain=ASANDCO,vers=1.0
> >>> //192.168.1.66/alan/ /spare/churchill/alan/
> >>>
> >>> rsync -avz --exclude-from=/home/alan/Scripts/exclude.txt
> >>> --chown=alan:alan --progress /home/alan/
> >>> /spare/churchill/alan/
> >>
> >> huh, you shouldn't need the '--chown' switch here, with the '-a' flag
> >> used. Furthermore, since you're sending it to a CIFS share, I'm
> >> somewhat surprised it's retaining any of the unix ownership and mode
> >> bits (normally, SMB/CIFS shares don't).
> >>
> >> execution of the script itself as root would explain why "root" becomes
> >> the owner though. Better to slap the 'sudo' into the command(s) that
> >> need it in the script, rather than running the whole script with sudo.
> >
> > You need to run as root if you want to be able to set the ownership,
> > either to match the original files. Otherwise, all files will end up
>
> Sure, but if he's "alan" on both hosts, then we're right back to "you
> don't need to run as root". (And ownership/permission capabilities
> of smb/cifs anyway).
>
I tried every combination but it only worked runnining as root.
HOWEVER, did you spot the chown=alan:alan among the rsync options?

--
Linux Mint 21.1 kernel version 5.15.0-78-generic Cinnamon 5.6.8

Re: rsync problem

<slrnudjtcs.f45.dan@djph.net>

  copy mid

https://www.novabbs.com/computers/article-flat.php?id=6650&group=alt.os.linux.mint#6650

  copy link   Newsgroups: alt.os.linux.mint
Path: i2pn2.org!i2pn.org!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: dan...@djph.net (Dan Purgert)
Newsgroups: alt.os.linux.mint
Subject: Re: rsync problem
Date: Mon, 14 Aug 2023 09:35:09 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 53
Message-ID: <slrnudjtcs.f45.dan@djph.net>
References: <20230808213925.b770a21a152e390fbdb9ebaf@gmail.com>
<slrnud5dpk.f45.dan@djph.net>
<20230809110225.c343fc7af7fda08ef0a1adc5@gmail.com>
<slrnud6pif.f45.dan@djph.net> <ub05q0$3v9gc$1@dont-email.me>
<slrnud7dil.f45.dan@djph.net>
<20230809212128.d44e3c6184159fd93315897c@gmail.com>
<slrnuda37a.f45.dan@djph.net> <ub3cg3$fl78$1@dont-email.me>
<slrnudc675.f45.dan@djph.net>
<20230812230943.ed1f236ff05481db47d00456@gmail.com>
Injection-Date: Mon, 14 Aug 2023 09:35:09 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="6f7a40f7015635873c433bdd8ecc8853";
logging-data="2371202"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+0Tko+E4hQLEjwaQZ+KWGQpU9/k3IZlME="
User-Agent: slrn/1.0.3 (Linux)
Cancel-Lock: sha1:EdW3nSMIAsln16SqmL1LPW8mY7M=
 by: Dan Purgert - Mon, 14 Aug 2023 09:35 UTC

On 2023-08-12, pinnerite wrote:
> On Fri, 11 Aug 2023 11:16:38 -0000 (UTC)
> Dan Purgert <dan@djph.net> wrote:
>
>> On 2023-08-10, Mark Bourne wrote:
>> > Dan Purgert wrote:
>> >> On 2023-08-09, pinnerite wrote:
>> >>> Just so it is clear, today completed a full backup of my work machine.
>> >>> It took many hours. The result was perfect.
>> >>>
>> >>> So this is an example of the mount statement and the rsync statememt.
>> >>> I have five of each running from the script that is executed from a sudo:
>> >>>
>> >>> mount -t cifs -o
>> >>> rw,noperm,user=alan,password=<my_password>,domain=ASANDCO,vers=1.0
>> >>> //192.168.1.66/alan/ /spare/churchill/alan/
>> >>>
>> >>> rsync -avz --exclude-from=/home/alan/Scripts/exclude.txt
>> >>> --chown=alan:alan --progress /home/alan/
>> >>> /spare/churchill/alan/
>> >>
>> >> huh, you shouldn't need the '--chown' switch here, with the '-a' flag
>> >> used. Furthermore, since you're sending it to a CIFS share, I'm
>> >> somewhat surprised it's retaining any of the unix ownership and mode
>> >> bits (normally, SMB/CIFS shares don't).
>> >>
>> >> execution of the script itself as root would explain why "root" becomes
>> >> the owner though. Better to slap the 'sudo' into the command(s) that
>> >> need it in the script, rather than running the whole script with sudo.
>> >
>> > You need to run as root if you want to be able to set the ownership,
>> > either to match the original files. Otherwise, all files will end up
>>
>> Sure, but if he's "alan" on both hosts, then we're right back to "you
>> don't need to run as root". (And ownership/permission capabilities
>> of smb/cifs anyway).
>>
> I tried every combination but it only worked runnining as root.
> HOWEVER, did you spot the chown=alan:alan among the rsync options?

Which is the part I'm having trouble resolving on several levels, as

- '-a' sets owner/group (although you were using a subset of this
switch at one point, so..)
- CIFS/SMB shares don't do UNIX ownership anyway
- If you hadn't run as root, the calling user (alan) would've been used
in the first place.

--
|_|O|_|
|_|_|O| Github: https://github.com/dpurgert
|O|O|O| PGP: DDAB 23FB 19FA 7D85 1CC1 E067 6D65 70E5 4CE7 2860

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor