Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 11 May 2008 22:52:49 +1000
From:      Adrian Thearle <adrian@thearle.com.au>
To:        ale@FreeBSD.org
Cc:        ports@FreeBSD.org
Subject:   FreeBSD Port: php5-pgsql-5.2.6 and php5-pspell-5.2.6 Seg Fault
Message-ID:  <4826EC21.7070208@thearle.com.au>

next in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------050005050309020008070705
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Hi Guys

I have discovered a problem when running php with postgresql and pspell. 
When both of these extensions are enabled in extensions.ini the server 
exits with a Segmentation Fault. I don't actually use pspell on my site 
just yet so its not a huge problem for me. I tracked down the problem 
because postgresql seemed to be the problem. (I started by disabling the 
pgsql extension in extensions.ini) I don't have anything the believe 
that this is a freebsd specific issue, so i didn't feel the need to 
submit a pr. Just letting everyone else out there know what problems I 
was experiencing.

[albert]~adrian# php -v
PHP 5.2.6 with Suhosin-Patch 0.9.6.2 (cli) (built: May 11 2008 22:14:00) 
(DEBUG)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies
Segmentation fault (core dumped)

I am running FreeBSD 7.0
[albert]~adrian# uname -rsv
FreeBSD 7.0-RELEASE FreeBSD 7.0-RELEASE #0: Sun Feb 24 19:59:52 UTC 
2008     root@logan.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC
With php5-5.2.6 from the ports collection

I have installed postgresql from the ports
postgresql-client-8.2.7

and aspell is
aspell-0.60.6_1

So I build php with debug enabled and this is the backtrace from the dump

(gdb) backtrace
#0  0x2912dcd0 in ?? ()
#1  0x286043d4 in pthread_mutex_destroy () from /lib/libc.so.7
#2  0x28f47629 in __tcf_1 () from /usr/local/lib/libaspell.so.16
#3  0x285e37e7 in __cxa_finalize () from /lib/libc.so.7
#4  0x28f46ff3 in __do_global_dtors_aux () from 
/usr/local/lib/libaspell.so.16
#5  0x28fd1f5c in _fini () from /usr/local/lib/libaspell.so.16
#6  0x282cc560 in ?? () from /libexec/ld-elf.so.1
#7  0x282cc3f4 in ?? () from /libexec/ld-elf.so.1
#8  0xbfbfea18 in ?? ()
#9  0x282aa449 in dlsym () from /libexec/ld-elf.so.1
#10 0x282aa552 in dlclose () from /libexec/ld-elf.so.1
#11 0x081a1f6f in module_destructor (module=0x287719e0) at 
/usr/ports/lang/php5/work/php-5.2.6/Zend/zend_API.c:1943
#12 0x081a79ed in zend_hash_apply_deleter (ht=0x82bcee0, p=0x28791460) 
at /usr/ports/lang/php5/work/php-5.2.6/Zend/zend_hash.c:805
#13 0x081a7b7e in zend_hash_graceful_reverse_destroy (ht=0x82bcee0) at 
/usr/ports/lang/php5/work/php-5.2.6/Zend/zend_hash.c:840
#14 0x0819a5ee in zend_shutdown () at 
/usr/ports/lang/php5/work/php-5.2.6/Zend/zend.c:814
#15 0x0814612f in php_module_shutdown () at 
/usr/ports/lang/php5/work/php-5.2.6/main/main.c:1906
#16 0x0821b26c in main (argc=2, argv=0xbfbfecf4) at 
/usr/ports/lang/php5/work/php-5.2.6/sapi/cli/php_cli.c:1341

Attached is the output from a php -i

Cheers
Adrian

--------------050005050309020008070705
Content-Type: text/plain;
 name="php-i.txt"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="php-i.txt"

phpinfo()
PHP Version => 5.2.6

System => FreeBSD a.somedomain.net 7.0-RELEASE FreeBSD 7.0-RELEASE #0: Sun Feb 24 19:59:52 UTC 2008     root@logan.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386
Build Date => May 11 2008 22:13:15
Configure Command =>  './configure'  '--with-layout=GNU' '--with-config-file-scan-dir=/usr/local/etc/php' '--disable-all' '--enable-libxml' '--with-libxml-dir=/usr/local' '--enable-reflection' '--program-prefix=' '--enable-fastcgi' '--with-apxs2=/usr/local/sbin/apxs' '--with-regex=php' '--with-zend-vm=CALL' '--enable-debug' '--prefix=/usr/local' '--mandir=/usr/local/man' '--infodir=/usr/local/info/'
Server API => Command Line Interface
Virtual Directory Support => disabled
Configuration File (php.ini) Path => /usr/local/etc
Loaded Configuration File => /usr/local/etc/php.ini
Scan this dir for additional .ini files => /usr/local/etc/php
additional .ini files parsed => /usr/local/etc/php/extensions.ini

