FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Gentoo > Gentoo Development

 
 
LinkBack Thread Tools
 
Old 04-21-2011, 02:23 AM
Jeroen Roovers
 
Default openrc portage news item

On Wed, 20 Apr 2011 20:12:21 -0500
Donnie Berkholz <dberkholz@gentoo.org> wrote:

> From a glance over the guide, it wasn't immediately obvious what in
> there would result in a broken system. Perhaps it's the "run
> dispatch-conf" that's buried in the middle of a paragraph without
> enough emphasis? That's particularly confusing for people who use
> etc-update instead, and it *needs* to move somewhere more obvious
> like a separate code listing with big <important> tags and bold text.
> The line of red text just isn't enough, it needs to stand out even
> more.

I have converted all my systems to baselayout-2/openrc now, and on all
of them, the very /last/ message shown after the emerge run is that "[x]
important configuration files [in /etc]" need to be updated.

I would think that Gentoo users are already primed to this message and
that they would respond accordingly. Even when it's dozens of packages
you have updated, this message should stand out, because it's basically
the first one you read scrolling back up.

> One potential cleaner approach to the same idea Kfir suggested is to
> make it an interactive emerge with an ACCEPT_LICENSE-like feature
> that pops up something you must read and agree to.

I've been thinking about an openrc mechanism that refuses rebooting
(reboot, halt, which are calls that openrc handles)
when /etc/{conf,init}.d files have not been updated. Anyone game to get
coding?


jer
 
Old 04-21-2011, 02:34 AM
Jeroen Roovers
 
Default openrc portage news item

On Thu, 21 Apr 2011 04:23:19 +0200
Jeroen Roovers <jer@gentoo.org> wrote:

> I have converted all my systems to baselayout-2/openrc now, and on all
> of them, the very /last/ message shown after the emerge run is that
> "[x] important configuration files [in /etc]" need to be updated.
>
> I would think that Gentoo users are already primed to this message and
> that they would respond accordingly. Even when it's dozens of packages
> you have updated, this message should stand out, because it's
> basically the first one you read scrolling back up.

Adding to that, the appropriate response is to not file a bug report or
complain otherwise, but to bow your head in shame, bring the system up
with some kind of boot medium and chroot in to run your favourite /etc
updating tool, then reboot cleanly and be running again.


jer
 
Old 04-22-2011, 10:39 AM
Lars Wendler
 
Default openrc portage news item

--
Lars Wendler (Polynomial-C)
Gentoo package maintainer and bug-wrangler

Am Donnerstag 21 April 2011, 03:12:21 schrieb Donnie Berkholz:
> On 13:32 Thu 14 Apr , Kfir Lavi wrote:
> > When i run world update, I usually don't really check all the written
> > stuff.
> >
> > If I do this, I'm sure a lot more Gentoo users do the same. So do
> > expect people rebooting the machine without checking what your have
> > wrote. This can be a major headache if you have few systems that are
> > doing auto updates. I would solve this issue by stopping the emerge
> > and getting the attention of the user. If I don't get the attention of
> > the user, no openrc will be installed. It should be something like
> > emerge -C ... 1 .2 3 4 5...
> >
> > To conclude, you can't issue such a change without proper confirmation
> > from the user.
>
> I know this is the case. You're going to get literally thousands of
> people (or more) who break their Gentoo systems if that indeed is the
> consequence of not reading the migration guide and doing some action.
>
> From a glance over the guide, it wasn't immediately obvious what in
> there would result in a broken system. Perhaps it's the "run
> dispatch-conf" that's buried in the middle of a paragraph without enough
> emphasis? That's particularly confusing for people who use etc-update
> instead, and it *needs* to move somewhere more obvious like a separate
> code listing with big <important> tags and bold text. The line of red
> text just isn't enough, it needs to stand out even more.
>
> It seems like nobody's really clear on what exactly happens though,
> since I've seen people talking about this *maybe* resulting in an
> unbootable system. Has anyone tested it?

I didn't test it intentionally. The last time I accidently rebooted a system
freshly moved to bl-2/openrc without updating the config files the boot process
threw a couple of strange errors. I cannot exactly remember what kind of
errors that were but the result was a system hanging in the middle of the boot
process with a message similar to "nothing left to do in this runlevel" and I
wasn't able to log into the system.
Another problem I've once encountered after updating a system to use openrc
was no running udev daemon after boot. I first didn't notice this but X didn't
start and funny part was that X won't tell you it cannot start because the
devicenodes in /dev for the graphics card were missing. So took me nearly a
day of frustrating research until I found that the udev init script wasn't
added to the sysinit runlevel. Of course this is mentioned in the migration
guide but it should be explicitly pointed out how fatal this can be to not
have udev getting started.

