Database Monitor: ODBC DSN not found

Support, Questions and Discussions on MonitorWare Agent

Moderator: alorbach

Google Ads


Database Monitor: ODBC DSN not found

Postby mongoose » Wed Dec 05, 2012 12:13 am

HI guys, I'm having a hard time getting the MonitorWare Agent Database Monitor to connect to my MSSQL database. I've successfully created and tested both a user DSN and a system DSN using the MS ODBC Data Source tool from within Monitorware Agent with no luck. Looks like MW can't find the DB connector even though it's there. The error reported from MW is "Data source name not found" (see below). The ODBC executable called from MW Agent is "odbccad32.exe", same as the one being executed from Windows' Data Sources (ODBC) tool. Is this a 32bit vs 64bit arch issue? There is no 64-bit ODBC tool in Windows 7 SP1.

Particulars:
Windows 7, SP1 64-bit
MonitorWare Agent; Build 419, agent ver 8.2.419, client ver 8.2.1358
DB is remote MSSQL, using integrated AD security
AD credentials are tested OK, can connect and pull from the DB with another client

Any help you can give is most appreciated!
Thanks,
Chuck

==============================================================
Log Name: Application
Source: AdisconMonitoreWareAgent
Date: 12/4/2012 1:51:37 PM
Event ID: 120
Task Category: None
Level: Error
Keywords: Classic
User: N/A
Computer: <hostname>
Description:
An ODBC Error occured in DB Monitor occured. Please check the select statement, table name and ID field in your configuration!

CMiscODBCHelper|ODBC Error 'SQLDriverConnect failed'
ODBC Error Code: 'IM002'
ODBC Error Description: '[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified'
See http://www.winsyslog.com/en/FAQ/odbc-error-codes.asp for more informations on ODBC Error codes
mongoose
New
 
Posts: 5
Joined: Tue Dec 04, 2012 9:45 pm

Re: Database Monitor: ODBC DSN not found

Postby alorbach » Wed Dec 05, 2012 10:34 am

Hi,

MonitorWare Agent Client should open the 64bit Version of odbccad32.exe automatically , even if the executable is called "odbccad32.exe".
The 32bit version is usually located in "C:\windows\syswow64", and the 64bit version in "C:\windows\system32\".

However, can you confirm that the System-DSN is available when you run C:\windows\syswow64\odbccad32.exe manually?

best regards,
Andre Lorbach
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Re: Database Monitor: ODBC DSN not found

Postby mongoose » Wed Dec 05, 2012 4:24 pm

Oh OK, thanks for the clarification, I had those reversed in my head. So OK, I manually ran the 32bit version of odbccad32.exe from sysWOW64, made a System DSN, and specified this instance in the Database Monitor config. I was happy to see a different error:

CMiscODBCHelper|ODBC Error 'SQLDriverConnect failed'
ODBC Error Code: 'IM014'
ODBC Error Description: '[Microsoft][ODBC Driver Manager] The specified DSN contains an architecture mismatch between the Driver and Application'
See http://www.winsyslog.com/en/FAQ/odbc-error-codes.asp for more informations on ODBC Error codes


...which indicates it can't load any 32bit ODBC drivers (what we'd expect on a 64-bit OS), but it did see the DSN.

Thanks For the assistance @alorbach
mongoose
New
 
Posts: 5
Joined: Tue Dec 04, 2012 9:45 pm

Re: Database Monitor: ODBC DSN not found

Postby alorbach » Wed Dec 05, 2012 4:31 pm

Hi,

but you should have to create 32Bit System DSN's at all on 64Bit Windows. This is strange, because we install a 64bit Version of MonitorWare Agent 8.x.
Can you confirm that the mwagent.exe file in your installation is the 64bit Version? You should be able to verify this using the taskmanager, show all processes. mwagent.exe should NOT have a *32 at the end.

best regards,
Andre
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Re: Database Monitor: ODBC DSN not found

Postby mongoose » Wed Dec 05, 2012 6:22 pm

Looks right in task manager:

mwagent.exe, running as SYSTEM
MWClient.exe *32, running as <my AD user>

In addition, I restarted everything, blew away all my defined DSNs, and reconfigured with one new revelation:
When I configured a user DSN into Database Monitor, I got the same "DSN not found" error. But when I configured a system DSN, I got:

ODBC Error Code: '28000'
ODBC Error Description: '[Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user 'DOMAIN\HOSTNAME$'.'


Which is good, that means it can see something. The user DSN is visible in the context of my AD service user, but somehow not in the context of MW Agent. I am starting MW Agent Configuration as my database service user. Is it because the agent runs as SYSTEM?

FYI I created my database service user as an AD user with only enough privilege to connect to the MSSQL server and issue SELECT queries.
mongoose
New
 
Posts: 5
Joined: Tue Dec 04, 2012 9:45 pm

Re: Database Monitor: ODBC DSN not found

Postby alorbach » Thu Dec 06, 2012 12:06 am

Hi,

to be honest we never used or tested UserDSN as System DSN were always working properly. Maybe you should give them another try? Alternative, you can also try the OleDB Database Action.It works well for Microsoft SQL Server, and the Action works simular to ODBC. OleDB is sometimes referenced as ODBCv2 ;).

best regards,
Andre
alorbach
Site Admin
 
Posts: 1627
Joined: Thu Feb 13, 2003 11:55 am

Re: Database Monitor: ODBC DSN not found

Postby mongoose » Fri Dec 07, 2012 4:30 pm

Thanks for the help Andre, I've got this issue sorted.

For the docs, it appears one can never use a User DSN, since the MW Agent runs in the SYSTEM context (and not the User who can access the User DSN). Of course my mistake was assuming that if I started the config wizard as a specific user, that the agent was also running as that user. Assumptions, assumptions ;)

No arch issues.

Thanks again!

Chuck
mongoose
New
 
Posts: 5
Joined: Tue Dec 04, 2012 9:45 pm

Google Ads



Return to MonitorWare Agent

Who is online

Users browsing this forum: No registered users and 1 guest

cron