Setting up Progress OpenEdge ODBC driver on Centos 7 with Plesk 12 and UnixODBC

Status
Not open for further replies.
P

Pandy Legend

Guest
I am trying to set up and ODBC connection to a Progress 10.1b database so I can query it with PHP 5.4 from a Centos 7 server running Plesk 12 and UnixODBC.

UnixODBC is working properly and ban be used successfully for both MySQL and PostgreSQL however I cannot get the Progress connection to work.

<?php $conn=odbc_connect("Progress_DB","sysprogress",""); ?>


produces the error:

Warning: odbc_connect(): SQL error: [unixODBC][DataDirect][ODBC 20101 driver]1201, SQL state 60 in SQLConnect


Researching this error I have found a number of different causes, but in each case the suggested resolution is either irrelevant or already implemented.

e.g:


I added tracing to the odbcinst.ini however no log file is created.

As the initial unixodbc installation was handled by the Plesk install, I wonder if there is some configuration elsewhere that I am missing.

I had to create the odbc.ini file as there was only an odbcinst.ini file in existence. Both files are definitely being read though because if I make a deliberate change to either, then things stop working altogether.

Here are the contents of the files:

/etc/odbc.ini

[ODBC Data Sources]
Progress=Progress_DB

[ODBC]
IANAAppCodePage=4
InstallDir=/opt/Progress/DataDirect/Connect64_for_ODBC_71
Trace = yes
TraceFile = /tmp/odbc.log
TraceDll=/usr/lib64/ddtrc27.so

[Progress_DB]
Driver=Progress
Description=DataDirect 7.1 Progress OpenEdge Wire Protocol
Database=fitz
HostName=thsrvsql02
LogonID=sysprogress
Password=
PortNumber=30020
APILevel=1
ConnectFunctions=YYN
CPTimeout=60
DriverODBCVer=03.52
FileUsage=0
SQLLevel=0
UsageCount=1
ArraySize=50
DefaultLongDataBuffLen=2048
DefaultIsolationLevel=REPEATABLE READ
StaticCursorLongColBuffLen=4096


/etc/odbcinst.ini

[ODBC]
Trace = yes
TraceFile = /tmp/odbc.log

[Progress]
Driver=/usr/lib64/ddoe27.so
FileUsage=1


[PostgreSQL]
Description = ODBC for PostgreSQL
Driver = /usr/lib/psqlodbcw.so
Setup = /usr/lib/libodbcpsqlS.so
Driver64 = /usr/lib64/psqlodbcw.so
Setup64 = /usr/lib64/libodbcpsqlS.so
FileUsage = 1


# Driver from the mysql-connector-odbc package
# Setup from the unixODBC package
[MySQL]
Description = MySQL driver for Plesk
Driver = /usr/lib64/libmyodbc5.so
Setup =
FileUsage = 1
Driver64 = /usr/lib64/libmyodbc5.so
Setup64 =
UsageCount = 1


Environment variables are set using a file in /etc/profile.d

Results of 'env'

[root@thsrvweb01 ~]# env
XDG_SESSION_ID=153
HOSTNAME=thsrvweb01
SELINUX_ROLE_REQUESTED=
TERM=xterm
SHELL=/bin/bash
HISTSIZE=1000
ODBCINST=/etc/odbcinst.ini
SSH_CLIENT=192.168.0.183 49210 22
SELINUX_USE_CURRENT_RANGE=
SSH_TTY=/dev/pts/0
USER=root
LD_LIBRARY_PATH=/opt/Progress/DataDirect/Connect64_for_ODBC_71/lib
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:eek:r=40;31;01:mi=01;05;37;41:su=37;41:sg=30;43:ca=30;41:tw=30;42:eek:w=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.axv=01;35:*.anx=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=01;36:*.au=01;36:*.flac=01;36:*.mid=01;36:*.midi=01;36:*.mka=01;36:*.mp3=01;36:*.mpc=01;36:*.ogg=01;36:*.ra=01;36:*.wav=01;36:*.axa=01;36:*.oga=01;36:*.spx=01;36:*.xspf=01;36:
MAIL=/var/spool/mail/root
PATH=/opt/Progress/DataDirect/Connect64_for_ODBC_71/tools:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/root/bin
PWD=/root
LANG=en_GB.UTF-8
SELINUX_LEVEL_REQUESTED=
HISTCONTROL=ignoredups
SHLVL=1
HOME=/root
ODBCINI=/etc/odbc.ini
LOGNAME=root
SSH_CONNECTION=192.168.0.183 49210 192.168.11.16 22
LESSOPEN=||/usr/bin/lesspipe.sh %s
XDG_RUNTIME_DIR=/run/user/0
_=/usr/bin/env


I am running out of things to try!

Please ask if you need any more information and I will be happy to provide.

Continue reading...
 
Status
Not open for further replies.
Top