From: Pavel Machek <pavel@ucw.cz>
To: Dan Moulding <dmoulding@me.com>
Cc: linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org,
tglx@linutronix.de, akpm@linux-foundation.org, corbet@lwn.net
Subject: Re: [PATCH v2 0/1] Allow setting hostname before userspace starts
Date: Fri, 6 May 2022 09:23:23 +0200 [thread overview]
Message-ID: <20220506072322.GA3925@amd> (raw)
In-Reply-To: <20220506060310.7495-1-dmoulding@me.com>
[-- Attachment #1: Type: text/plain, Size: 651 bytes --]
Hi1
> Some userspace processes may rely on gethostname to always return the
> correct machine name. However, the only way that the hostname may be
> set is by some other userspace process calling sethostname
> first. During boot, if a process that depends on gethostname runs
> before sethostname has been called, then the process that called
> gethostname is going to get an incorrect result.
Don't do that, then? :-).
init gets passed command line parameters kernel did not use. So init
can do that easily. Plus, there's initrd.
Best regards,
Pavel
--
People of Russia, stop Putin before his war on Ukraine escalates.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]
next prev parent reply other threads:[~2022-05-06 7:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-06 6:03 [PATCH v2 0/1] Allow setting hostname before userspace starts Dan Moulding
2022-05-06 6:03 ` [PATCH v2 1/1] init: Add "hostname" kernel parameter Dan Moulding
2022-05-06 7:23 ` Pavel Machek [this message]
2022-05-06 15:44 ` [PATCH v2 0/1] Allow setting hostname before userspace starts Dan Moulding
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220506072322.GA3925@amd \
--to=pavel@ucw.cz \
--cc=akpm@linux-foundation.org \
--cc=corbet@lwn.net \
--cc=dmoulding@me.com \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).