#!/usr/bin/perl BEGIN { my $x = $0; $x =~ s/\/[^\/]+$//; if ($x eq $0 || $x eq '') { $x = `pwd`;chomp $x; }; require "$x/config.pl"; }; sub usage { print "usage: unset_ip_pointer ip ...\n"; exit 1; } my $ip = shift @ARGV; &usage if (!defined($ip)); my $ldap = &get_ldap_conn; while (scalar(@ARGV) > 0) { my $ipaddr = join('.', reverse split /\./, $ip) . '.in-addr.arpa'; $ldap->delete(&dn_domain($ipaddr)); $ip = shift @ARGV; }