Is this is a error ?

Quek Meng-Chong mengchong.quek at pacific.net.sg
Wed Feb 9 01:34:15 UTC 2000


Hi all

Here's a oneliner perl I've gotten from a colleague when I had to migrate
from BIND8.1.2 to 8.2.2P5.  Using Perl 5.

perl -ni.bak -e 'print "$TTL X\n" if /^\@\s+IN\s+SOA/; print' FILE

where X is the variable for $TTL in seconds and FILE is the zonefile you
want to modify.  The whole commands means that for the FILE you want to
edit, look for the SOA and edit in place the $TTL  X; a FILE.bak is
created as well.

Remove the .bak if you feel confident and use * instead for FILE to edit a
whole directory of zonefiles.

Hope this helps...

Cheerio
Meng-Chong

On Tue, 8 Feb 2000, Andy Walden wrote:

> No apology required. Thank you for the clarification.
> 
> andy
> 
> 
> 
> --
> -----------------------------------------------------------------------
> Andy Walden                        Work Email: andy at mtco.com.
> Network Administrator, 		   Pers Email: andy at netimagination.com.
> MTCO Communications		   Phone: (800) 859-6826
> "A little nonsense now and then, is relished by the wisest men."
> 						-Willi Wonka
> 
> 
> On Tue, 8 Feb 2000, Quek Meng-Chong wrote:
> 
> > Hi Andy
> > 
> > My apologies for not making myself clear.  All that is need is to prepend
> > a $TTL X (where X is a variable in seconds) before the SOA in each zone
> > file and BIND will work fine.
> > 
> > What I meant by the complaining bit is that without the $TTL X, BIND will
> > complain but the zonefile is still reloaded properly and accepted by BIND.
> > Hope I made myself clear on this.  My apologies once again.
> > 
> > Cheerio
> > Meng-Chong
> > 
> > On Tue, 8 Feb 2000, Andy Walden wrote:
> > 
> > > So what would be the correct way to do it so that BIND doesn't complain
> > > AND works?
> > > 
> > > andy
> > > 
> > > --
> > > -----------------------------------------------------------------------
> > > Andy Walden                        Work Email: andy at mtco.com.
> > > Network Administrator, 		   Pers Email: andy at netimagination.com.
> > > MTCO Communications		   Phone: (800) 859-6826
> > > "A little nonsense now and then, is relished by the wisest men."
> > > 						-Willi Wonka
> > > 
> > > 
> > > On Tue, 8 Feb 2000, Quek Meng-Chong wrote:
> > > 
> > > > Hi Abdul
> > > > 
> > > > You need to have a default TTL entry with the following parameters before
> > > > the SOA of the zonefile.
> > > > 
> > > > $TTL   X
> > > > 
> > > > where X is the default TTL value in seconds.  BIND will complain but
> > > > works.
> > > > 
> > > > Cheerio
> > > > Meng-Chong
> > > > 
> > > > On Tue, 8 Feb 2000, Abdul Rehman Saeed wrote:
> > > > 
> > > > > Hello alls,
> > > > > 
> > > > > I am using 8.2.2-P5.
> > > > > Can any body explain this................
> > > > > 
> > > > >  No default TTL set using SOA minimum instead
> > > > > 
> > > > > Best Regards
> > > > > 
> > > > > 
> > > > > 
> > > > > 
> > > > > 
> > > > > 
> > > > 
> > > > Quek Meng-Chong         mengchong.quek at pacific.net.sg 
> > > > Network Engineer	Pacific Internet Limited 
> > > > 
> > > > "Two roads diverged in a wood, and I --
> > > >  I took the one less traveled by,
> > > >  And that has made all the difference"
> > > > 
> > > > Robert Frost: The Road Not Taken (1915)
> > > > 
> > > > 
> > > > 
> > > 
> > > 
> > 
> > Quek Meng-Chong         mengchong.quek at pacific.net.sg 
> > Network Engineer	Pacific Internet Limited 
> > 
> > "Two roads diverged in a wood, and I --
> >  I took the one less traveled by,
> >  And that has made all the difference"
> > 
> > Robert Frost: The Road Not Taken (1915)
> > 
> > 
> > 
> 
> 

Quek Meng-Chong         mengchong.quek at pacific.net.sg 
Network Engineer	Pacific Internet Limited 

"Two roads diverged in a wood, and I --
 I took the one less traveled by,
 And that has made all the difference"

Robert Frost: The Road Not Taken (1915)




More information about the bind-users mailing list