For Programmers: Free Programming Magazines  


Home > Archive > PHP DB > June 2005 > sybase_connect(): Sybae:Unable to allocate connection record









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author sybase_connect(): Sybae:Unable to allocate connection record
Philip Wasshington

2005-06-01, 3:56 pm

After installing php-4.3.9-3.6.src.rpm on RHEL4 I modified the php.spec
file to
add --with-sybase-ct=/opt/sybase/OCS-12_5

Everything appeared to compile fine but after update installing the
rpms I get the error
'Warning: sybase_connect(): Sybase:Unable to allocate connection
record.'
when attempting to run code.

I have done this before on RHEL3 and did not run into this problem.

The server is running fine and I can use isql from this server and
connect to SYBASESR


%configure \
--cache-file=../config.cache \
--with-config-file-path=%{_sysconfdir} \
--with-config-file-scan-dir=%{_sysconfdir}/php.d \
--enable-force-cgi-redirect \
--disable-debug \
--enable-pic \
--disable-rpath \
--enable-inline-optimization \
--with-bz2 \
--with-db4=%{_prefix} \
--with-curl \
--with-exec-dir=%{_bindir} \
--with-freetype-dir=%{_prefix} \
--with-png-dir=%{_prefix} \
--with-gd=shared \
--enable-gd-native-ttf \
--without-gdbm \
--with-gettext \
--with-ncurses=shared \
--with-gmp \
--with-iconv \
--with-jpeg-dir=%{_prefix} \
--with-openssl \
--with-png \
--with-pspell \
--with-xml \
--with-expat-dir=%{_prefix} \
--with-dom=shared,%{_prefix} \
--with-dom-xslt=%{_prefix} --with-dom-exslt=%{_prefix} \
--with-xmlrpc=shared \
--with-pcre-regex=%{_prefix} \
--with-zlib \
--with-layout=GNU \
--enable-bcmath \
--enable-exif \
--enable-ftp \
--enable-magic-quotes \
--enable-sockets \
--enable-sysvsem \
--enable-sysvshm \
--enable-track-vars \
--enable-trans-sid \
--enable-yp \
--enable-wddx \

--with-pear=/usr/share/pear \
--with-imap=shared --with-imap-ssl \
--with-kerberos \
--with-ldap=shared \
--with-mysql=shared,%{_prefix} \
%{?_with_oci8:--with-oci8-instant-client=shared} \
%{?_with_mssql:--with-mssql=shared} \
%{?_with_mhash:--with-mhash=shared} \
--with-pgsql=shared \
--with-snmp=shared,%{_prefix} \
--with-snmp=shared \
--enable-ucd-snmp-hack \
--with-unixODBC=shared,%{_prefix} \
--with-sybase-ct=/opt/sybase/OCS-12_5 \
--enable-memory-limit \
--enable-shmop \
--enable-calendar \
--enable-dbx \
--enable-dio \
--enable-mbstring=shared --enable-mbstr-enc-trans \
--enable-mbregex \
--with-mime-magic=%{_datadir}/file/magic.mime \
$* || tail -300 config.log



script:
$server="SYBASESR";
$user="sa";
$pass="";
$con =sybase_connect($server,$user, $pass);
Philip Washington

2005-06-04, 3:57 am

I think that after installation the system needed to be rebooted so that
the apache user could see the new environment variables.

Philip Wasshington wrote:
> After installing php-4.3.9-3.6.src.rpm on RHEL4 I modified the php.spec
> file to
> add --with-sybase-ct=/opt/sybase/OCS-12_5
>
> Everything appeared to compile fine but after update installing the
> rpms I get the error
> 'Warning: sybase_connect(): Sybase:Unable to allocate connection
> record.'
> when attempting to run code.
>
> I have done this before on RHEL3 and did not run into this problem.
>
> The server is running fine and I can use isql from this server and
> connect to SYBASESR
>
>
> %configure \
> --cache-file=../config.cache \
> --with-config-file-path=%{_sysconfdir} \
> --with-config-file-scan-dir=%{_sysconfdir}/php.d \
> --enable-force-cgi-redirect \
> --disable-debug \
> --enable-pic \
> --disable-rpath \
> --enable-inline-optimization \
> --with-bz2 \
> --with-db4=%{_prefix} \
> --with-curl \
> --with-exec-dir=%{_bindir} \
> --with-freetype-dir=%{_prefix} \
> --with-png-dir=%{_prefix} \
> --with-gd=shared \
> --enable-gd-native-ttf \
> --without-gdbm \
> --with-gettext \
> --with-ncurses=shared \
> --with-gmp \
> --with-iconv \
> --with-jpeg-dir=%{_prefix} \
> --with-openssl \
> --with-png \
> --with-pspell \
> --with-xml \
> --with-expat-dir=%{_prefix} \
> --with-dom=shared,%{_prefix} \
> --with-dom-xslt=%{_prefix} --with-dom-exslt=%{_prefix} \
> --with-xmlrpc=shared \
> --with-pcre-regex=%{_prefix} \
> --with-zlib \
> --with-layout=GNU \
> --enable-bcmath \
> --enable-exif \
> --enable-ftp \
> --enable-magic-quotes \
> --enable-sockets \
> --enable-sysvsem \
> --enable-sysvshm \
> --enable-track-vars \
> --enable-trans-sid \
> --enable-yp \
> --enable-wddx \
>
> --with-pear=/usr/share/pear \
> --with-imap=shared --with-imap-ssl \
> --with-kerberos \
> --with-ldap=shared \
> --with-mysql=shared,%{_prefix} \
> %{?_with_oci8:--with-oci8-instant-client=shared} \
> %{?_with_mssql:--with-mssql=shared} \
> %{?_with_mhash:--with-mhash=shared} \
> --with-pgsql=shared \
> --with-snmp=shared,%{_prefix} \
> --with-snmp=shared \
> --enable-ucd-snmp-hack \
> --with-unixODBC=shared,%{_prefix} \
> --with-sybase-ct=/opt/sybase/OCS-12_5 \
> --enable-memory-limit \
> --enable-shmop \
> --enable-calendar \
> --enable-dbx \
> --enable-dio \
> --enable-mbstring=shared --enable-mbstr-enc-trans \
> --enable-mbregex \
> --with-mime-magic=%{_datadir}/file/magic.mime \
> $* || tail -300 config.log
>
>
>
> script:
> $server="SYBASESR";
> $user="sa";
> $pass="";
> $con =sybase_connect($server,$user, $pass);

Philip Washington

2005-06-08, 3:57 am

Philip Washington wrote:
> I think that after installation the system needed to be rebooted so that
> the apache user could see the new environment variables.
>

After further review it appears that the problem was caused by
permissions on the /opt/sybase directory. Originally it was set up and
had a permission of 700. After being moved and copied the permisions
were changed to 755. This appears to have been the problem.
[color=darkred]
> Philip Wasshington wrote:
>
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2009 codecomments.com