I can offer to "abuse" my two stable VMs (amd64 / x86) for this to test if
there's interest in getting "exact results".

> One potential cleaner approach to the same idea Kfir suggested is to
> make it an interactive emerge with an ACCEPT_LICENSE-like feature that
> pops up something you must read and agree to.
 
Old 04-29-2011, 07:08 AM
William Hubbs
 
Default openrc portage news item

All,

here is an updated version of the news item. If there are no
objections/corrections/criticisms, this will be committed on 2011/5/1.

This includes input from several comments I received on this thread.

Someone suggested that we make emerge not work until the news item is
read. There is nothing I can do in openrc to make something like that
happen. It would be something that would require a portage modification.
Also, that wouldn't really do much for us, because someone could still
read the news item, emerge the packages, then they could still end up
rebooting before they follow the steps, so I don't see what something
like that buys us.

I still do not have a link to the front page news item. If there isn't
one, should I delete the last paragraph before I commit?

Also, the way you can recover if you boot your system before following
the steps is mentioned in the news item now, and there's not really
anything more to it, so I'm not sure where else it should be mentioned.

What does everyone think?

William

Title: Baselayout update
Author: Christian Faulhammer <fauli@gentoo.org>
Author: William Hubbs <williamh@gentoo.org>
Content-Type: text/plain
Posted: 2011-05-01
Revision: 1
News-Item-Format: 1.0
Display-If-Installed: <sys-apps/baselayout-2

The baselayout package provides files which all systems must have in
order to function properly. You are currently using version 1.x, which
has several issues. The most significant of these is that the included
init scripts are written entirely in bash, which makes them slow and
not very flexible.

On 2011/05/08, you will see an update for sys-apps/baselayout to
2.x and a new package, sys-apps/openrc. It is recommended that you
perform this update as soon as possible.

Please note, after these packages are emerged, it is
__Absolutely_Critical__ that you immediately update your configuration
files with dispatch-conf, etc-update or a similar tool then follow the
steps in the migration guide located at the following URL.
http://www.gentoo.org/doc/en/openrc-migration.xml

FAILURE TO FOLLOW ALL OF THESE STEPS WILL RESULT IN AN UNBOOTABLE
SYSTEM! IF THIS SHOULD HAPPEN, YOU WILL NEED TO BOOT FROM A LIVE CD OR
DVD, MOUNT YOUR ROOT FILE SYSTEM, CHROOT INTO THAT ENVIRONMENT AND
FOLLOW THE ABOVE STEPS!

For more information or support regarding this change please see the
following:
- link to news item (should contain info regarding where to obtain support)
 
Old 04-29-2011, 11:21 AM
Rich Freeman
 
Default openrc portage news item

On Fri, Apr 29, 2011 at 3:08 AM, William Hubbs <williamh@gentoo.org> wrote:
> Someone suggested that we make emerge not work until the news item is
> read. There is nothing I can do in openrc to make something like that
> happen. It would be something that would require a portage modification.

Honestly - I see that as a future enhancement for portage/PMS/etc, and
not something that should hold up openrc. There are a number of
situations where such a feature would be useful, and trying to
shoehorn in a hack for openrc doesn't make sense.

Perhaps a future/in-progress EAPI could define a mechanism where an
ebuild can indicate that a particular update or set of circumstances
is a system-critical change, and that the package manager should
consequently alert the user and ensure that they have confirmed the
action. Then we have a nicely defined interface that we can use for
things like major baselayout changes, gcc/glibc ABI changes, and so
on.

Otherwise the best we can do is widely publicize the change (news,
lists, website, etc). In this case the news is out a full week before
the update, which I think is good timing (long enough that missing it
is less likely, not so long that forgetting it is likely).

Rich
 
Old 04-29-2011, 11:28 AM
Ciaran McCreesh
 
Default openrc portage news item

On Fri, 29 Apr 2011 07:21:23 -0400
Rich Freeman <rich0@gentoo.org> wrote:
> Perhaps a future/in-progress EAPI could define a mechanism where an
> ebuild can indicate that a particular update or set of circumstances
> is a system-critical change, and that the package manager should
> consequently alert the user and ensure that they have confirmed the
> action.

