LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-11-2015, 11:57 PM   #1
pal2ie
LQ Newbie
 
Registered: May 2015
Posts: 2

Rep: Reputation: Disabled
Unhappy ODBC Setup problems (SQLGetPrivateProfileString failed with Unable to find component)


I am having issues setting up ODBC to connect to my Azure SQLServer database.

I had a Petra (16) installation on my laptop that had ODBC setup for this purpose. Recently, I did a fresh install of Mint 17 and upgraded to 17.1 on the same laptop. Then I setup ODBC the same way as I had working on Petra. But this time I got errors. As the ODBC version was an old one, I uninstalled it and installed the latest ODBC pacakge (2.3.2) using ./configure and make install. Re-did all the setups and still same problems.

I have setup below:
  • /etc/odbc.ini
    /etc/odbcinst.ini
    /etc/ODBCDataSources/tds.driver.template

set up below variables in /etc/environment:
Code:
ODBCINI="/etc/odbc.ini"
ODBCSYSINI="/etc"
ODBCINSTINI="odbcini.ini"
When I go to /etc/ODBCDataSources and do
Code:
>>odbcinst -i -d -f tds.driver.template
odbcinst: SQLInstallDriverEx failed with Unable to find component name
During a lot of tinkering yesterday, at some point I was able to run this same command successfully and it did get installed then. But the error has reappeared. However, the driver seems to be installed fine:
Code:
>>odbcinst -q -s
[ms-sql]
Code:
>>odbcinst -j
unixODBC 2.3.2
DRIVERS............: /etc/odbcini.ini
SYSTEM DATA SOURCES: /etc/odbc.ini
FILE DATA SOURCES..: /etc/ODBCDataSources
USER DATA SOURCES..: /etc/odbc.ini
SQLULEN Size.......: 8
SQLLEN Size........: 8
SQLSETPOSIROW Size.: 8
BUT
Code:
>>odbcinst -q -d
odbcinst: SQLGetPrivateProfileString failed with Unable to find component name.
I can connect via tsql though:
Code:
>>TDSVER=8.0 tsql -H <server> -U <usr> -D <database> -p 1433 -P <pwd>
locale is "en_IN"
locale charset is "UTF-8"
using default charset "UTF-8"
Default database being set to <...>
1>
But cannot make isql work:
Code:
>>isql -v ms-sql <usr> <pwd>
[IM002][unixODBC][Driver Manager]Data source name not found, and no default driver specified
[ISQL]ERROR: Could not SQLConnect
Result: I am not able to connect to this from python using pyodbc.

Any pointers to resolve this will be greatly appreciated!!

Thanks in advance.
 
Old 05-12-2015, 12:25 PM   #2
pal2ie
LQ Newbie
 
Registered: May 2015
Posts: 2

Original Poster
Rep: Reputation: Disabled
Dear all, PLEASE help!
 
Old 10-23-2017, 11:31 AM   #3
ederrafo
LQ Newbie
 
Registered: May 2016
Posts: 1

Rep: Reputation: Disabled
Hello

Notice in the blanks, at the beginning of the lines, in the odbcinst.ini file.
the blanks may be causing that error

Incorrect:
---[FreeTDS]
---Description = FreeTDS
---Driver = /var/www/html/installers/libtdsodbc.so

Correct:
[FreeTDS]
Description = FreeTDS
Driver = /var/www/html/installers/libtdsodbc.so

Last edited by ederrafo; 10-23-2017 at 11:34 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
net rpc join failed in samba 3.4.5.unable to setup creds (NT_STATUS_ACCESS_DENIED annadaprasana Linux - Server 2 02-10-2010 11:01 PM
Failed to launch VMware Web Access: unable to find a graphical web browser. rob0t Linux - Server 0 03-18-2009 02:32 PM
Setup is unable to find the ''gcc'' program - Fedora core 5 scorpio56 Linux - Newbie 4 06-11-2008 09:12 AM
Setup is unable to find a hard disk location to store temporary files. Klas Linux - Software 2 02-14-2006 06:47 PM
Failed to load installer component titusind Debian 0 09-09-2005 10:52 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:41 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration