LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-05-2003, 06:00 PM   #1
MrCarl
LQ Newbie
 
Registered: Sep 2003
Posts: 17

Rep: Reputation: 0
Resolving Hostname on Slackware


Ive recently setup a slackware linux server for testing some things on, its only on a LAN so I wasnt worrying too much about the hostname so I had set it up as

subdomain.mydomain.co.uk

But I havnt set that up on a DNS server anywhere cos I wasnt worried about it having to actually resolve to the server.

Now I just come to setup MySQL and it says the hostname could not be looked up, does this mean I need to make sure the above domain resolves to the IP address of the Server?

The only problem I have with that is that the server is behind a NAT router so it has a local IP, so unless I expose the server to the internet directly (which I didnt want to do) I cannot get it to resolve.

Anyway round this?

- Carl S
 
Old 11-05-2003, 06:06 PM   #2
DavidPhillips
LQ Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,163

Rep: Reputation: 58
put the ip address and hostname of the server in your /etc/hosts file
 
Old 11-05-2003, 06:30 PM   #3
MrCarl
LQ Newbie
 
Registered: Sep 2003
Posts: 17

Original Poster
Rep: Reputation: 0
Kinda sorted... had to put this in the hosts file

192.168.1.100 subdomain

How come it wasnt working when it just had this in the hosts file??

192.168.1.100 subdomain.mydomain.co.uk

Because the actual hostname is this 'subdomain.mydomain.co.uk' but at the shell prompt I just get root@subdomain

Is this right?

Id have expected it to all follow the full hostname which is setup for the server...

- Carl S
 
Old 11-05-2003, 06:39 PM   #4
DavidPhillips
LQ Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,163

Rep: Reputation: 58
Actually the hostname is what is to the left of the first dot and I would think the other part is a domainname.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Slow Resolving Hostname in any browser elias4444 Debian 1 09-10-2004 11:12 AM
hostname updated, but not resolving ericnmu Linux - Networking 5 09-09-2004 05:34 AM
Slow resolving DNS Hostname rmainville Linux - Networking 3 09-03-2004 11:16 AM
problems resolving Yahoo! mail under Slackware stibbons Slackware 11 02-11-2004 01:29 PM
/etc/hosts resolving before DNS resolving ? markraem Linux - Networking 4 11-02-2003 04:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:41 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration