Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 

LMS3.2 connection to databases

I created the DSN's as described in the procedure and when I click the test button they says it OK

However if I use an application to connect to these DSN's it says generic:

[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified (SQL-IM002)

I reused the script for local connections to work on a remote via the ODBC but it says the same as other applications when they try to hook up to the DSN

use DBI;

my ($dbh, $cur, $sqlstr);
my $connString = "dsn=cmf;uid=lmsdatafeed";

$dbh = DBI->connect('DBI:ODBC:DSN', $connString, 'didata', {PrintError => 1});

if ($dbh) {

   my $sqlstr = "SELECT Device_Id, Device_Display_Name, Management_IPAddress FROM Network_Devices";
   my $cur = $dbh->prepare($sqlstr);

   $cur->execute if ($cur);

   while (my $rs = $cur->fetchrow_arrayref) {
      my ($devId, $dispName, $ip,) = @$rs;
      print "Device_Id: $devId\n";
      print "Device_Display_Name: $dispName\n";
      print "Management_IPAddress: $ip\n";
      print "--------------------------------------------\n";
   }

   $cur->finish;
   $dbh->disconnect();

}

Does anyone see what I miss here?

Cheers,

Michel

Everyone's tags (4)
5 REPLIES
Cisco Employee

Re: LMS3.2 connection to databases

What are all of the parameters you specified for the cmf data source?

Re: LMS3.2 connection to databases

Let's start with ani

on the tab ODBC

Data source name:      ani

Descrioption:              ani

on the tab Login

User ID:                      lmsdatafeed

Password:                  didata

on the tab Database

Server Name:              aniEng

Database name:          aniDb

on the tab Network

TCP/IP:                       HOST=wk3-lms;DOBROADCAST=NO;ServerPort=43443

and cmf

on the tab ODBC

Data source name:      cmf

Descrioption:              cmf

on the tab Login

User ID:                      lmsdatafeed

Password:                  didata

on the tab Database

Server Name:              cmfEng

Database name:          cmfDb

on the tab Network

TCP/IP:                       HOST=wk3-lms;DOBROADCAST=NO;ServerPort=43441

Cisco Employee

Re: LMS3.2 connection to databases

Within the ODBC properties, you don't need to specify the username/password.  That is set when you run the dbaccess.pl script on the server.  Other than that everything looks okay.  Make sure you can telnet to TCP port 43441 from the client to the server.

Re: LMS3.2 connection to databases

Thanks Joe,

I thought the "Test Connection" button may need a username/password

Telnet to that port works.

Can't drop that session from the cli it seems

Cheers,

Michel

Cisco Employee

Re: LMS3.2 connection to databases

All of this checks out.  Make sure the proper DLLs are installed on the client per the database access instructions.  You can also try sniffing the traffic between the client and server to see if a connection is being attempted.  If not, this could point to a client ODBC issue.  You might try starting over on a new client to rule out any problems.

519
Views
0
Helpful
5
Replies
CreatePlease to create content