ID: 8151 Updated by: sander Reported By: baonguyenx @yahoo.com Old Status: Open Status: Bogus Bug Type: Sybase-ct (ctlib) related Operating System: Linux 6.1 PHP Version: 4.0.2 New Comment:
Probably not a bug in PHP. Ask support questions on the appropriate mailinglist. Previous Comments: ------------------------------------------------------------------------ [2000-12-07 03:47:19] baonguyenx @yahoo.com Hi Please Help 911!!! I have successfully installed FreeTDS0.51 and compiled it with PHP4.0.2. Also, I was able to run a script with select and insert statement on a MSSQL 7.0 DB. However, when I restarted apache server, I couldn't execute the script and got a message "Sybase: Unable to connect" . What had I done wrong ? Did I just shutdown the freetds process when I restart apache server? How do I restart freetds service? Do I need to add any environment variables to httpd.conf ? Here was the complete process that I had done. Thanks for reading. System Info: Linux6.1,FreeTDS0.51,PHP4.0.2, MySQL3.23.28,Apache1.3.9 DB Server: NT4.0, MSSQL 7.0, SP1 At the Directory /usr/local/ 1. Install FreeTDS0.51 >tar -zxvf freetds-0.51.tgz >cd freetds-0.51 >./configure --with-tdsver=4.2 --enable-msdblib --enable-dbmfix --with-gnu-ld --enable-shared --enable-static >make >make install By Default, it should install to /usr/local/freetds directory. Set enviroment in bash Shell. Copy and paste these lines > SYBASE=/usr/local/freetds > LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$SYBASE/lib > export SYBASE LD_LIBRARY_PATH Insert /usr/local/freetds/lib to etc/ld.so.conf >ldconfig Edit file /usr/local/freetds/interfaces NTSVR4 query tcp tds4.2 207.120.42.150 1433 master tcp tds4.2 207.120.42.150 1433 2. Install PHP Download the right version of freetds patch that is matched with your PHPversion. For php4.0.2: http://opensource.comvos.de/media/download/freetdspatch.tgz >tar -zxvf php-4.0.2.tar.gz >patch -p0 < patch.freetds >cd php-4.0.2 >./configure --enable-track-vars --with-mysql=/usr/local/mysql --with-apxs --with-sybase-ct=/usr/local/freetds Replace "dbopen" with "tdsdbopen" in /usr/local/php4/ext/sysbase/php_sybase_db.c >make >make install If you are using php4.0.1pl2, click here to download the patch http://www.phpbuilder.com/columns/alberto20000919.zip If you are using php4.0.3pl1, ask Alex for it [EMAIL PROTECTED] . You can also go to, http://bugs.php.net/bugs.php?id=7792 and copy it. Regards, Bn ------------------------------------------------------------------------ Edit this bug report at http://bugs.php.net/?id=8151&edit=1 -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]