Bug 690038 - Packages loose their marking as "do not change"
Summary: Packages loose their marking as "do not change"
Status: VERIFIED FIXED
: 681404 686145 689002 (view as bug list)
Alias: None
Product: openSUSE 11.4
Classification: openSUSE
Component: YaST2 (show other bugs)
Version: Factory
Hardware: Other Other
: P2 - High : Normal (vote)
Target Milestone: ---
Assignee: Duncan Mac-Vicar
QA Contact: Jiri Srain
URL:
Whiteboard: maint:released:11.4:41044
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-26 19:43 UTC by Dieter Jurzitza
Modified: 2011-12-07 10:21 UTC (History)
9 users (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
This depicts clearly the deletion of /etc/zypp/locks (3.66 MB, text/plain)
2011-04-29 18:55 UTC, Dieter Jurzitza
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dieter Jurzitza 2011-04-26 19:43:29 UTC
User-Agent:       Mozilla/5.0 (X11; Linux i686; rv:2.0.0) Gecko/20100101 Firefox/4.0

I repetitively stumble across the fact that Yast is loosing the attributes of "don't change" files either due to package kit or due to a timeout.

The current mgetty / sendfax distribution is buggy (bug report exists) Hence I installed a fixed version - somewhat older than the recend one and marked it as "do not change". This always ensured that the packages were kept as long as I did not intentionally change the attribute.

However, since openSUSE 11.4 the attribute "don't change" (Geschützt - nicht verändern) get's lost -the heck knows why this happens.

So I cannot tell an unexperienced user to upgrade - because the upgrade potentionally destroys a running system.

Reproducible: Always

Steps to Reproduce:
1. Mark a package as "Geschützt  - nicht verändern")
2. wait (a day, a week, don't know how long
3. Marking is gone!!!!!
Actual Results:  
Well, the mark as "Geschützt" is vanishing into the haze after some time - don't know what causes this behaviour!

Expected Results:  
Guess what :-) If I intentionally mark software as _dont_change_this_ I would expect the updater to respect my decision. I have my reasons!!!!
Comment 1 Dieter Jurzitza 2011-04-27 18:35:46 UTC
Hi folks,
I found the root cause. Blame kpackagekit for this misbehaviour! In the very moment kpackagekit finds updates and you accept an update suggestion and enter the password the "locks" - file gets deleted.

