Perl scripts to automatically update zone files?

Will Yardley &- at
Mon Jun 24 17:41:16 UTC 2002

In article <af7las$fb99$1 at>, Crazy Diamond wrote:
> I have a box running apache and bind here at the University of
> Massachusetts Lowell and we want to set up apache and bind so that
> people can set up web sites automatically using virtual hosting
> through a perl script.  So, for example, say our domain name is
> and a user creates a website, the script would automatically
> create a virtual host in apache called
> The question to this group is, does anyone here know a PERL script
> that will automatically stop named, append the subdomain to the zone
> file i specify, and then restart the name daemon?

this is a good candidate for wildcard A records; for instance you could
*  IN A

in the zone file for

then you just have to write the perl script to determine which name the
site was called with and serve up the appropriate data....

an example would be

any A record that's not otherwise specified will return the same IP


No copies, please.
To reply privately, simply reply; don't remove anything.

More information about the bind-users mailing list