PHP5 fails to install lucid

Bug #787061 reported by Ian Hoff
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
php5 (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

Binary package hint: php5

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libapache2-mod-php5 php5-common
Suggested packages:
  php-pear php5-suhosin
The following NEW packages will be installed:
  libapache2-mod-php5 php5 php5-common
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 0B/3,383kB of archives.
After this operation, 8,806kB of additional disk space will be used.
Do you want to continue [Y/n]? y
Selecting previously deselected package php5-common.
(Reading database ... 51039 files and directories currently installed.)
Unpacking php5-common (from .../php5-common_5.3.2-1ubuntu4.9_i386.deb) ...
Selecting previously deselected package libapache2-mod-php5.
Unpacking libapache2-mod-php5 (from .../libapache2-mod-php5_5.3.2-1ubuntu4.9_i386.deb) ...
Selecting previously deselected package php5.
Unpacking php5 (from .../php5_5.3.2-1ubuntu4.9_all.deb) ...
Setting up php5-common (5.3.2-1ubuntu4.9) ...
Setting up libapache2-mod-php5 (5.3.2-1ubuntu4.9) ...
dpkg: error processing libapache2-mod-php5 (--configure):
 subprocess installed post-installation script returned error exit status 20
dpkg: dependency problems prevent configuration of php5:
 php5 depends on libapache2-mod-php5 (>= 5.3.2-1ubuntu4.9) | libapache2-mod-php5filter (>= 5.3.2-1ubuntu4.9) | php5-cgi (>= 5.3.2-1ubuntu4.9); however:
  Package libapache2-mod-php5 is not configured yet.
  Package libapache2-mod-php5filter is not installed.
  Package php5-cgi is not installed.
dpkg: error processing php5 (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
  Errors were encountered while processing:
 libapache2-mod-php5
 php5
E: Sub-process /usr/bin/dpkg returned an error code (1)

Revision history for this message
Ian Hoff (5-admin4life-gmail-com) wrote :

Trying to quell the dependency issue by installing php5-cgi gives the same error

Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Hi Ian, thanks for taking the time to file a bug report!

There is no dependency issue above. The post-installation script failed, as indicated here:

Setting up libapache2-mod-php5 (5.3.2-1ubuntu4.9) ...
dpkg: error processing libapache2-mod-php5 (--configure):
 subprocess installed post-installation script returned error exit status 20

So dpkg will not configure the rest of the dependent packages until libapache2-mod-php5 is configured.

The post-installation script, if you haven't removed the package from your system, should be at

/var/lib/dpkg/info/libapache2-mod-php5.postinst

It most likely had some issue while configuring the module. Error 20 is generally "Not a directory", so probably tried to do an 'rmdir' or 'chdir' on a directory that isn't on your system even though it should be. That very well could be a bug if its a directory the script should not expect to automatically be there. You can help us figure out if its a bug, or if your system has problems causing the issue, by running it with

sudo sh -x /var/lib/dpkg/info/libapache2-mod-php5.postinst configure 5.3.2-1ubuntu4.9

And pasting the output here.

Marking Incomplete pending response from Ian.

Changed in php5 (Ubuntu):
status: New → Incomplete
Revision history for this message
Ian Hoff (5-admin4life-gmail-com) wrote :

I ran the command as root user.
sh -x /var/lib/dpkg/info/libapache2-mod-php5.postinst configure 5.3.2-1ubuntu4.9
+ set -e
+ [ configure = triggered ]
+ [ configure != configure ]
+ phpini=/etc/php5/apache2/php.ini
+ ucf /usr/share/php5/php.ini-production /etc/php5/apache2/php.ini

Revision history for this message
Ian Hoff (5-admin4life-gmail-com) wrote :

I tried to get some more info on what might be happening with ucf

ucf -v /usr/share/php5/php.ini-production /etc/php5/apache2/php.ini
ucf: The new file is /usr/share/php5/php.ini-production
ucf: The Destination file is /etc/php5/apache2/php.ini
ucf: The Source directory is /usr/share/php5
ucf: The State directory is /var/lib/ucf
The hash file exists
egrep [[:space:]]\/etc\/php5\/apache2\/php\.ini$ /var/lib/ucf/hashfile
ucf: The new file is /usr/share/php5/php.ini-production
ucf: The Destination file is /etc/php5/apache2/php.ini
ucf: The Source directory is /usr/share/php5
ucf: The State directory is /var/lib/ucf
The hash file exists

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for php5 (Ubuntu) because there has been no activity for 60 days.]

Changed in php5 (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.