PHP API => 20041225
PHP Extension => 20060613
Zend Extension => 220060519
Debug Build => yes
Thread Safety => disabled
Zend Memory Manager => enabled
IPv6 Support => enabled
Registered PHP Streams => php, file, data, http, ftp, https, ftps, zip  
Registered Stream Socket Transports => tcp, udp, unix, udg, ssl, sslv3, sslv2, tls
Registered Stream Filters => string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, convert.iconv.*


This server is protected with the Suhosin Patch 0.9.6.2
Copyright (c) 2006 Hardened-PHP Project


This program makes use of the Zend Scripting Language Engine:
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies


 _______________________________________________________________________


Configuration

PHP Core

Directive => Local Value => Master Value
allow_call_time_pass_reference => Off => Off
allow_url_fopen => On => On
allow_url_include => Off => Off
always_populate_raw_post_data => Off => Off
arg_separator.input => & => &
arg_separator.output => & => &
asp_tags => Off => Off
auto_append_file => no value => no value
auto_globals_jit => On => On
auto_prepend_file => no value => no value
browscap => no value => no value
default_charset => no value => no value
default_mimetype => text/html => text/html
define_syslog_variables => Off => Off
disable_classes => no value => no value
disable_functions => no value => no value
display_errors => Off => Off
display_startup_errors => Off => Off
doc_root => no value => no value
docref_ext => no value => no value
docref_root => no value => no value
enable_dl => On => On
error_append_string => no value => no value
error_log => no value => no value
error_prepend_string => no value => no value
error_reporting => 6143 => 6143
expose_php => On => On
extension_dir => /usr/local/lib/php/20060613-debug => /usr/local/lib/php/20060613-debug
file_uploads => On => On
highlight.bg => <font style="color: #FFFFFF">#FFFFFF</font> => <font style="color: #FFFFFF">#FFFFFF</font>
highlight.comment => <font style="color: #FF8000">#FF8000</font> => <font style="color: #FF8000">#FF8000</font>
highlight.default => <font style="color: #0000BB">#0000BB</font> => <font style="color: #0000BB">#0000BB</font>
highlight.html => <font style="color: #000000">#000000</font> => <font style="color: #000000">#000000</font>
highlight.keyword => <font style="color: #007700">#007700</font> => <font style="color: #007700">#007700</font>
highlight.string => <font style="color: #DD0000">#DD0000</font> => <font style="color: #DD0000">#DD0000</font>
html_errors => Off => Off
ignore_repeated_errors => Off => Off
ignore_repeated_source => Off => Off
ignore_user_abort => Off => Off
implicit_flush => On => On
include_path => .:/usr/local/share/pear => .:/usr/local/share/pear
log_errors => On => On
log_errors_max_len => 1024 => 1024
magic_quotes_gpc => Off => Off
magic_quotes_runtime => Off => Off
magic_quotes_sybase => Off => Off
mail.force_extra_parameters => no value => no value
max_execution_time => 0 => 0
max_input_nesting_level => 64 => 64
max_input_time => -1 => -1
memory_limit => 128M => 128M
open_basedir => no value => no value
output_buffering => 0 => 0
output_handler => no value => no value
post_max_size => 8M => 8M
precision => 14 => 14
realpath_cache_size => 16K => 16K
realpath_cache_ttl => 120 => 120
register_argc_argv => On => On
register_globals => Off => Off
register_long_arrays => Off => Off
report_memleaks => On => On
report_zend_debug => Off => Off
safe_mode => Off => Off
safe_mode_exec_dir => no value => no value
safe_mode_gid => Off => Off
safe_mode_include_dir => no value => no value
sendmail_from => no value => no value
sendmail_path => /usr/sbin/sendmail -t -i => /usr/sbin/sendmail -t -i
serialize_precision => 100 => 100
short_open_tag => Off => Off
SMTP => localhost => localhost
smtp_port => 25 => 25
sql.safe_mode => Off => Off
suhosin.log.phpscript => 0 => 0
suhosin.log.phpscript.is_safe => Off => Off
suhosin.log.phpscript.name => no value => no value
suhosin.log.sapi => no value => no value
suhosin.log.script => no value => no value
suhosin.log.script.name => no value => no value
suhosin.log.syslog => no value => no value
suhosin.log.syslog.facility => no value => no value
suhosin.log.syslog.priority => no value => no value
suhosin.log.use-x-forwarded-for => Off => Off
track_errors => Off => Off
unserialize_callback_func => no value => no value
upload_max_filesize => 2M => 2M
upload_tmp_dir => no value => no value
user_dir => no value => no value
variables_order => GPCS => GPCS
xmlrpc_error_number => 0 => 0
xmlrpc_errors => Off => Off
y2k_compliance => On => On
zend.ze1_compatibility_mode => Off => Off

