|< 1 2 3 >| | 28 Einträge, 3 Seiten |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
sub ripout
{
my $a = "$path/log/".$host."-".$wan."_in.stat";
my $b = "$path/log/".$host."-".$wan."_out.stat";
my $session = Net::Telnet::Netscreen->new(
Host => $wan,
Timeout => "90",
Input_log => $a,
Output_log => $b
);
#einloggen auf der CPE
$session->login('xy', 'zzzzz');
$a="set vrouter trust-vr";
$b="unset protocol rip";
$c="y";
$f="exit";
$d="save";
$e="exit";
$session->cmd($a);
$session->cmd($b);
$session->cmd($c);
$session->cmd($f);
$session->cmd($d);
$session->cmd($e);
$session->close;
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
$session->login('xy', 'zzzzz');
$a="set vrouter trust-vr";
$b="unset protocol rip";
$c="y";
$f="exit";
$d="save";
$e="exit";
$session->cmd($a);
$session->cmd($b);
$session->waitfor('/deleting RIP instance, are you sure? y\/[n] /') or die " Error getting \"deleting RIP instance, are you sure? y/[n]\" prompt: $!";
$session->cmd($c);
$session->cmd($f);
$session->cmd($d);
$session->cmd($e);
$session->close;
1
2
3
4
5
6
Herzlich Willkommen, Sie befinden sich auf Router XXXXX
login: xy
password:
9999999999-> set vrouter trust-vr
9999999999(trust-vr)-> unset protocol rip
deleting RIP instance, are you sure? y/[n]
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
$session->login('xy', 'zzzzz');
$command1="set vrouter trust-vr";
$command2="unset protocol rip";
$command3="y";
$command4="exit";
$command5="save";
$command6="exit";
$session->cmd($command1) or die " Error giving \"set vrouter trust-vr\" command: $!";
$session->cmd($command2) or die " Error giving \"unset protocol rip\" command: $!";
$session->waitfor('/deleting RIP instance, are you sure? y\/[n]/') or die " Error getting \"deleting RIP instance, are you sure? y/[n]\" prompt: $!";
$session->cmd($command3) or die " Error giving \"y\" command: $!";
$session->cmd($command4) or die " Error giving \"exit\" command: $!";
$session->cmd($command5) or die " Error giving \"save\" command: $!";
$session->cmd($command6) or die " Error giving \"exit\" command: $!";
$session->close;
|< 1 2 3 >| | 28 Einträge, 3 Seiten |