|
Bugzilla – Full Text Bug Listing |
| Summary: | rug does not ask for cd | ||
|---|---|---|---|
| Product: | [openSUSE] openSUSE 10.2 | Reporter: | Holger Sickenberg <holgi> |
| Component: | libzypp | Assignee: | Duncan Mac-Vicar <dmacvicar> |
| Status: | RESOLVED FIXED | QA Contact: | Stanislav Visnovsky <visnov> |
| Severity: | Major | ||
| Priority: | P5 - None | CC: | aj, dmacvicar, jsrain, kkaempf, schubi, wstephenson |
| Version: | RC 2 | ||
| Target Milestone: | --- | ||
| Hardware: | Other | ||
| OS: | Other | ||
| Whiteboard: | |||
| Found By: | Other | Services Priority: | |
| Business Priority: | Blocker: | --- | |
| Marketing QA Status: | --- | IT Deployment: | --- |
Still non-matching callbacks ? Apparently, the callbacks are fine but not properly evaluated by rug I have these packages installed
libzypp-zmd-backend-7.1.1.0_0.4-37
rug-7.1.100.0-30
zmd-7.1.100.0-40
Running the 'transact' helper standalone does show proper output:
> sudo /usr/lib64/zmd/transact /tmp/zmd.db
0|2
10|6|SUSE LINUX (Media source cd:/// does not contain the desired media)
3|Can't provide ./suse/noarch/ttf-founder-traditional-0.20040419-7.noarch.rpm from cd:///
1|Can't provide ./suse/noarch/ttf-founder-traditional-0.20040419-7.noarch.rpm from cd:///
4
The second line (10|6|...) is requesting ZMD to ask for media #6 but this request isn't properly evaluated.
Jinu, please check this out. We did not see the transact helper returning '10' (Media Change) on the RC1 setup. we got a 0|2 3|Can't provide /suse/i586/xchat-2.6.6-17.i586.rpm from cd:///?devices=/dev/hdc 4 Looked like the Media Change status was fixed recently (RC2). We then got the latest libzypp-backend from SuSE autobuild and that helped us reproduce the status Klaus is mentioning.. Working on it.. Yes, RC1 was troubled with bug #223726 and did not properly report media change requests to ZMD. RC2 is fixed, see comment #3 I did get to reproduce the issue with the latest libzypp-zmd-backend and here is what I figured out so far.. I get the following messages from the transact helper on a "rug in xchat" 0|2 10|2|openSUSE (Media source cd:///?devices=/dev/hdc does not contain the desired media) /* this is fine, this is where zmd waits for the media. */ 3|Can't provide /suse/i586/xchat-2.6.6-22.i586.rpm from cd:///?devices=/dev/hdc /* is a 3 (Failure) expected at this stage???? if I tweak the ZyppBackend (zmd side) to ignore the 3 at this stage. rug behaves correctly.. */ 4 /* Done is ok.. */ Here is the rug behaviour when I ignore the 3 (failure) immediately after 10 (media change).. ----- bugz:/usr/lib # rug in xchat Resolving Dependencies... The following packages will be installed: xchat 2.6.6-22 (cd:///?devices=/dev/hdc&alias=20061127-063752) Transaction... Please insert openSUSE (Media source cd:///?devices=/dev/hdc does not contain the desired media), disk 2, and press Enter. ----- We are looking at whats making the helper to return 3 at this stage now.. The helper is right to exit with "3|...". This is how media change works - zmd calls transact helper - transact needs media, reports it to zmd as "10|media-nr|repository name" since zmd has to pass control back to rug (resp. zen-*), the transact helper exits(!) at this point - zmd passed media request to client (rug or zen-installer or zen-updater) - user acknowledges "insert media X of repo Y" message - zmd restarts transact So after transact reports "10|...", the "3|..." message just contains additional information. But zmd is supposed to continue with the transaction and not abort it. See http://en.opensuse.org/Libzypp/ZMD/ZMD7.1/helpers The "3|..." message has warning level only, its not an error ! *** Bug 224172 has been marked as a duplicate of this bug. *** 3 is defined as an Error status in ZyppBackend. A 3 after 10 was the cause for the problem. Abhi had a chat with Tambet and he also echoed the same as comment #8. A 3 was not expected after 10. Anyways the fix is this, we just ignore any other status once MediaChange is received, untill ofcourse the next transaction (0) starts.. Will speak to Klaus offline to see if ZyppBackend would have to treat a 3 as warning in any other case. Indeed. 10.1 (resp. SLE10GA) only reported "10|" and not "10|" and "3|". Actually, this is another bug in libzypp-zmd-backend :-( transact.cc has the following code:
if (med_callback.mediaNr() != 0 // exception due to MediaChange callback ?
&& !med_callback.description().empty())
{
// "4|" means 'message' to ZMD
cerr << "4|Need media " << med_callback.mediaNr() << ": " << med_callback.description() << endl;
}
else {
// "3|" is progress to stdout
cout << "3|" << joinlines( expt_r.asUserString() ) << endl;
// report as message ("4|" is message) to stderr
cerr << "4|" << expt_r.asString() << endl;
}
"4|..." is the 'transact exiting' code.
So if transact is exiting early because of a media change request, it just report "4|...", if it exits early for another reason, it reports "3|..." and then "4|...".
It looks like the requestMedia() call from zypp doesn't fill the "description" parameter in 10.2 zmd with this fix and a few other is submitted to autobuild. on klaus's request keeping the defect open to track comment #15. Klaus, do we need further changes here? Not for 10.2 immediately. Adapting severity. However, we should investigate the code in comment #14 and check why callback parameters have changed (description is empty now). |
luna:~ # rug in xchat Resolving Dependencies... The following packages will be installed: xchat 2.6.6-23 (cd:///?devices=/dev/hda&alias=20061128-125831) Transaction... 0% ERROR: Transaction failed: Can't provide /suse/x86_64/xchat-2.6.6-23.x86_64.rpm from cd:///?devices=/dev/hda