ctype

ctype functions => enabled

curl

cURL support => enabled
cURL Information => libcurl/7.18.0 OpenSSL/0.9.8e zlib/1.2.3

date

date/time support => enabled
"Olson" Timezone Database Version => 2008.2
Timezone Database => internal
Default timezone => UTC

Directive => Local Value => Master Value
date.default_latitude => 31.7667 => 31.7667
date.default_longitude => 35.2333 => 35.2333
date.sunrise_zenith => 90.583333 => 90.583333
date.sunset_zenith => 90.583333 => 90.583333
date.timezone => no value => no value

dom

DOM/XML => enabled
DOM/XML API Version => 20031129
libxml Version => 2.6.31
HTML Support => enabled
XPath Support => enabled
XPointer Support => enabled
Schema Support => enabled
RelaxNG Support => enabled

exif

EXIF Support => enabled
EXIF Version => 1.4 $Id: exif.c,v 1.173.2.5.2.25 2008/03/12 17:33:14 iliaa Exp $
Supported EXIF Version => 0220
Supported filetypes => JPEG,TIFF

filter

Input Validation and Filtering => enabled
Revision => $Revision: 1.74 $

Directive => Local Value => Master Value
filter.default => unsafe_raw => unsafe_raw
filter.default_flags => no value => no value

ftp

FTP support => enabled

gd

GD Support => enabled
GD Version => bundled (2.0.34 compatible)
FreeType Support => enabled
FreeType Linkage => with freetype
FreeType Version => 2.3.5
T1Lib Support => enabled
GIF Read Support => enabled
GIF Create Support => enabled
JPG Support => enabled
PNG Support => enabled
WBMP Support => enabled
XPM Support => enabled
XBM Support => enabled

gettext

GetText Support => enabled

hash

hash support => enabled
Hashing Engines => md2 md4 md5 sha1 sha256 sha384 sha512 ripemd128 ripemd160 ripemd256 ripemd320 whirlpool tiger128,3 tiger160,3 tiger192,3 tiger128,4 tiger160,4 tiger192,4 snefru gost adler32 crc32 crc32b haval128,3 haval160,3 haval192,3 haval224,3 haval256,3 haval128,4 haval160,4 haval192,4 haval224,4 haval256,4 haval128,5 haval160,5 haval192,5 haval224,5 haval256,5 

iconv

iconv support => enabled
iconv implementation => libiconv
iconv library version => 1.11

Directive => Local Value => Master Value
iconv.input_encoding => ISO-8859-1 => ISO-8859-1
iconv.internal_encoding => ISO-8859-1 => ISO-8859-1
iconv.output_encoding => ISO-8859-1 => ISO-8859-1

json

json support => enabled
json version => 1.2.1

libxml

libXML support => active
libXML Version => 2.6.31
libXML streams => enabled

mysql

MySQL Support => enabled
Active Persistent Links => 0
Active Links => 0
Client API version => 5.0.51a
MYSQL_MODULE_TYPE =>  
MYSQL_SOCKET => /tmp/mysql.sock
MYSQL_INCLUDE =>  
MYSQL_LIBS =>  

Directive => Local Value => Master Value
mysql.allow_persistent => On => On
mysql.connect_timeout => 60 => 60
mysql.default_host => no value => no value
mysql.default_password => no value => no value
mysql.default_port => no value => no value
mysql.default_socket => no value => no value
mysql.default_user => no value => no value
mysql.max_links => Unlimited => Unlimited
mysql.max_persistent => Unlimited => Unlimited
mysql.trace_mode => Off => Off

