DNS::Zoneparse

J

Jeff Kunzelman

I'm having trouble getting the Zoneparse module to update SOA records.
Can someone see what I'm doing wrong? There's a beer in if for you if
you can.

use DNS::ZoneParse;

my $zoneTemplateFile = DNS::ZoneParse->new("fwdTest.soa");

# Get a reference to the MX records
my $templateMx = $zoneTemplateFile->mx;
my %templateSOA = $zoneTemplateFile->soa;

#read in file of DNS informaton. Then repeat for every record in
the file

# begin zone file creation
# Change zone file attributes

%templateSOA = ( 'origin' => 'us-lbt-sn01-ice-rt01',
'primary' => 'primary',
'email' => 'email'
);

$templateMx->[0] = { host => 'mail.localhost.com',
priority => 10,
name => '@' };

# update the serial number
$zoneTemplateFile->new_serial();

print $templateSOA{'ttl'};



#write the new zone file to disk
open NEWZONE, ">zonefile2.db" or die "error";

print NEWZONE $zoneTemplateFile->output();
close NEWZONE;

#end zone file creation
 
G

Gunnar Hjalmarsson

Jeff said:
I'm having trouble getting the Zoneparse module to update SOA
records.

I have seen this question posted to three newsgroups in three
different messages. It's called multi-posting, and is considered rude.
Maybe you should give it a thought why that is the case...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

perl.modules 0
Code critique xmlrpclib 1
Net DNS Update problem 1
dns querry script. 4
Beginner: Data type conversion question 6
Dynamic DNS management 4
Fetching DNS MX and A records 2
about Net::DNS 0.47 2

Members online

No members online now.

Forum statistics

Threads
473,983
Messages
2,570,187
Members
46,747
Latest member
jojoBizaroo

Latest Threads

Top