Bad, bad habit of kpackagekit - you guys had better stayed with what you had for years and what used to be working :-(

Please fix!

Thank you for looking into this,
take care




Dieter Jurzitza
Comment 2 Dieter Jurzitza 2011-04-27 18:36:37 UTC
Just for the records: I am referring to /etc/zypp/locks!
Comment 3 Thomas Göttlicher 2011-04-28 09:52:52 UTC
As kpackagekit is the frontend only this might be a zypp-packagekit issue. zypp-maintainers could you please look into it?
Comment 4 Michael Andres 2011-04-29 09:15:58 UTC
Please attach the PackageKit logfile (/var/log/pk_backend_zypp). Maybe this contains a hint, what packagekit is doing.
Comment 5 Dieter Jurzitza 2011-04-29 18:55:35 UTC
Created attachment 427363 [details]
This depicts clearly the deletion of /etc/zypp/locks

Well, here you can identify the issue. See line 23743 - you have to figure out why this happens. Please fix, this behaviour is very bad.
Strange enough, this is not triggered if one updates via yast - maybe some of you guys understand why.
Comment 6 Dieter Jurzitza 2011-04-29 18:56:42 UTC
Hi folks,
the attachement of pk_backend_zypps should provide all the information you need.
Thank you for looking into this,
take care



Dieter Jurzitza
Comment 7 Bjørn Lie 2011-04-29 21:03:11 UTC
Please see bug
https://bugzilla.novell.com/show_bug.cgi?id=686145

this new bug here is clearly a dup, but since this one seems to maybe have some effort put into it, I'll leave it for now
Comment 8 Bjørn Lie 2011-04-29 21:04:32 UTC
and this one https://bugzilla.novell.com/show_bug.cgi?id=681404
Comment 9 Bjørn Lie 2011-04-29 21:08:24 UTC
yet one more
https://bugzilla.novell.com/show_bug.cgi?id=679162
Comment 10 Michael Andres 2011-05-02 18:02:38 UTC
*** Bug 681404 has been marked as a duplicate of this bug. ***
Comment 11 Michael Andres 2011-05-02 18:03:56 UTC
*** Bug 686145 has been marked as a duplicate of this bug. ***
Comment 12 Michael Andres 2011-05-03 10:53:37 UTC
pk_backend_zypp: I guess it starts at:

    2011-04-29 20:48:52 <1> djunix(4255) [zypp] Resolver.cc(solverInit):271
    -------------- Calling SAT Solver -------------------

Resolving for installation of miro-3.5.1-1.pm.2.36 shows the locks being present in the pool and passed to the solver.

    2011-04-29 20:48:53 <1> djunix(4255) [zypp] SATResolver.cc(resolvePool):747 
    SATResolver::resolvePool() done. Ret:1

Don't know what PK is doing now, but it involves some RepoManager action:

    2011-04-29 20:49:01 <1> djunix(4255) [zypp] 
    RepoManager.cc(init_knownRepositories):552 start construct known repos

After this PK solves again to install miro-3.5.1-1.pm.2.36, but meanwhile locks have been deleted from the pool.

    2011-04-29 20:49:01 <1> djunix(4255) [zypp] Resolver.cc(solverInit):271 
    -------------- Calling SAT Solver -------------------

This time followed by a commit, which installs miro-3.5.1-1.pm.2.36 and of course remembers the deleted locks.


Now we need to figure out what PK is doing between the 2 solver runs.
Comment 13 Duncan Mac-Vicar 2011-05-06 14:34:27 UTC
I fixed this upstream. I will update Factory and if possible 11.4 in the next days.

I am lowering the severity, as it is not straightforward to reproduce. You  need to get the requires of a locked package and then do another operation to get the reset lock commited.

commit e9ed00089de47e64090af65f42c9eba1e8eee0d4
Author: Duncan Mac-Vicar P <dmacvicar@suse.de>
Date:   Fri May 6 16:12:37 2011 +0200

    zypp: fix deletion of package locks (bnc#690038)
    
    Save and restore Pool status when doing calculations like
    in get_depends and get_requires.
    
    Fixes bug introduced by commit:
    "zypp: reset packages status in repo while removing packages" which
    resetted the status of an item, including its locks.
    
    So if you browse a locked package, see if requires, the reset done
    after removed the locks, and if you installed a package later, this was
    saved.
Comment 14 Dieter Jurzitza 2011-05-06 17:58:36 UTC
Hi Duncan,
thank you _very_ much for your efforts to fix this problem. However:

this:
> I am lowering the severity, as it is not straightforward to reproduce. You 
> need to get the requires of a locked package and then do another operation to
> get the reset lock commited.

is kind of strange. As an administrator I am urged now to live with kpackagekit, and everyone knows that defective packages hang around all the time. 

And if you argue that an effect that happens _immediately_ and _always_ when using the services of kpackagekit you're urged to use as the former yast frontend for updates does not exist any more is not straightforwad to reproduce, hmm, then, please tell me what would be straightforward in your opinion? It is 100% reproducible ..... ;-)

Don't get me wrong, I am glad you fix this, but I cannot agree with your points. This bug is severe IMHO because it touches the basics of system administration. If I have to tell people don't use this service because it definitively destroys functionalities (talking about the defective package of mgetty that is being distributed) then it is serious. At least much more serious than a simple broken feature of a non-system relevant program.

Thank you anyway for fixing this quickly,
take care

Dieter Jurzitza
Comment 15 Duncan Mac-Vicar 2011-05-09 13:03:22 UTC
I will check if I can include this as an update for 11.4.
Comment 16 Duncan Mac-Vicar 2011-05-09 13:43:29 UTC
Maintenance team, this bug is not trivial to backport as the backend has gone through lot of cleanups. I suggest just a PackageKit upgrade in 11.4.

Here is the relevant changes from 0.6.12 to 0.6.14 (leaving out other backends):
Also, there are fixes related to the daemon cancelling transactions when asked to quit, which may fix also #689627

      add missing python(gio) requirement
      check for polkit_authority_get_sync symbol
      trivial: refactor category to group
      network: update for NetworkManager 0.9 snapshots
      Add storeInCache parameter to downloadPackages to cover new API
      qt: Fix typo in SearchGroups
      zypp: uses the standard system update algorithm from ZYpp, which     honours user policies. (bnc#637764)
      Patch::Content is returned by value, so we should not iterate     using two different copies. Fixes crash on get-updates (bnc#685831)
      Use output parameters (references) for containers instead of     pointers. ZYpp throws exceptions and therefore it is safer to     have objects allocated on the stack if you are not protecting them     with a guard or smart pointer.
      use std:: and zypp:: namespace once to remove the hundred ocurrences of     namespace noise.
      Use const string &
      typo
      remove unused function
      Report download speed (bnc#663069)
      Added Italian translation
      pkcon: add missing {} around if
      docs: fix path of packagekitd
      docs: update Feature Matrix for conary
      client: fix precedence when assigning strings to a *GStrv
      trivial: Increase loop timeout in engine self-test
      trivial: Inform about GNOME-PackageKit in Debian
      browser-plugin: Remove deprecated symbols
      Add GIR annotations to make PK GIR usable
      Add missing languages to LINGUAS file
      Minor typo
Richard Hughes (32):
      trivial: post release version bump
      trivial: require --enable-local for make check support in src/
      trivial: fix make check for 64bit debian systems that only have /lib/libglib-2.0.so.0.2800.0 rather than /lib/libglib-2.0.so
      trivial: remove the get-updates cached results test, we're testing code that no longer exists
      trivial: show different warning messages for the different databases
      trivial: make the error checks more strict in the pk_backend_set_name() tests
      trivial: increase the allowed time for cleanup in the self test programs to prevent an intermittent failure
      Work with NetworkManager >= 0.8.992 which has removed two enumerated types
      Revert "Work with NetworkManager >= 0.8.992 which has removed two enumerated types"
      glib: allow pk_client_download_packages_async() to be called with no target directory
      Port away from PolkitBackendActionLookup to support new versions of PolicyKit
      trivial: post release version bump
      Introduce other attributes in the SetProxy() method
      Honour ACLOCAL_FLAGS in Makefile.am. Fixes fd#35237
      trivial: fix make check after the new proxy parameters was introduced
      Fix a crash where the error code was pointing to freed memory. Fixes rh#684464
      Automatically cancel running background transactions if a foreground transaction is committed
      Clear the pending queue and cancel any background transactions when we get SuggestDaemonQuit
      trivial: fix up the Fedora spec file
      Add a 'store_in_cache' attribute to the DownloadPackages method
directory passed to it
      Do not allow backends to output duplicate older packages when searching with newest
      trivial: update the LINGUAS file
      trivial: Update linguas file after I broke it in f983ebe658d596cc7847e31feb3ef4894338ecac
      Do not abort in pk_catalog_init() if PackageKit is not available. Fixes rh#688280
      Use the new threadsafe signal handling support in GLib
      zypp: remove check online in refresh cache
      pk-debuginfo-install:fix typo of using PK_FILTER
      zypp: check repo file before using it
      zypp:consider only_trusted option while installing packages
      zypp:reload RpmDB before removing packages
      zypp:Set locale info at the begin of transaction
      Fix a typo in pk_transaction_db_get_proxy
      zypp: support proxy_https,proxy_socks,no_proxy
      zypp:fix memory leak in pk_backend_transaction_start
      Get more proxy info after the new proxy parameters was introduced
      Creat transaction db properly if it's not exist
      Backend Matrix:Set zypp backend can downloadPackages
      zypp: reset packages status in repo while removing packages
      Added Galician translation
Comment 17 Marcus Meissner 2011-05-09 14:50:34 UTC
we hafve a packagekit update already running with 2 bugfixes.


Bugzilla #663069 - zypper PackageKit backend does not use the speed property
Bugzilla #685831 - zypp: occasional crashes of packagekitd 



this update would probably obsolete it, right?

Duncan says it is worth it, but "some QA" is necessary. 

I am not fully decided yet, it sounds good, but not sure on the risk of breaking working stuff. (+1)
Comment 18 Christian Dengler 2011-05-10 14:43:29 UTC
I think we should merge it with the running update.

Can you submit the fixed sources and add a new patchinfo?

SwampID: 40504
Comment 19 Duncan Mac-Vicar 2011-05-12 13:46:46 UTC
I have submitted the packages to openSUSE:11.4:Update:Test (request id 70119)
and I have updated the patchinfo.

Once the update reaches update/11.4-test we should make some noise to get some feedback from the community on how it works for them.
Comment 20 Bernhard Wiedemann 2011-05-12 14:00:15 UTC
This is an autogenerated message for OBS integration:
This bug (690038) was mentioned in
https://build.opensuse.org/request/show/70119 11.4 / PackageKit
Comment 21 Marcus Meissner 2011-05-12 14:05:20 UTC
you need to submit a new one, below
https://swamp.suse.de/webswamp/swamp/template/DisplayWorkflow.vm/workflowid/40504

(add patchinfo for openSUSE product)

can you mention the version update and perhaps give a brief summary of the changes in it?
Comment 22 Dieter Jurzitza 2011-05-12 18:47:51 UTC
Hi Duncan,
would you be so kind to specify exactly which packages to upgrade? I am willing to give you a feedback, but I do not want to include 11.4-test generally, would prefer to install specific packages .... just a list would be greatly appreciated :-) [if it is only one, even better, but I'd need to know ...]

Again, thank you for your efforts,
take care



Dieter
Comment 23 Duncan Mac-Vicar 2011-05-13 08:05:17 UTC
@Marcus New patchinfo added. Changes due to the version upgrade are irrelevant for the non-programmer, except for the improvements in zypper not being able to shutdown packagekit.

Dieter you will only need to upgrade the PackageKit package.
Comment 24 john andersen 2011-05-19 21:26:06 UTC
I am still seeing this bug as of today.  I've learned to be very careful when updating with KpackageKit. 

I use a version of UNISON, which is dictated by a remote server (2.27) and therefore I have LOCKED that version in Yast.

However, Kpackagekit will sometimes remove these locks and try to install a later version, which won't work with that remote server.


KPackageKit: 0.6.3.3
KDE Development Platform: 4.6.3 (4.6.3) "release 4
Opensuse 11.4 fresh install using this repository for upgrades:
http://download.opensuse.org/repositories/KDE:/Release:/46/openSUSE_11.4/
Comment 27 Swamp Workflow Management 2011-06-07 13:52:23 UTC
Update released for: PackageKit, PackageKit-branding-upstream, PackageKit-browser-plugin, PackageKit-browser-plugin-debuginfo, PackageKit-debuginfo, PackageKit-debugsource, PackageKit-devel, PackageKit-doc, PackageKit-gstreamer-plugin, PackageKit-gstreamer-plugin-debuginfo, PackageKit-gtk-module, PackageKit-gtk-module-debuginfo, PackageKit-gtk3-module, PackageKit-gtk3-module-debuginfo, PackageKit-lang, libpackagekit-glib2-14, libpackagekit-glib2-14-debuginfo, libpackagekit-glib2-devel, libpackagekit-qt-devel, libpackagekit-qt14, libpackagekit-qt14-debuginfo, libpackagekit-qt2-2, libpackagekit-qt2-2-debuginfo, libpackagekit-qt2-devel
Products:
openSUSE 11.4 (debug, i586, x86_64)
Comment 28 Duncan Mac-Vicar 2011-07-08 07:41:05 UTC
Closing, as update went out.
Comment 29 Bernhard Wiedemann 2011-11-07 11:00:17 UTC
This is an autogenerated message for OBS integration:
This bug (690038) was mentioned in
https://build.opensuse.org/request/show/90226 11.4 / PackageKit
Comment 30 Michael Andres 2011-12-07 10:21:49 UTC
*** Bug 689002 has been marked as a duplicate of this bug. ***