From owner-freebsd-questions@FreeBSD.ORG Wed Oct 5 08:14:00 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 14C4116A41F for ; Wed, 5 Oct 2005 08:14:00 +0000 (GMT) (envelope-from youshi10@u.washington.edu) Received: from mxout5.cac.washington.edu (mxout5.cac.washington.edu [140.142.32.135]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9BBAB43D45 for ; Wed, 5 Oct 2005 08:13:59 +0000 (GMT) (envelope-from youshi10@u.washington.edu) Received: from smtp.washington.edu (smtp.washington.edu [140.142.33.9]) by mxout5.cac.washington.edu (8.13.4+UW05.04/8.13.4+UW05.09) with ESMTP id j958Dwcx023839 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 5 Oct 2005 01:13:59 -0700 X-Auth-Received: from [192.168.0.9] (c-24-18-246-211.hsd1.wa.comcast.net [24.18.246.211]) (authenticated authid=youshi10) by smtp.washington.edu (8.13.4+UW05.04/8.13.4+UW05.09) with ESMTP id j958DwPZ018738 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT) for ; Wed, 5 Oct 2005 01:13:58 -0700 In-Reply-To: <002c01c5c983$1c3a2ac0$0c64a8c0@opteron> References: <80A9FCAE-B445-4E9D-B42F-7F5D5644B6C6@u.washington.edu><43438264.1040309@servingpeace.com> <795D325A-9591-4B11-83BC-3C30F675CAAC@u.washington.edu> <002c01c5c983$1c3a2ac0$0c64a8c0@opteron> Mime-Version: 1.0 (Apple Message framework v734) X-Priority: 3 Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <51DEB633-065F-487B-9018-81CCD7AA254D@u.washington.edu> Content-Transfer-Encoding: 7bit From: Garrett Cooper Date: Wed, 5 Oct 2005 01:15:11 -0700 To: FreeBSD Questions X-Mailer: Apple Mail (2.734) X-Uwash-Spam: Gauge=IIIIIII, Probability=7%, Report='__CT 0, __CTE 0, __CT_TEXT_PLAIN 0, __HAS_MSGID 0, __HAS_X_MAILER 0, __HAS_X_PRIORITY 0, __KNOWN_SPAMMER_ADDRESS_2 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __SANE_MSGID 0' Subject: Re: php4 sessions not built by default? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Oct 2005 08:14:00 -0000 On Oct 5, 2005, at 1:02 AM, K Anderson wrote: > > ----- Original Message ----- > From: "Garrett Cooper" > To: "FreeBSD Questions" > Sent: Wednesday, October 05, 2005 12:58 AM > Subject: Re: php4 sessions not built by default? > > > >> >> On Oct 5, 2005, at 12:36 AM, Sam Nilsson wrote: >> >> >>> Garrett Cooper wrote: >>> >>> >>>> Just trying to access some session variables via the PHP4 >>>> and for >>>> some odd reason it doesn't appear as if the function exists. Is >>>> this >>>> not built in PHP4 by default? And if so, how may I remedy the >>>> issue? >>>> Thanks, >>>> -Garrett >>>> >>>> >>> >>> Hi Garrett, >>> >>> Yeah, I think you are right that it doesn't install session >>> support by >>> default. I remember running into this myself. The solution is to >>> install >>> the lang/php4-extensions port if you don't already have it >>> installed. >>> That port will give you options to install all kinds of php >>> extensions >>> that you might need including session support. >>> >>> If you already have the lang/php4-extensions port installed and >>> you need >>> a different way to install session support, install the www/ php4- >>> session >>> port directly. >>> >>> - Sam >>> >>> >> >> Still no dice. Do I need to restart any services or something? >> > Did you shutdown apache then restart it? > Also, for giggles find your extensions.ini file (might be found in > /usr/local/etc/php) and see if you have a line that says > extension=session.so. If not then add it. Shut down apache and then > restart > it. > > Hope that helps. > > ~Mr. Anderson Thought about that just a second ago, and it doesn't seem like restarting Apache helped. Here's my extensions.ini file... it has session.so in it, but hopefully there weren't any additional files that were needed by the extension other than php4. root@sprsd# cat /usr/local/etc/php/extensions.ini extension=pcre.so extension=session.so Interesting stuff when I ran the PHP script via a terminal: gman@sprsd$ php index.php PHP Warning: Function registration failed - duplicate name - preg_match in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - preg_match_all in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - preg_replace in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - preg_replace_callback in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - preg_split in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - preg_quote in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - preg_grep in Unknown on line 0 PHP Warning: pcre: Unable to register functions, unable to load in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_name in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_module_name in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_save_path in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_id in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_regenerate_id in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_decode in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_register in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_unregister in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_is_registered in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_encode in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_start in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_destroy in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_unset in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_set_save_handler in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_cache_limiter in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_cache_expire in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_set_cookie_params in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_get_cookie_params in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_write_close in Unknown on line 0 PHP Warning: Function registration failed - duplicate name - session_commit in Unknown on line 0 PHP Warning: session: Unable to register functions, unable to load in Unknown on line 0 Segmentation fault (core dumped) gman@sprsd$ I have no idea what the core dump line implies, but it's definitely not good... Any ideas? -Garrett