PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ldap.ini on line 1 in Unknown on line 0

Bug #573436 reported by Mike.lifeguard on 2010-05-02
134
This bug affects 30 people
Affects Status Importance Assigned to Milestone
php5 (Ubuntu)
Medium
Unassigned

Bug Description

Binary package hint: php5

As with bug 556469, the .ini file uses a deprecated comment syntax, which spews warnings.

ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: php5-ldap (not installed)
ProcVersionSignature: Ubuntu 2.6.32-21.32-generic-pae 2.6.32.11+drm33.2
Uname: Linux 2.6.32-21-generic-pae i686
Architecture: i386
Date: Sun May 2 00:20:23 2010
ProcEnviron:
 PATH=(custom, user)
 LANG=en_CA.UTF-8
 SHELL=/bin/bash
SourcePackage: php5

Related branches

Mike.lifeguard (mikelifeguard) wrote :
Nigel Hathaway (nhathaway) wrote :

PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imap.ini on line 1 in Unknown on line 0
PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0

All the others in my /etc/php5/cli/conf.d directory have the ';' comment.

Chuck Short (zulcss) wrote :

Thanks this will be in maverick and will probably be backported to lucid.

chuck

Changed in php5 (Ubuntu):
importance: Undecided → Low
status: New → Incomplete
Damian Friedli (damian-friedli) wrote :

it also affects php5-imagick (and maybe other modules...)

PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imagick.ini on line 1 in Unknown on line 0
[PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imap.ini on line 1 in Unknown on line 0]
[PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0]

Scott Evans (vk7hse) wrote :

This bug also affects Mediawiki maintenance PHP scripts as well...

example:

sudo php removeUnusedAccounts.phpPHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0
PHP Fatal error: Allowed memory size of 262144 bytes exhausted (tried to allocate 261900 bytes) in Unknown on line 0
Could not startup.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 10-05-10 11:08 AM, Scott Evans wrote:
> This bug also affects Mediawiki maintenance PHP scripts as well...

AFAICT, the deprecated comment syntax isn't used upstream:
http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/maintenance/removeUnusedAccounts.php?view=markup

> PHP Fatal error: Allowed memory size of 262144 bytes exhausted (tried to allocate 261900 bytes) in Unknown on line 0
> Could not startup.

This fatal error is unrelated to the comment syntax.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)

iEYEARECAAYFAkvoIoUACgkQst0AR/DaKHvRrQCfSTPcfToXXvi6WTE/6vaUDO1E
YAoAoJIeOqbyXegg0w1G+eGQBX7ILjrs
=5/4V
-----END PGP SIGNATURE-----

Mrten (bugzilla-ii) wrote :

This affects imap.ini and mcrypt.ini, too.

PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imap.ini on line 1 in Unknown on line 0
PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0

New contens of /etc/php5/cli/conf.d/mcrypt.ini (similar for other files)

; configuration for php MCrypt module
extension=mcrypt.so

Chuck Short (zulcss) on 2010-05-25
Changed in php5 (Ubuntu):
importance: Low → Medium
status: Incomplete → In Progress
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package php5 - 5.3.2-1ubuntu5

---------------
php5 (5.3.2-1ubuntu5) maverick; urgency=low

  * debian/php5-module.ini: Comment should be "#" not ";". (LP: #573436)
  * debian/patches/cherrypick-upstream-51740.diff: Fix acinclude.ac macro check. (LP: #576910)
  * debian/patches/cherrypick-upstream-48361.diff: Fix regression with getPathInfo()
    doesn't return parent info (LP: #576910)
  * debian/patches/session_save_path.patch: ave PHP sessions to
    /var/lib/php rather than /tmp. (LP: #573222)
 -- Chuck Short <email address hidden> Tue, 25 May 2010 10:17:00 -0400

Changed in php5 (Ubuntu):
status: In Progress → Fix Released

This is great, but how do I install this new source?

The following worked for me:

cd /etc/php5/cli/conf.d
sudo perl -pi.bk -e 's/(\s*)#/\1;/' *ini
sudo mkdir bk
sudo mv *.bk bk

Which only catches comments at the start of a line; also, backups of the original files are in the /etc/php5/cli/conf.d/bk directory.

I just went to that directory mcrypt.ini and deleted first line starting with # and everything is ok.

grimko (grimko) wrote :

You should replace # with ; instead, in order to keep the comment.

Wido den Hollander (wido) wrote :

Shouldn't this be backported to Lucid since that is a LTS?

mdgrech (mdgrech) wrote :

Number 11 above worked for me, thanks Ogilvierothchild !

GP Das (gpdass) wrote :

I just deleted the first line of /etc/php5/cli/conf.d/mcript.ini (Number 12). It worked.
Thanks Uros Djokic.

Davim (davim) wrote :

This should be backported to Lucid

Why not just change the comment?

I kept getting mail with a similar error (different file), so I did

sudo vim /etc/php5/cli/conf.d/ps.ini
and changed the
# comment
to
/** comment **/
and all seems good.

Robbert Korving (robkorv) wrote :

Tnx for the solution.

Plz backport this to 10.04 so it won't surface again on a new install.

+1 please backport to 10.04, so it doesn't appear on a new install

John Faucett (jwaterfaucett) wrote :

yea had bad comment in ming.ini

i'd say just quickly scan through your /etc/üjü5/cli/conf.d/

cat grep or whatever and replace with # with ;

Alex (alex-ap-consulting) wrote :

+1

please backport to 12.04

PHP Deprecated: Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ming.ini on line 1 in Unknown on line 0

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers