jump to navigation

Configuring CSQL for unixODBC October 12, 2009

Posted by Prabakaran Thirumalai in asterisk, csqlcache.
Tags: , , ,
trackback

CSQL Installation

CSQL follows extract and use installation strategy. When CSQL needs to be accessed from any terminal without setting the necessary environment such as LD_LIBRARY_PATH, CSQL_CONFIG_FILE, etc, some extra settings are required. This blog provides step by step procedure for doing the same.

Download the latest CSQL Release from http://www.csqlcache.com

$tar zxvf csql2.7-linux-x86.tar.gz

Copy install directory to /usr/local

$cp -R csql2.7-linux-x86 /usr/local

Create soft link csql to point to the csql installation directory

$ln -s /usr/local/csql2.7-linux-x86 csql

Configuring CSQL

$cd /usr/local/csql

Add below line to sample/csql.conf file

DURABILITY=true

Copy the configuration file to /etc directory

$mkdir /etc/csql

$cp sample/csql.conf /etc/csql/csql.conf

Create file /etc/ld.so.conf.d/csql.conf with following content “/usr/local/csql/lib”

unixODBC Confguration for CSQL

Download and install unixODBC from http://www.unixodbc.org

Add the below lines to ~/.odbc.ini file

[mycsql]
Driver = /usr/local/csql/lib/libcsqlodbc.so

Starting CSQL Server

CSQL provides two scripts,

  • setupenv.ksh – set the necessary environment variables such as PATH, LD_LIBRARY_PATH, CSQL_INSTALL_ROOT, etc.
  • startup.sh – start csqlserver

Run the scripts as mentioned in the below sequence

$cd /usr/local/csql

$. ./setupenv.ksh

$scripts/startup.sh

Checking configuration and server status

Verify whether server started by checking /tmp/csql/log/csqlserver.log file

Connect with isql tool to check ODBC configuration

$isql mycsql root manager

If the above command gives you SQL prompt, then ODBC configuration for CSQL works fine

More Information on CSQL Configuration

http://www.wiki.csqldb.com/index.php/UserManual/CSQLInstallation

About these ads

Comments»

1. CSQL For Astrisk Real Time Queues « Csqlcache Weblog - October 12, 2009

[...] this blog to find information on CSQL installation and [...]

2. Using CSQL for Asterisk func_odbc « Csqlcache Weblog - October 14, 2009

[...] Configuring CSQL for unixODBC [...]


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: