[systemd-devel] Antw: Re: Antw: Re: Binary changed since start

Ulrich Windl Ulrich.Windl at rz.uni-regensburg.de
Thu Dec 12 11:26:40 UTC 2019


>>> Lennart Poettering <lennart at poettering.net> schrieb am 12.12.2019 um 11:37
in
Lennafrt,

please review: I had been raising doubts to the statement "would not work if
the file was just rewritten", saying "Did you ever try to overwrite a
dynamically loaded file?".

Then you responded: "Your package manager does that all the time."

Completely independent from the following disagreeing opinions, my former
statement that it's not possible to overwrite a file that is demand-paged
(formulated as a polite question), was _not_ proven false. I was just raising
my surprise to the fact that nobody seems to understand what demand-paged
means. YOU (not me) used the "fool" term, so please re-read.

Regards,
Ulrich



Nachricht <20191212103704.GB20337 at gardel-login>:
> On Do, 12.12.19 07:53, Ulrich Windl (Ulrich.Windl at rz.uni‑regensburg.de)
wrote:
> 
>> >> > Well. This specifically may be doable by checking if any file open by
>> >> > process is marked deleted, but would not work if the file was just
>> >> > rewritten...
>> >>
>> >> Did you ever try to overwrite a dynmically loaded file? I doubt it
>> >> is possible for obvious reasons.
>> >
>> > Your package manager does that all the time. It's possible and common
>> > case.
>>
>> Seems you are all MS‑Windows guys: If the package manager would overwrite
>> existing files, there'd be no reason to restart any process. What the 
> package
>> manager does is to unlink the name from the inode and then recreate a new 
> inode
>> assigning the same name. If you don't understand this difference, you
don't
>> understand how UNIX works. I'm kind of shocked to read such nonsense in
this
>> list.
> 
> Oh, man, you are getting on my nerves. So first of all, in systemd all
> regular files we ever write are written in this "atomic style",
> i.e. write out the new version under a temporary name, and move it
> into place with rename() atomically.
> 
> Secondly, your premise that "if the package manager would overwrite
> existing files, there'd be no reason to restart any process" (by which
> you apparently mean "keep the inode, overwrite blocks") is just
> so weird, that I don't even know where to start...
> 
> Anyway, every now and then please assume we are not complete
> fools. Thank you,
> 
> Lennart
> 
> ‑‑
> Lennart Poettering, Berlin





More information about the systemd-devel mailing list