Bug#745876: Please create /etc/machine-id if it does not exist

Michael Biebl biebl at debian.org
Mon Apr 28 18:09:59 BST 2014


Am 28.04.2014 17:51, schrieb Santiago Vila:
> On Sat, 26 Apr 2014, Martin Pitt wrote:
> 
>> Santiago Vila [2014-04-26 12:16 +0200]:
>>> IMHO, such bug is ridiculous: On systems where systemd is the init
>>> manager, systemd becomes essential and you simply *don't* remove it!
>>
>> On Debian we support multiple init systems, so in theory a user could
>> install sysvinit or upstart or openrc etc., and afterwards purge
>> systemd. In that case I think it would be wrong to remove
>> /etc/machine-id, as on the next installation you would get a new one
>> and change the machine's ID.
> 
> Well, it could be argued that if you wanted to keep the machine ID,
> you would just remove (not purge) systemd the first time.
> 
> For now, /etc/machine-id is a configuration (or state) file for the
> systemd package. Documentation about machine-id even says that
> removing the file on reboots is mostly harmless (you could have a
> different machine-id every time the machine boots and nothing bad
> would happen).

Hm, I don't see this recommendation anywhere. The machine-id man page
[0] at least doesn't give any advice like this.
If you are going to change machine-id, this will treat old journal files
as coming from a different system. I wouldn't consider that a harmless
consequence.

> So, my recommendation (if you don't just ignore piuparts report)
> is that you actually remove it at purge.
> 
> The base-files package is Essential: yes, and it is currently
> Architecture: any, but that's mainly a way to make /etc/issue to be
> pretty looking (it says "Linux" only on Linux architectures). For all
> other purposes I would like to keep the base-files package as much
> "Architecture: all" as we can (both regarding .deb contents and also
> behaviour), and this file is not needed on every architecture yet.
> 
> (Moreover, there are people who dislike systemd with a passion. Forcing
> systemd files on machines not needing it is not going to be good
> publicity for systemd).
> 
> On the other hand, if you can show me another init system (which is
> not systemd) also using /etc/machine-id, we can reconsider about this.

The reason why we want to see /etc/machine-id in base-files is actually
because it is not only used by systemd, but e.g. also by dbus.

Say you've installed both dbus and systemd, dbus will read and use
/etc/machine-id. If you now purge the systemd package (and
/etc/machine-id along with it), this will confuse dbus.

Michael

[0] http://www.freedesktop.org/software/systemd/man/machine-id.html
-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 884 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-systemd-maintainers/attachments/20140428/f1c652e7/attachment-0002.sig>


More information about the Pkg-systemd-maintainers mailing list