hostname setting in rc.conf ignored?

Mike Barborak mab2001 at gmail.com
Thu May 17 19:23:26 UTC 2007


Thanks for the suggestions.

That's right, I'm not using DHCP.

I searched through /etc and /usr/local/etc for calls to hostname and for the
string www.mydomain.com and all I found was a call to the command "hostname"
in /etc/rc.network and my setting of the hostname variable in /etc/rc.conf.
After perusing /etc, apparently rc.network is called by /etc/rc after
sourcing rc.conf and this is how the hostname in /etc/rc.conf becomes the
hostname of the machine. So that appears to be fine.

Perhaps another tack, what is the last script executed during boot up? If I
add a line like "/bin/hostname www.mydomain.com" to /etc/rc.local should
this force the hostname change?

Thanks,
Mike



On 5/17/07, Mark Tinguely <tinguely at casselton.net> wrote:
>
>
> I understand DHCP setting the hostname, which you are not using.
> I understand DNS or /etc/hosts reporting the old name on the network,
> but it should not effect hostname.
>
> I would look for the old name:
>
>         # grep -r mydomain.com /etc
>
> --Mark Tinguely
>


More information about the freebsd-questions mailing list