Page 1 of 1

Set computer and domain name

Posted: Fri Feb 08, 2013 10:00 am
by alwe
I recently installed Raspbian (2012-12-16-wheezy-raspbian) and need to be recognized in the company's AD to be able to get network access. Have tried to find how to set the computer name and domain name, but cant't find where (new to linux).

The computer name should be A93 and the domain Ao.local , since it already has been added in the AD.

Tried to add the hostname through sudo nano etc/hosts, but the file does not seem to exist.?

Re: Set computer and domain name

Posted: Fri Feb 08, 2013 11:01 am
by RaTTuS
not sure about AD
but the files should be
/etc/hosts

Re: Set computer and domain name

Posted: Fri Feb 08, 2013 6:58 pm
by DBryant
/etc/hostname defines the system's name and /etc/resolv.conf the domain details. Both are text files that may be modified with your favourite editor.

The network environment of hosts is defined in /etc/hosts; note the leading /

You may find the means to set these from your desktop manager under Administration > Network

Re: Set computer and domain name

Posted: Tue Feb 12, 2013 8:53 pm
by alwe
Great, thanks! Works like a charm!

Re: Set computer and domain name

Posted: Tue Feb 12, 2013 9:07 pm
by DBryant
Nice to hear. Good luck.

Re: Set computer and domain name

Posted: Wed Feb 13, 2013 7:49 am
by socialdefect
If you like quick and dirty there's also this one:

Code: Select all

sudo hostname your.hostname.here
This will set a fully qualified hostname (FQDN) too, have a look:

Code: Select all

hostname -f