Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Accessing data directly from BSC

by Tech21 (Initiate)
on May 04, 2012 at 10:11 UTC ( #968903=perlquestion: print w/replies, xml ) Need Help??
Tech21 has asked for the wisdom of the Perl Monks concerning the following question:

What is the purpose of CLI for accessing a node and how to use it??? Plz help me out in making the Perl script for the purpose... BSC is "BASE STATION CONTROLLER " which has some external fault indications through alarms. In bsc we work on windows platform. so we need to fetch these alarms data from bsc and save it in a folder. The script is based of directly fetching the data from the node with bypassing the oss server(INTELLIGENT SERVER) and accessing the node through router path .
#!perl use strict; use warnings; use Time::Local; use Net::CLI; # Create the object instance for Telnet $cli = new Net::CLI('TELNET'); $NAME = "BSC14"; # Connect to host $cli->connect('HOSTNAME'); # Perform login $cli->login( Username => $USERNAME, Password => $PASSWORD, ); $cli->SearchAndExec('Windows NT Domain:'); $cli->print('\n'); $cli->system('C:\WINNT\Profiles\PATHNAME OF BSC>'); # Send a command and read the resulting output $output = $cli->cmd("mml"); print $output; $cli->print('\n'); $cli->cmd("allip;"); open ALLIP,">c:\\mm1\\log\\$NAME.txt"; @output = $cli->system('/<$/i'); $cli->cmd("exit"); $cli->system('C:\WINNT\Profiles\PATHNAME OF BSC>'); $cli->cmd("exit"); print ALLIP "$NAME\t"; print ALLIP @output; close(ALLIP); $cli->disconnect;
THE problem i am facing is that it is not logging to the node . the second problem is that it is making the .txt file in the log folder but .txt file is empty without any alarms. plz help me out in this .thanks !

Replies are listed 'Best First'.
Re: Accessing data directly from BSC
by marto (Bishop) on May 04, 2012 at 10:17 UTC

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://968903]
Approved by kcott
and the monks are mute...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (2)
As of 2017-09-23 05:00 GMT
Find Nodes?
    Voting Booth?
    During the recent solar eclipse, I:

    Results (270 votes). Check out past polls.