Gentoo Archives: gentoo-dev

From: Duncan <1i5t5.duncan@×××.net>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Re: News Item: OpenAFS no longer needs kernel option DEBUG_RODATA
Date: Sun, 24 Jul 2016 03:01:07
Message-Id: pan$d785b$462ebd13$a9757949$6f64e78e@cox.net
In Reply to: Re: [gentoo-dev] News Item: OpenAFS no longer needs kernel option DEBUG_RODATA by Andrew Savchenko
1 Andrew Savchenko posted on Sun, 24 Jul 2016 00:30:39 +0300 as excerpted:
2
3 > Do we ever had such case like multiple versions of the same
4 > single-slotted package installed or recorded as installed in the real
5 > world? I'm not sure even in this, but I may assume that it may happen
6 > one day.
7 >
8 > Do we have any proof that PM can recover from such situation,
9 > where VDB is a mess and installed files can also be a mess? I'm not sure
10 > in this at all.
11 >
12 > Do we have any test suits for portage (as the most popular PM
13 > implementation) for such cases? I doubt this, I can find none. I'm not
14 > sure if such tests are implemented in other PM test suits too.
15
16 Think of how a package is upgraded (by portage, I don't know enough about
17 the others to describe the process for them). The package is built, then
18 installed to a temporary location, then "qmerged" from the temporary
19 location to the live filesystem, replacing the previous version's files
20 and recording the new one in the installed-package database, then the old
21 version is unmerged and its record removed from the installed-package
22 database.
23
24 What happens if there's a crash in either the qmerge or old-version
25 unmerge steps?
26
27 Right, now there's parts of two versions in the installed-package
28 database, and who knows what files from each on the live filesystem.
29
30 I'm not a portage dev so won't comment on the test suite angle, but
31 portage has been able to handle this with the user simply redoing the
32 upgrade (whether from binpkg or full rebuild) for many years now (singe
33 before I became a gentooer in 2004, I know as I had some faulty hardware
34 at the time and regularly crashed during build and installs, which was
35 likely before REPLACING_VERSIONS was a thing), and given the number of
36 installations out there and the stress of parallel-building some packages
37 while others are installing, the code to handle this is GOING to get
38 regularly tested.
39
40 This needs to continue to work, thus the PMS rules, and ebuilds that are
41 unprepared to deal with it aren't going to help.
42
43 --
44 Duncan - List replies preferred. No HTML msgs.
45 "Every nonfree program has a lord, a master --
46 and if you use the program, he is your master." Richard Stallman

Replies