Subject: | |
From: | |
Reply To: | |
Date: | Tue, 15 Mar 2016 08:32:35 -0400 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
On Tue, Mar 15, 2016 at 7:04 AM, Loris Bennett
<[log in to unmask]> wrote:
> Hi Benjamin,
>
> Benjamin Lefoul <[log in to unmask]> writes:
>
>> Hi Loris,
>>
>> On SL7, I believe hostnames are best set declaratively in the file
>> /etc/hostname (as has been the case for long on other distros). I
>> suspect the preferred imperative way to set hostname is with
>> "hostnamectl set-hostname" (check the man hostnamectl).
>>
>> Regards,
>>
>> Benjamin Lefoul
>> nWISE AB
>
> [snip (50 lines)]
>
> Ah, I should have said: I'm on SL 6.7 and 'hostnamectl' doesn't seem to
> be available.
>
> Cheers,
>
> Loris
"system-config-network-tui" works pretty well if installed.
The problem is that the $HOSTNAME for the system isn't published in
DNS, nor is it the first hostname for a line in /etc/hosts, so the
"hostname --fqdn" is not finding it associated with your IP addresses.
The usual approach for portable laptops is to put a line like this in
/etc/hosts somewhere.
127.0.0.1 mymachine.mydomain
Do *not* put this.
127.0.0.1 mymachine mymachine.mydomain
And do not touch the line for localhost, the way some installers do.
127.0.0.1 localhost.localdomain localhost localhost4.localdomain
localhost4 mymachine.mydomain mymachine
That last one is very common with a lot of bad, bad, software
installers and configuration tools. Use a *different line* for the
FQDN.
Note that some software also may work better if you have the hostname
tied to the systems's live IP addresses, but that's usually because
it's bad software.
|
|
|