LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-27-2004, 06:54 PM   #1
silvereye
LQ Newbie
 
Registered: Aug 2004
Location: latvia
Posts: 7

Rep: Reputation: 0
need to add static dns record


hi

recently i set up a router with multiple services running including named

i use bind 9.2.2
and i need to add STATIC or permament record to dns cache.
(domain name that is NOT actualy registred)
my rooter acts as a DNS server for all subnet an this hostname must be used by all network users behind my rooter

host ftp.something.com -->> aaa.bbb.ccc.ddd

looks pretty easy but i cant do it for about 24 hours

i have no will to read all n x hundred page manual for named.conf
no time for that

i have pretty good knowlege about linux and all that stuff - but this simple thing i dont understand

tryed to add records to named.ca

ftp.domain.com IN A aaa.bbb.ccc.ddd

doesnt help!

someone help!

ps im running bind 9.2.2 on slackware 9.0
 
Old 08-27-2004, 09:17 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
Re: need to add static dns record

Quote:
Originally posted by silvereye
i have no will to read all n x hundred page manual for named.conf
no time for that
Now that's not a very good attitude to have.. I'd suggest reading the man pages and howto's on named and bind. It can be very complicated and it would benefit you to know these things, instead of getting the quick answer on knowing really only one thing with your DNS server..
 
Old 09-01-2004, 11:28 AM   #3
silvereye
LQ Newbie
 
Registered: Aug 2004
Location: latvia
Posts: 7

Original Poster
Rep: Reputation: 0
Angry

im sorry but this forum really sucks or at least people who ar posting replies

forums are made to let people help each other.


to trickykid

if you have red bind manual you could suggest me tu read for example part X or you could post an URL

but you are saying that i need to read manual - I KNOW THAT
but as i told u i have no time for that

YOU ARE NOT HELPING ME!!!

next time leave your message unposted

a would be thankful to someone who would say: edit file xxx, add line blablabla, restart server - or something like this!
 
Old 09-01-2004, 12:05 PM   #4
mikedeatworld
Member
 
Registered: Nov 2003
Location: Farmington Michigan
Distribution: UBUNTU - Slackware - SuSE 9.1 - Knoppix - Fedora
Posts: 828

Rep: Reputation: 30
don't think that will help you get your answer....

and what trickykid suggested wasn't a bad suggestion...
 
Old 09-01-2004, 12:20 PM   #5
nitin_batta
Member
 
Registered: Aug 2004
Location: India
Distribution: Redhat Enterprise Server 2.1
Posts: 96

Rep: Reputation: 15
Hi Dude,

Say something.com is your domain name and ftp.something.com is a host having a statc ip.

This is what you need to do

edit /etc/named/named.conf to add the zone for something.com

<code>
zone "something.com" {

type master;
notify no;

allow-query { any; };
file "something.zone";
};

</code>

Now Place the record in the file named something.zone in /var/named (the location of files may depend on the distro too)

You can just use the find command to locate them.

A sample something.zone file :


<code>
; Zone file for something.com
@ IN SOA ns0.something.com. hostmaster.something.com. (

200211152 ; serial#

3600 ; refresh, seconds

3600 ; retry, seconds

3600 ; expire, seconds

3600 ) ; minimum, seconds

;

NS www ; Inet Address of nameserver
localhost A 127.0.0.1
ftp A aaa.bbb.ccc.ddd
</code>

Give a restart to the named and just check the logs to make sure that named starts without any eroors.

This is all you would need to do.


.... Nitin Batta ....
http://nitinb.blogspot.com

__________________
If this helped you, please take the time to rate the value of this post by clicking the affero button
 
Old 09-07-2004, 09:11 AM   #6
silvereye
LQ Newbie
 
Registered: Aug 2004
Location: latvia
Posts: 7

Original Poster
Rep: Reputation: 0
thanks nitin_batta!!

ill try this!

if this will help ill rate your reply
 
Old 09-07-2004, 11:01 AM   #7
silvereye
LQ Newbie
 
Registered: Aug 2004
Location: latvia
Posts: 7

Original Poster
Rep: Reputation: 0
hi nitin_batta!

i must say you helped me but no for 100%)

lines in zonefile:

NS www ; Inet Address of nameserver
localhost A 127.0.0.1
ftp A aaa.bbb.ccc.ddd

was not understood by bind eather by me
(ofcourse i changed aaa.bbb.ccc.ddd to my IP))

so i changet them (somehow i figured out )

@ NS ns0.something.com.
ftp.something.com. IN A aaa.bbb.ccc.ddd

(i actually added extra lines like hub.something.com. IN A aaa.bbb.ccc.ddd etc)

and everything runs!!

i must say this dns config thing is made so ununderstandabe that
only the man who wrote this server can understand all that entirely (maybe)

