]> git.sesse.net Git - nms/blobdiff - web/smanagement.pl
Add logging to mbd.
[nms] / web / smanagement.pl
index b900f1ea53e140d0c45460c0f7dd5d7c41052866..ed783b2fa915b245f821f92c9d19675416df061c 100755 (executable)
@@ -22,22 +22,6 @@ my $sgetip = $dbh->prepare("SELECT ip FROM switches WHERE sysname = ?")
        or die "Could not prepare sgetip";
 my $sgid = $dbh->prepare("SELECT nextval('squeue_group_sequence') as gid");
 
-# Send a command to switch and return the data recvied from the switch
-sub switch_exec($$) {
-       my ($cmd, $conn) = @_;
-
-       # Send the command and get data from switch
-       my @data = $conn->cmd($cmd);
-       my @lines = ();
-       foreach my $line (@data) {
-               # Remove escape-7 sequence
-               $line =~ s/\x1b\x37//g;
-               push (@lines, $line);
-       }
-
-       return @lines;
-}
-
 sub parse_range($) {
        my $switches = $_;
        my @range;