pkg_pretend can do that...

--
Ciaran McCreesh
 
Old 04-29-2011, 02:27 PM
Duncan
 
Default openrc portage news item

William Hubbs posted on Fri, 29 Apr 2011 02:08:31 -0500 as excerpted:

> Also, the way you can recover if you boot your system before following
> the steps is mentioned in the news item now, and there's not really
> anything more to it, so I'm not sure where else it should be mentioned.
>
> What does everyone think?

This one looks very reasonable, to me.

The bases are all covered including the level of criticality, what to do
to recover if it becomes necessary, and links for migration and further
information.

Thanks again for your work on this. =:^)

--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman
 
Old 04-29-2011, 05:18 PM
Alex Alexander
 
Default openrc portage news item

On Fri, Apr 29, 2011 at 12:28:03PM +0100, Ciaran McCreesh wrote:
> On Fri, 29 Apr 2011 07:21:23 -0400
> Rich Freeman <rich0@gentoo.org> wrote:
> > Perhaps a future/in-progress EAPI could define a mechanism where an
> > ebuild can indicate that a particular update or set of circumstances
> > is a system-critical change, and that the package manager should
> > consequently alert the user and ensure that they have confirmed the
> > action.
>
> pkg_pretend can do that...

indeed. it works quite well too. please have a look at the attached
patch. it forces the user to acknowledge and verify that he has read the
printed message by prepending a variable to the emerge command.

I know it is a bit nasty, but it accomplishes our goal by making sure
the users read the message.

--
Alex Alexander | wired
+ Gentoo Linux Developer
++ www.linuxized.com
Index: openrc-0.8.2-r1.ebuild
================================================== =================
RCS file: /var/cvsroot/gentoo-x86/sys-apps/openrc/openrc-0.8.2-r1.ebuild,v
retrieving revision 1.1
diff -u -B -r1.1 openrc-0.8.2-r1.ebuild
--- openrc-0.8.2-r1.ebuild 28 Apr 2011 19:50:51 -0000 1.1
+++ openrc-0.8.2-r1.ebuild 29 Apr 2011 17:10:34 -0000
@@ -2,7 +2,7 @@
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-apps/openrc/openrc-0.8.2-r1.ebuild,v 1.1 2011/04/28 19:50:51 williamh Exp $

-EAPI="1"
+EAPI="4"

inherit eutils flag-o-matic multilib toolchain-funcs

@@ -34,6 +34,22 @@
DEPEND="${RDEPEND}
virtual/os-headers"

+pkg_pretend() {
+ if [[ -z ${REPLACING_VERSIONS} ]] && [[ ${WARNING_OPENRC} != 1 ]]; then
+ eerror
+ eerror "You're upgrading your system to openrc. After emerge is"
+ eerror "complete, you MUST follow the guide located here:"
+ ewarn " http://www.gentoo.org/doc/en/openrc-migration.xml"
+ eerror "FAILING TO DO SO WILL PROBABLY RESULT IN AN *NON-BOOTABLE* SYSTEM."
+ eerror
+ eerror "To verify you read and understood this message, please prepend"
+ ewarn " WARNING_OPENRC=1"
+ eerror "to your emerge command."
+ eerror
+ die "We need user verification to proceed."
+ fi
+}
+
make_args() {
unset LIBDIR #266688
 
Old 04-29-2011, 05:25 PM
Ulrich Mueller
 
Default openrc portage news item

>>>>> On Fri, 29 Apr 2011, Alex Alexander wrote:

> please have a look at the attached patch.

> -EAPI="1"
> +EAPI="4"

Shouldn't the ebuild's phase functions be updated from "EAPI 0 style"
to "EAPI 2 style" too?

Ulrich
 
Old 04-29-2011, 05:32 PM
Alex Alexander
 
Default openrc portage news item

On Fri, Apr 29, 2011 at 07:25:12PM +0200, Ulrich Mueller wrote:
> >>>>> On Fri, 29 Apr 2011, Alex Alexander wrote:
>
> > please have a look at the attached patch.
>
> > -EAPI="1"
> > +EAPI="4"
>
> Shouldn't the ebuild's phase functions be updated from "EAPI 0 style"
> to "EAPI 2 style" too?

Yeah

My goal was to see that the idea actually works as intended and get
feedback from the list so I didn't make it that far.

--
Alex Alexander | wired
+ Gentoo Linux Developer
++ www.linuxized.com
 

Thread Tools




All times are GMT. The time now is 08:59 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org