openssl

OpenSSL support => enabled
OpenSSL Version => OpenSSL 0.9.8e 23 Feb 2007

pcre

PCRE (Perl Compatible Regular Expressions) Support => enabled
PCRE Library Version => 7.6 2008-01-28

Directive => Local Value => Master Value
pcre.backtrack_limit => 100000 => 100000
pcre.recursion_limit => 100000 => 100000

pdf

PDF Support => enabled
PDFlib GmbH Version => 7.0.2
PECL Version => 2.1.5
Revision => $Revision: 1.7 $

PDO

PDO support => enabled
PDO drivers => sqlite

pdo_sqlite

PDO Driver for SQLite 3.x => enabled
PECL Module version => (bundled) 1.0.1 $Id: pdo_sqlite.c,v 1.10.2.6.2.3 2007/12/31 07:20:10 sebastian Exp $
SQLite Library => 3.3.7

pgsql

PostgreSQL Support => enabled
PostgreSQL(libpq) Version => 8.2.7
Multibyte character support => enabled
SSL support => enabled
Active Persistent Links => 0
Active Links => 0

Directive => Local Value => Master Value
pgsql.allow_persistent => On => On
pgsql.auto_reset_persistent => Off => Off
pgsql.ignore_notice => Off => Off
pgsql.log_notice => Off => Off
pgsql.max_links => Unlimited => Unlimited
pgsql.max_persistent => Unlimited => Unlimited

posix

Revision => $Revision: 1.70.2.3.2.18 $

pspell

PSpell Support => enabled

Reflection

Reflection => enabled
Version => $Id: php_reflection.c,v 1.164.2.33.2.50 2008/03/13 15:56:21 iliaa Exp $

session

Session Support => enabled
Registered save handlers => files user 
Registered serializer handlers => php php_binary 

Directive => Local Value => Master Value
session.auto_start => Off => Off
session.bug_compat_42 => Off => Off
session.bug_compat_warn => On => On
session.cache_expire => 180 => 180
session.cache_limiter => nocache => nocache
session.cookie_domain => no value => no value
session.cookie_httponly => Off => Off
session.cookie_lifetime => 0 => 0
session.cookie_path => / => /
session.cookie_secure => Off => Off
session.entropy_file => no value => no value
session.entropy_length => 0 => 0
session.gc_divisor => 1000 => 1000
session.gc_maxlifetime => 1440 => 1440
session.gc_probability => 1 => 1
session.hash_bits_per_character => 5 => 5
session.hash_function => 0 => 0
session.name => PHPSESSID => PHPSESSID
session.referer_check => no value => no value
session.save_handler => files => files
session.save_path => no value => no value
session.serialize_handler => php => php
session.use_cookies => On => On
session.use_only_cookies => Off => Off
session.use_trans_sid => 0 => 0

SimpleXML

Simplexml support => enabled
Revision => $Revision: 1.151.2.22.2.39 $
Schema support => enabled

soap

Soap Client => enabled
Soap Server => enabled

Directive => Local Value => Master Value
soap.wsdl_cache => 1 => 1
soap.wsdl_cache_dir => /tmp => /tmp
soap.wsdl_cache_enabled => 1 => 1
soap.wsdl_cache_limit => 5 => 5
soap.wsdl_cache_ttl => 86400 => 86400

sockets

Sockets Support => enabled

SPL

SPL support => enabled
Interfaces => Countable, OuterIterator, RecursiveIterator, SeekableIterator, SplObserver, SplSubject
Classes => AppendIterator, ArrayIterator, ArrayObject, BadFunctionCallException, BadMethodCallException, CachingIterator, DirectoryIterator, DomainException, EmptyIterator, FilterIterator, InfiniteIterator, InvalidArgumentException, IteratorIterator, LengthException, LimitIterator, LogicException, NoRewindIterator, OutOfBoundsException, OutOfRangeException, OverflowException, ParentIterator, RangeException, RecursiveArrayIterator, RecursiveCachingIterator, RecursiveDirectoryIterator, RecursiveFilterIterator, RecursiveIteratorIterator, RecursiveRegexIterator, RegexIterator, RuntimeException, SimpleXMLIterator, SplFileInfo, SplFileObject, SplObjectStorage, SplTempFileObject, UnderflowException, UnexpectedValueException

SQLite

