# DBD::ODBC looks in /etc not /usr/local/etc for odbc files

**URL:** <https://www.ruby-forum.com/t/dbd-odbc-looks-in-etc-not-usr-local-etc-for-odbc-files/93588>\
**Category:** Ruby\
**Created:** [April 4, 2006, 11:46pm UTC](https://www.ruby-forum.com/t/dbd-odbc-looks-in-etc-not-usr-local-etc-for-odbc-files/93588 "2006-04-04T23:46:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![weyus](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/7ab992/32.png) [@weyus](https://www.ruby-forum.com/u/weyus)\
**Post date:** [April 4, 2006, 11:46pm UTC](https://www.ruby-forum.com/t/dbd-odbc-looks-in-etc-not-usr-local-etc-for-odbc-files/93588/1 "2006-04-04T23:46:32Z")

</div>

All,

I had installed the freetds and unixODBC packages onto my Linux system  
using RPMs.

These RPMs installed these two packages into / basically (config files  
in /etc, libraries in /lib and so forth).

However, when I discovered that they weren’t working, I gave up on the  
RPMs and built the packages myself into /usr/local (config files in  
/usr/local/etc, libraries in /usr/local/lib and so forth).

I then installed ruby-odbc and ruby-dbi (with the ODBC driver).

What I’m finding is that when I attempt to use the DBD::ODBC package to  
connect to my database, the config. files are still being referenced  
from /etc instead of /usr/local/etc.

How do I “make” the Ruby modules look in /usr/local for the config files  
instead of /etc?

I don’t really understand how Ruby is generating it’s path’s internally.

Thanks,  
Wes

---

<div class="post-metadata">

**Author:** ![weyus](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/7ab992/32.png) [@weyus](https://www.ruby-forum.com/u/weyus)\
**Post date:** [April 5, 2006, 3:51am UTC](https://www.ruby-forum.com/t/dbd-odbc-looks-in-etc-not-usr-local-etc-for-odbc-files/93588/2 "2006-04-05T03:51:45Z")

</div>

You set the configuration files path when configuring unixODBC. Test  
your ODBC connection with isql. Ruby ODBC only uses whatever was  
configured in unixODBC.

2006/4/4, Wes G. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid):

> /usr/local/etc, libraries in /usr/local/lib and so forth).  
> I don’t really understand how Ruby is generating it’s path’s internally.
> 
> Thanks,  
> Wes
> 
> –  
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).

–  
Gerardo S.  
“Between individuals, as between nations, respect for the rights of  
others is peace” - Don Benito Juárez

> **[Santana's Tech Notes](http://santanatechnotes.blogspot.com/)**
>
> Small notes about technical related stuff I do, mainly OpenBSD and Ruby
