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 > Ubuntu > Ubuntu Masters Of The Universe

 
 
LinkBack Thread Tools
 
Old 07-01-2011, 02:23 PM
Christoph Mathys
 
Default reload kernel module from initscript during package update

I've got a package which contains a kernel module (packaged with
dkms). This kernel module is loaded by an init-script, which is also
part of the package. Now the problem is this: If an application is
running and using the device, the init script fails when it tries to
reload the updated module, which right now causes the package
installation to fail.

Now the question is: Are there any best practices to handle this sort of thing?

I thinking of implementing one of the following ideas:
I could ask the user with a debconf dialog if he wants to terminate
the application[s] holding the device node open, warning that an old
module version is used if the applications are not terminated.

I could also just leave the module loaded and give a hint, that the
modules initscript needs to be called with restart.

Christoph

--
Ubuntu-motu mailing list
Ubuntu-motu@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-motu
 
Old 07-01-2011, 02:26 PM
Mario Limonciello
 
Default reload kernel module from initscript during package update

On Fri, Jul 1, 2011 at 09:23, Christoph Mathys <eraserix@gmail.com> wrote:

I've got a package which contains a kernel module (packaged with

dkms). This kernel module is loaded by an init-script, which is also

part of the package. Now the problem is this: If an application is

running and using the device, the init script fails when it tries to

reload the updated module, which right now causes the package

installation to fail.



Now the question is: Are there any best practices to handle this sort of thing?



I thinking of implementing one of the following ideas:

I could ask the user with a debconf dialog if he wants to terminate

the application[s] holding the device node open, warning that an old

module version is used if the applications are not terminated.



I could also just leave the module loaded and give a hint, that the

modules initscript needs to be called with restart.



Christoph



--

Ubuntu-motu mailing list

Ubuntu-motu@lists.ubuntu.com

Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-motu


Why not set up the module to load on demand from a modalias instead?
--
Mario Limonciello
superm1@gmail.com


--
Ubuntu-motu mailing list
Ubuntu-motu@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-motu
 
Old 07-01-2011, 03:43 PM
Chow Loong Jin
 
Default reload kernel module from initscript during package update

On 01/07/2011 22:26, Mario Limonciello wrote:
> On Fri, Jul 1, 2011 at 09:23, Christoph Mathys <eraserix@gmail.com
> <mailto:eraserix@gmail.com>> wrote:
>
> I've got a package which contains a kernel module (packaged with
> dkms). This kernel module is loaded by an init-script, which is also
> part of the package. Now the problem is this: If an application is
> running and using the device, the init script fails when it tries to
> reload the updated module, which right now causes the package
> installation to fail.
>
> Now the question is: Are there any best practices to handle this sort of thing?
>
> I thinking of implementing one of the following ideas:
> I could ask the user with a debconf dialog if he wants to terminate
> the application[s] holding the device node open, warning that an old
> module version is used if the applications are not terminated.
>
> I could also just leave the module loaded and give a hint, that the
> modules initscript needs to be called with restart.
>
> Christoph
>
> --
> Ubuntu-motu mailing list
> Ubuntu-motu@lists.ubuntu.com <mailto:Ubuntu-motu@lists.ubuntu.com>
> Modify settings or unsubscribe at:
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-motu
>
>
> Why not set up the module to load on demand from a modalias instead?

I think the issue is less to do with the initscript and more to do with
reloading the module -- after the upgrade, the postinst doesn't manage to reload
the module because something is holding onto the device node.

--
Kind regards,
Loong Jin

--
Ubuntu-motu mailing list
Ubuntu-motu@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-motu
 

Thread Tools




All times are GMT. The time now is 09:56 PM.

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