* opkg: How to make package signal reboot required?
@ 2013-08-01 1:28 Bryan Evenson
2013-08-01 8:44 ` Paul Eggleton
2013-08-01 10:32 ` Martin Jansa
0 siblings, 2 replies; 6+ messages in thread
From: Bryan Evenson @ 2013-08-01 1:28 UTC (permalink / raw)
To: Openembedded-devel@lists.openembedded.org
All,
I have a package that I created for my setup which, when upgraded, will require a system reboot. Is there a general flag/setting that already exists to put in my Bitbake recipe to signal that the package requires a reboot? If so, does it just set a flag that a reboot is required or does it force a reboot?
Regards,
Bryan
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: opkg: How to make package signal reboot required?
2013-08-01 1:28 opkg: How to make package signal reboot required? Bryan Evenson
@ 2013-08-01 8:44 ` Paul Eggleton
2013-08-01 10:32 ` Martin Jansa
1 sibling, 0 replies; 6+ messages in thread
From: Paul Eggleton @ 2013-08-01 8:44 UTC (permalink / raw)
To: Bryan Evenson; +Cc: openembedded-devel
Hi Bryan,
On Wednesday 31 July 2013 21:28:50 Bryan Evenson wrote:
> I have a package that I created for my setup which, when upgraded, will
> require a system reboot. Is there a general flag/setting that already
> exists to put in my Bitbake recipe to signal that the package requires a
> reboot? If so, does it just set a flag that a reboot is required or does
> it force a reboot?
It would be worth checking to see if the package manager has any intrinsic
support for this kind of thing; FWIW I don't know that the ones that we use do
(at least, we have no out-of-the-box integration for such functionality - I
know some package managers have "delay until end" functionality for things
like ldconfig and man page indexes, but we don't currently support this as far
as I know).
One approach (untested) that could work now however would be to define a
postinstall script for the package that would start another script in the
background or via cron; the latter script would then wait until the package
manager finished and then do whatever was necessary to restart the machine.
Cheers,
Paul
--
Paul Eggleton
Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: opkg: How to make package signal reboot required?
2013-08-01 1:28 opkg: How to make package signal reboot required? Bryan Evenson
2013-08-01 8:44 ` Paul Eggleton
@ 2013-08-01 10:32 ` Martin Jansa
2013-08-01 12:27 ` Bryan Evenson
2013-08-02 11:05 ` Paul Eggleton
1 sibling, 2 replies; 6+ messages in thread
From: Martin Jansa @ 2013-08-01 10:32 UTC (permalink / raw)
To: openembedded-devel
[-- Attachment #1: Type: text/plain, Size: 949 bytes --]
On Wed, Jul 31, 2013 at 09:28:50PM -0400, Bryan Evenson wrote:
> All,
>
> I have a package that I created for my setup which, when upgraded, will require a system reboot. Is there a general flag/setting that already exists to put in my Bitbake recipe to signal that the package requires a reboot? If so, does it just set a flag that a reboot is required or does it force a reboot?
I don't know about the feature to do the reboot, but we were using extra
metadata flags for .ipk to mark packages which need the reboot (so that
package manager can query updated packages and decide if it's needed).
See
http://patches.openembedded.org/patch/39181/
http://patches.openembedded.org/patch/39183/
I don't know why this wasn't ever merged in oe-core
http://lists.linuxtogo.org/pipermail/openembedded-core/2012-November/031856.html
doesn't have any negative review AFAIK.
--
Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: opkg: How to make package signal reboot required?
2013-08-01 10:32 ` Martin Jansa
@ 2013-08-01 12:27 ` Bryan Evenson
2013-08-02 11:02 ` Paul Eggleton
2013-08-02 11:05 ` Paul Eggleton
1 sibling, 1 reply; 6+ messages in thread
From: Bryan Evenson @ 2013-08-01 12:27 UTC (permalink / raw)
To: openembedded-devel@lists.openembedded.org; +Cc: Paul Eggleton
Martin and Paul,
Thanks for the replies. If there is nothing standard in place at the moment, then I'm planning on setting things up on my end to follow the standard (from what I can tell) Debian practice. In my pkg_postinst, I'm going to add the lines:
#!/bin/sh -e
if test "x$D" = "x"; then
touch /var/run/reboot-required
cat ${PN} >> /var/run/reboot-required.pkgs
fi
Then in my script that does the firmware upgrade, I'll check for the existence of /var/run/reboot-required to determine whether the system needs to be rebooted.
If anything can be done to add the above (or something similar) to the pkg_postinst by setting a flag in the Bitbake recipe, I'm all for it. I'm not quite sure which piece would be responsible for such action (oe-core? Bitbake? Something else?). If someone could suggest the proper place, I'd happily submit a request on the proper bug tracker.
Regards,
Bryan
> -----Original Message-----
> From: openembedded-devel-bounces@lists.openembedded.org
> [mailto:openembedded-devel-bounces@lists.openembedded.org] On Behalf Of
> Martin Jansa
> Sent: Thursday, August 01, 2013 6:33 AM
> To: openembedded-devel@lists.openembedded.org
> Subject: Re: [oe] opkg: How to make package signal reboot required?
>
> On Wed, Jul 31, 2013 at 09:28:50PM -0400, Bryan Evenson wrote:
> > All,
> >
> > I have a package that I created for my setup which, when upgraded,
> will require a system reboot. Is there a general flag/setting that
> already exists to put in my Bitbake recipe to signal that the package
> requires a reboot? If so, does it just set a flag that a reboot is
> required or does it force a reboot?
>
> I don't know about the feature to do the reboot, but we were using
> extra metadata flags for .ipk to mark packages which need the reboot
> (so that package manager can query updated packages and decide if it's
> needed).
>
> See
> http://patches.openembedded.org/patch/39181/
> http://patches.openembedded.org/patch/39183/
>
> I don't know why this wasn't ever merged in oe-core
> http://lists.linuxtogo.org/pipermail/openembedded-core/2012-
> November/031856.html
> doesn't have any negative review AFAIK.
>
> --
> Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: opkg: How to make package signal reboot required?
2013-08-01 12:27 ` Bryan Evenson
@ 2013-08-02 11:02 ` Paul Eggleton
0 siblings, 0 replies; 6+ messages in thread
From: Paul Eggleton @ 2013-08-02 11:02 UTC (permalink / raw)
To: Bryan Evenson; +Cc: openembedded-devel
Hi Bryan,
On Thursday 01 August 2013 08:27:32 Bryan Evenson wrote:
> Thanks for the replies. If there is nothing standard in place at the
> moment, then I'm planning on setting things up on my end to follow the
> standard (from what I can tell) Debian practice. In my pkg_postinst, I'm
> going to add the lines:
>
> #!/bin/sh -e
> if test "x$D" = "x"; then
> touch /var/run/reboot-required
> cat ${PN} >> /var/run/reboot-required.pkgs
> fi
>
> Then in my script that does the firmware upgrade, I'll check for the
> existence of /var/run/reboot-required to determine whether the system needs
> to be rebooted.
>
> If anything can be done to add the above (or something similar) to the
> pkg_postinst by setting a flag in the Bitbake recipe, I'm all for it. I'm
> not quite sure which piece would be responsible for such action (oe-core?
> Bitbake? Something else?). If someone could suggest the proper place, I'd
> happily submit a request on the proper bug tracker.
Since this is something that would be implemented in OE-Core the best place
for this would be the Yocto Project bugzilla which tracks bugs/enhancements
for that:
https://bugzilla.yoctoproject.org/
If you could file it under Runtime -> Package Management Issues ->
package-management-Issues and mark it as "enhancement" in the severity column
that would be great.
Cheers,
Paul
--
Paul Eggleton
Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: opkg: How to make package signal reboot required?
2013-08-01 10:32 ` Martin Jansa
2013-08-01 12:27 ` Bryan Evenson
@ 2013-08-02 11:05 ` Paul Eggleton
1 sibling, 0 replies; 6+ messages in thread
From: Paul Eggleton @ 2013-08-02 11:05 UTC (permalink / raw)
To: Martin Jansa; +Cc: openembedded-devel
On Thursday 01 August 2013 12:32:52 Martin Jansa wrote:
> I don't know about the feature to do the reboot, but we were using extra
> metadata flags for .ipk to mark packages which need the reboot (so that
> package manager can query updated packages and decide if it's needed).
>
> See
> http://patches.openembedded.org/patch/39181/
> http://patches.openembedded.org/patch/39183/
>
> I don't know why this wasn't ever merged in oe-core
> http://lists.linuxtogo.org/pipermail/openembedded-core/2012-November/031856.
> html doesn't have any negative review AFAIK.
I recall seeing these, I'm not sure why they weren't accepted either, but it
might have had something to do with wanting more specific feature
implementation(s) rather than a generic way to pass anything through to the
package manager. The best thing would probably be to ask Richard directly when
he returns.
Cheers,
Paul
--
Paul Eggleton
Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2013-08-02 11:05 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-01 1:28 opkg: How to make package signal reboot required? Bryan Evenson
2013-08-01 8:44 ` Paul Eggleton
2013-08-01 10:32 ` Martin Jansa
2013-08-01 12:27 ` Bryan Evenson
2013-08-02 11:02 ` Paul Eggleton
2013-08-02 11:05 ` Paul Eggleton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.