Public bug reported:

zram-config, even after uninstalled, leaves behind the /etc/init/zram-
config.conf file, likely because it's marked as a conffile

This file, being the only actual functional file in zram-config, and the
only thing needed by Upstart to configure zram swaps, doesn't check
whether the zram-config package is installed before merrily continuing
as if zram-config were actually in the system.

I suggest to move some of the /etc/init/zram-config.conf code into shell
scripts that are tested for presence (or executability) before being
run, exiting silently if they're not there.

If they're absent, this means package is uninstalled and zram-config
should exit silently.

It'd be nice if, in the process, some configuration moved into
/etc/default/zram-config, like the fraction of the ram that should be
used for zram swap (in the line around "(1/2 of ram)" comment in "zram-
config.conf").

Steps to reproduce:

 $ sudo apt-get install zram-config
 $ cat /proc/swaps
  (see zram swap(s))
 $ sudo apt-get remove zram-config
 $ sudo reboot
 (wait for reboot and open terminal again)
 $ cat /proc/swaps
  (see zram swap(s) still there when they shouldn't)

The workaround is to type

dpkg --purge zram-config

Which finally removes the upstart script and stops zram swaps from being
configured at boot.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: zram-config 0.1
ProcVersionSignature: Ubuntu 3.2.0-29.46~ppa1-generic-tuxonice 3.2.24
Uname: Linux 3.2.0-29-generic-tuxonice x86_64
ApportVersion: 2.0.1-0ubuntu12
Architecture: amd64
Date: Mon Aug 13 20:06:46 2012
Dependencies:
 
InstallationMedia: Ubuntu 12.04 LTS "Precise Pangolin" - Release amd64 
(20120425)
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=pt_BR:pt:en
 TERM=xterm
 PATH=(custom, no user)
 LANG=pt_BR.UTF-8
 SHELL=/bin/bash
SourcePackage: zram-config
UpgradeStatus: No upgrade log present (probably fresh install)

** Affects: zram-config (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug precise

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1036339

Title:
  zram-config runs even after uninstalled, needs purge

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/zram-config/+bug/1036339/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to