well ok i ll rate your reply
 
Old 12-18-2004, 08:20 AM   #8
Soulstealer
Member
 
Registered: Dec 2004
Location: Necropolis
Distribution: FreeBSD
Posts: 47

Rep: Reputation: 15
?

Well, this doesn't work for me. When I edit my named.conf and kill the named to start it again it just doesn't start.My namd can't start when the named.conf is changed.When I delete the extra lines in named.conf and start named, it runs.
Here is what I'm writing:
I'm adding this to named.conf
Quote:
zone "soulstealer.org" {
type master;
notify no;
allow-query { any; };
file "soulstealer.zone";
};
I have zone file in /var/named
and it looks like:
Quote:
; Zone file for soulstealer.org
@ IN SOA ns0.soulstealer.org. hostmaster.soulstealer.org. (

200211152 ; serial#

3600 ; refresh, seconds

3600 ; retry, seconds

3600 ; expire, seconds

3600 ) ; minimum, seconds

;

NS www ; Inet Address of nameserver
localhost A 127.0.0.1
ftp A 192.168.10.1
Can anyone help me ?
btw I'm using slackware10.0
 
Old 12-19-2004, 02:29 AM   #9
nitin_batta
Member
 
Registered: Aug 2004
Location: India
Distribution: Redhat Enterprise Server 2.1
Posts: 96

Rep: Reputation: 15
Quote:
Well, this doesn't work for me. When I edit my named.conf and kill the named to start it again it just doesn't start.My namd can't start when the named.conf is changed.When I delete the extra lines in named.conf and start named, it runs.
What is the error message you get in the logs when you try to start named and what extra lines do you delete to start the named deamon.
This would help in better debugging.
 
Old 12-19-2004, 09:58 AM   #10
Soulstealer
Member
 
Registered: Dec 2004
Location: Necropolis
Distribution: FreeBSD
Posts: 47

Rep: Reputation: 15
Well I realized my syntax error in named.conf
now the daemon is running, but it's working in the old way. When I write soulstealer.org in the browser on machine in my local net, I get the message "This page cannot be displayed"
here is the zone file I tried:
Code:
; Zone file for soulstealer.org
@ IN SOA ns0.soulstealer.org. hostmaster.soulstealer.org. (

200211152 ; serial#

3600 ; refresh, seconds

3600 ; retry, seconds

3600 ; expire, seconds

3600 ) ; minimum, seconds

;

@ NS ns0.soulstealer.org.
soulstealer.org. IN A 192.168.10.1
I also tried with this kind:
Code:
; Zone file for soulstealer.org
@ IN SOA ns0.soulstealer.org. hostmaster.soulstealer.org. (

200211152 ; serial#

3600 ; refresh, seconds

3600 ; retry, seconds

3600 ; expire, seconds

3600 ) ; minimum, seconds

;

NS www ; Inet Address of nameserver
localhost A 127.0.0.1
ftp A 192.168.10.1
but no success
Can you help me, please?

P.S. here are the extra lines in named.conf:
Code:
zone "soulstealer.org" {
      type master;
      notify no;
      allow-query { any; };
      file "soulstealer.zone";
};
 
Old 12-20-2004, 10:49 AM   #11
Soulstealer
Member
 
Registered: Dec 2004
Location: Necropolis
Distribution: FreeBSD
Posts: 47

Rep: Reputation: 15
OK, I got it!
Now can anyone tell me how to set subdomains?
my zone file looks like:
Code:
$ORIGIN .
$TTL 14400
soulstealer.org       IN      SOA    soulstealer.org. root.soulstealer.org. (
                       20040647        ; serial
                       28800           ; refresh (8 hours)
                       7200            ; retry (2 hours)
                       864000          ; expire (1 week 3 days)
                       86400           ; minimum (1 day)
                       )
                       NS      ns.soulstealer.org.
                       MX      10 soulstealer.org.
                       A       192.168.10.1
$ORIGIN soulstealer.org
something 228800 IN A 192.168.10.1
this works for soulstealer.org to be resolved to 192.168.10.1
I'm asking how to do this to work like:
something.soulstealer.org to be resolved to 192.168.10.1/something (or again 192.168.10.1)
or to another IP (e.g. something.soulstealer.org <--> 192.168.10.2)
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Bind DNS record macadam Linux - Networking 4 06-11-2005 08:18 AM
howto add filename to each record? kscott121 Programming 4 09-14-2004 10:13 AM
ADD an auto DNS record ! freelinuxcpp Linux - Software 1 01-25-2004 02:16 AM
DNS & A-Record with my domain name fquinteros Linux - Newbie 1 09-02-2003 01:40 AM
Free DNS record?... BCE_HAMAHA General 5 03-26-2002 03:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:30 AM.

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