SQLite support => enabled
PECL Module version => 2.0-dev $Id: sqlite.c,v 1.166.2.13.2.10 2007/12/31 07:20:11 sebastian Exp $
SQLite Library => 2.8.17
SQLite Encoding => UTF-8

Directive => Local Value => Master Value
sqlite.assoc_case => 0 => 0

standard

Regex Library => Bundled library enabled
Dynamic Library Support => enabled
Path to sendmail => /usr/sbin/sendmail -t -i

Directive => Local Value => Master Value
assert.active => 1 => 1
assert.bail => 0 => 0
assert.callback => no value => no value
assert.quiet_eval => 0 => 0
assert.warning => 1 => 1
auto_detect_line_endings => 0 => 0
default_socket_timeout => 60 => 60
safe_mode_allowed_env_vars => PHP_ => PHP_
safe_mode_protected_env_vars => LD_LIBRARY_PATH => LD_LIBRARY_PATH
url_rewriter.tags => a=href,area=href,frame=src,input=src,form=fakeentry => a=href,area=href,frame=src,input=src,form=fakeentry
user_agent => no value => no value

sysvmsg

sysvmsg support => enabled
Revision => $Revision: 1.20.2.3.2.7 $

tokenizer

Tokenizer Support => enabled

xml

XML Support => active
XML Namespace Support => active
libxml2 Version => 2.6.31

xmlreader

XMLReader => enabled

xmlwriter

XMLWriter => enabled

zip

Zip => enabled
Extension Version => $Id: php_zip.c,v 1.99 2007/01/18 02:05:18 pajoye Exp $
Zip version => 1.9.0
Libzip version => 0.7.1

Additional Modules

Module Name
sysvsem
sysvshm

Environment

Variable => Value
USER => adrian
LOGNAME => adrian
HOME => /root
MAIL => /var/mail/adrian
PATH => /sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/home/adrian/bin
TERM => xterm
FTP_PASSIVE_MODE => YES
BLOCKSIZE => K
SHELL => /bin/csh
SSH_CLIENT => 192.168.123.139 3346 22
SSH_CONNECTION => 192.168.123.139 3346 192.168.123.115 22
SSH_TTY => /dev/ttyp0
HOSTTYPE => FreeBSD
VENDOR => intel
OSTYPE => FreeBSD
MACHTYPE => i386
SHLVL => 2
PWD => /home/adrian
GROUP => adrian
HOST => .a.somedomain.net
REMOTEHOST => 192.168.123.139

PHP Variables

Variable => Value
_SERVER["USER"] => adrian
_SERVER["LOGNAME"] => adrian
_SERVER["HOME"] => /root
_SERVER["MAIL"] => /var/mail/adrian
_SERVER["PATH"] => /sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/home/adrian/bin
_SERVER["TERM"] => xterm
_SERVER["FTP_PASSIVE_MODE"] => YES
_SERVER["BLOCKSIZE"] => K
_SERVER["SHELL"] => /bin/csh
_SERVER["SSH_CLIENT"] => 192.168.123.139 3346 22
_SERVER["SSH_CONNECTION"] => 192.168.123.139 3346 192.168.123.115 22
_SERVER["SSH_TTY"] => /dev/ttyp0
_SERVER["HOSTTYPE"] => FreeBSD
_SERVER["VENDOR"] => intel
_SERVER["OSTYPE"] => FreeBSD
_SERVER["MACHTYPE"] => i386
_SERVER["SHLVL"] => 2
_SERVER["PWD"] => /home/adrian
_SERVER["GROUP"] => adrian
_SERVER["HOST"] => a.somedomain.net
_SERVER["REMOTEHOST"] => 192.168.123.139
_SERVER["PHP_SELF"] => 
_SERVER["SCRIPT_NAME"] => 
_SERVER["SCRIPT_FILENAME"] => 
_SERVER["PATH_TRANSLATED"] => 
_SERVER["DOCUMENT_ROOT"] => 
_SERVER["REQUEST_TIME"] => 1210545939
_SERVER["argv"] => Array
(
)

_SERVER["argc"] => 0

PHP License
This program is free software; you can redistribute it and/or modify
it under the terms of the PHP License as published by the PHP Group
and included in the distribution in the file:  LICENSE

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

If you did not receive a copy of the PHP license, or have any
questions about PHP licensing, please contact license@php.net.

--------------050005050309020008070705--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4826EC21.7070208>