how to properly edit hosts, hostname and resolf.conf?Putty can't connect over SSH to hostname, IP connection...
What does an unprocessed RAW file look like?
Calculate of total length of edges in Voronoi diagram
Square Root Distance from Integers
How do you get out of your own psychology to write characters?
Plausible reason for gold-digging ant
Potential client has a problematic employee I can't work with
What can I do to encourage my players to use their consumables?
Does a paladin have to announce that they're using Divine Smite before attacking?
Why is 'diphthong' pronounced the way it is?
Renting a 2CV in France
Microtypography protrusion with Polish quotation marks
Why do neural networks need so many training examples to perform?
What is the wife of a henpecked husband called?
Why do all the books in Game of Thrones library have their covers facing the back of the shelf?
Boss asked me to sign a resignation paper without a date on it along with my new contract
Is there a file that always exists and a 'normal' user can't lstat it?
Categorical Unification of Jordan Holder Theorems
Why are carbons of Inositol chiral centers?
Are the positive and negative planes inner or outer planes in the Great Wheel cosmology model?
Broad Strokes - missing letter riddle
I have trouble understanding this fallacy: "If A, then B. Therefore if not-B, then not-A."
What language shall they sing in?
Why is one not obligated to give up his life rather than violate Lashon Hara?
Custom shape shows unwanted extra line
how to properly edit hosts, hostname and resolf.conf?
Putty can't connect over SSH to hostname, IP connection worksSet up CentOS6 Web Server on local network, but unable to view websites on it?How to have a different hostname to the fqdn?After renaming system with hostname, mails sent no longer show correct domainBroswers open localhost instead of remote serverHow to point domain name to Amazon EC2 subdirectoryMixed network, Linux-to-Linux hostname resolution issuesunderstanding fqdns is troublingConfiguring /etc/hosts to run an applicationWhat is a hostname versus a computer name versus a subdomain versus www?
I have been searching the Internet for a real nop tutorial on the subject but could not found any direct info. on how to edit these files the proper way.
I have a Debian Internet server that I use to host some personal domains and runs Squid and rTorrent. The server is up and running with no problems. However, I am confused about a few things.
Lets say that I named my server (foo), my domain is (example.com) and my public IP is 95.211.133.200 now:
should /etc/hostname contains:
tango.example.com
or
tango <----- just the server name
should
/etc/hosts
contain:
127.0.0.1 localhost.localdomain localhost
95.211.133.200 foo.example.com foo
should
/etc/resolf.conf
contain (along with the name servers) both:
domain example.com
search example.com
or just the first one.
Are there any other files that I should edit in order to make things right?
last thing, the command:
domainname
returns: (none)
I believe it should return (example.com). What should I do to correct that?
linux hostname hosts
bumped to the homepage by Community♦ 4 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
migrated from serverfault.com Apr 2 '12 at 22:23
This question came from our site for system and network administrators.
add a comment |
I have been searching the Internet for a real nop tutorial on the subject but could not found any direct info. on how to edit these files the proper way.
I have a Debian Internet server that I use to host some personal domains and runs Squid and rTorrent. The server is up and running with no problems. However, I am confused about a few things.
Lets say that I named my server (foo), my domain is (example.com) and my public IP is 95.211.133.200 now:
should /etc/hostname contains:
tango.example.com
or
tango <----- just the server name
should
/etc/hosts
contain:
127.0.0.1 localhost.localdomain localhost
95.211.133.200 foo.example.com foo
should
/etc/resolf.conf
contain (along with the name servers) both:
domain example.com
search example.com
or just the first one.
Are there any other files that I should edit in order to make things right?
last thing, the command:
domainname
returns: (none)
I believe it should return (example.com). What should I do to correct that?
linux hostname hosts
bumped to the homepage by Community♦ 4 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
migrated from serverfault.com Apr 2 '12 at 22:23
This question came from our site for system and network administrators.
Your shift key appears to be broken.
– Chris S
Apr 2 '12 at 22:21
1
This sounds suspiciously like a homework assignment I once had. Anyway, all of these questions can be answered in man pages:resolv.conf(5)
,hostname(1)
andhosts(5)
– AdmiralNemo
Apr 2 '12 at 23:09
add a comment |
I have been searching the Internet for a real nop tutorial on the subject but could not found any direct info. on how to edit these files the proper way.
I have a Debian Internet server that I use to host some personal domains and runs Squid and rTorrent. The server is up and running with no problems. However, I am confused about a few things.
Lets say that I named my server (foo), my domain is (example.com) and my public IP is 95.211.133.200 now:
should /etc/hostname contains:
tango.example.com
or
tango <----- just the server name
should
/etc/hosts
contain:
127.0.0.1 localhost.localdomain localhost
95.211.133.200 foo.example.com foo
should
/etc/resolf.conf
contain (along with the name servers) both:
domain example.com
search example.com
or just the first one.
Are there any other files that I should edit in order to make things right?
last thing, the command:
domainname
returns: (none)
I believe it should return (example.com). What should I do to correct that?
linux hostname hosts
I have been searching the Internet for a real nop tutorial on the subject but could not found any direct info. on how to edit these files the proper way.
I have a Debian Internet server that I use to host some personal domains and runs Squid and rTorrent. The server is up and running with no problems. However, I am confused about a few things.
Lets say that I named my server (foo), my domain is (example.com) and my public IP is 95.211.133.200 now:
should /etc/hostname contains:
tango.example.com
or
tango <----- just the server name
should
/etc/hosts
contain:
127.0.0.1 localhost.localdomain localhost
95.211.133.200 foo.example.com foo
should
/etc/resolf.conf
contain (along with the name servers) both:
domain example.com
search example.com
or just the first one.
Are there any other files that I should edit in order to make things right?
last thing, the command:
domainname
returns: (none)
I believe it should return (example.com). What should I do to correct that?
linux hostname hosts
linux hostname hosts
edited Oct 8 '12 at 0:50
Linger
2,776102740
2,776102740
asked Apr 2 '12 at 22:16
FirewallFirewall
62
62
bumped to the homepage by Community♦ 4 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 4 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
migrated from serverfault.com Apr 2 '12 at 22:23
This question came from our site for system and network administrators.
migrated from serverfault.com Apr 2 '12 at 22:23
This question came from our site for system and network administrators.
Your shift key appears to be broken.
– Chris S
Apr 2 '12 at 22:21
1
This sounds suspiciously like a homework assignment I once had. Anyway, all of these questions can be answered in man pages:resolv.conf(5)
,hostname(1)
andhosts(5)
– AdmiralNemo
Apr 2 '12 at 23:09
add a comment |
Your shift key appears to be broken.
– Chris S
Apr 2 '12 at 22:21
1
This sounds suspiciously like a homework assignment I once had. Anyway, all of these questions can be answered in man pages:resolv.conf(5)
,hostname(1)
andhosts(5)
– AdmiralNemo
Apr 2 '12 at 23:09
Your shift key appears to be broken.
– Chris S
Apr 2 '12 at 22:21
Your shift key appears to be broken.
– Chris S
Apr 2 '12 at 22:21
1
1
This sounds suspiciously like a homework assignment I once had. Anyway, all of these questions can be answered in man pages:
resolv.conf(5)
, hostname(1)
and hosts(5)
– AdmiralNemo
Apr 2 '12 at 23:09
This sounds suspiciously like a homework assignment I once had. Anyway, all of these questions can be answered in man pages:
resolv.conf(5)
, hostname(1)
and hosts(5)
– AdmiralNemo
Apr 2 '12 at 23:09
add a comment |
1 Answer
1
active
oldest
votes
/etc/hostname
should have just foo
/etc/hosts
looks fine
/etc/resolv.conf
should probably be example.com
for both, depending on your use case. Note that you named it /etc/resolf.conf
and it should be v
and not f
I don't know about domainname
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f407827%2fhow-to-properly-edit-hosts-hostname-and-resolf-conf%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
/etc/hostname
should have just foo
/etc/hosts
looks fine
/etc/resolv.conf
should probably be example.com
for both, depending on your use case. Note that you named it /etc/resolf.conf
and it should be v
and not f
I don't know about domainname
add a comment |
/etc/hostname
should have just foo
/etc/hosts
looks fine
/etc/resolv.conf
should probably be example.com
for both, depending on your use case. Note that you named it /etc/resolf.conf
and it should be v
and not f
I don't know about domainname
add a comment |
/etc/hostname
should have just foo
/etc/hosts
looks fine
/etc/resolv.conf
should probably be example.com
for both, depending on your use case. Note that you named it /etc/resolf.conf
and it should be v
and not f
I don't know about domainname
/etc/hostname
should have just foo
/etc/hosts
looks fine
/etc/resolv.conf
should probably be example.com
for both, depending on your use case. Note that you named it /etc/resolf.conf
and it should be v
and not f
I don't know about domainname
answered Oct 8 '12 at 1:34
UtahJarheadUtahJarhead
1,6221815
1,6221815
add a comment |
add a comment |
Thanks for contributing an answer to Super User!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f407827%2fhow-to-properly-edit-hosts-hostname-and-resolf-conf%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Your shift key appears to be broken.
– Chris S
Apr 2 '12 at 22:21
1
This sounds suspiciously like a homework assignment I once had. Anyway, all of these questions can be answered in man pages:
resolv.conf(5)
,hostname(1)
andhosts(5)
– AdmiralNemo
Apr 2 '12 at 23:09