Nginx can't be removed using dpkg if not running

Bug #240720 reported by Nick Garvey
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
nginx (Debian)
Fix Released
Unknown
nginx (Ubuntu)
Fix Released
Low
Unassigned

Bug Description

Binary package hint: nginx

Description: Ubuntu 8.04
Release: 8.04

nginx Version 0.5.33

When the command "sudo dpkg -r nginx" is run, the following happens

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  nginx
0 upgraded, 0 newly installed, 1 to remove and 4 not upgraded.
After this operation, 606kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 156206 files and directories currently installed.)
Removing nginx ...
Stopping nginx: invoke-rc.d: initscript nginx, action "stop" failed.
dpkg: error processing nginx (--remove):
 subprocess pre-removal script returned error exit status 1
Errors were encountered while processing:
 nginx
E: Sub-process /usr/bin/dpkg returned an error code (1)

This occurs because nginx is not currently running, so the invoke-rc.d script fails to "stop" it.

This is fixed by adding --oknodo to the init.d script for nginx.

Revision history for this message
Nick Garvey (garvey-nick) wrote :
Revision history for this message
William Grant (wgrant) wrote :

Fixed in Intrepid.

Changed in nginx:
importance: Undecided → Low
status: New → Fix Released
Changed in nginx:
status: Unknown → Fix Released
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.