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 > Debian > Debian Development

 
 
LinkBack Thread Tools
 
Old 07-19-2012, 08:40 AM
kix
 
Default Bug #680861 - change postinst or bug in debhelper?

El 2012-07-19 10:00, Reinier Haasjes escribió:

Hi All,

I'm trying to resolve bug #680861 where the problem is that if the
config of aiccu is incorrect and thus the program can't start it
breaks

the upgrade.

In the aiccu.postinst i have the line: "#DEBHELPER#", debhelper
replaces

this with:
# Automatically added by dh_installinit
if [ -x "/etc/init.d/aiccu" ]; then
update-rc.d aiccu defaults >/dev/null
invoke-rc.d aiccu start || exit $?
fi
# End automatically added section

The problem is "invoke-rc.d aiccu start || exit $?" which exits the
postinst with an error if aiccu fails to start and thus brakes the
upgrade.


Hi Reinier,

probably you could check the reasons why the aiccu start script can
fail and "catch" them. For example, if aiccu needs a file or device that
don't exists, the start script could show a info message like "The file
x was not found. Not starting aiccu" but don't return an error.


Regards.
kix


I want to change this to "invoke-rc.d aiccu start || true" but then I
have to remove the "#DEBHELPER#" line and do it 'manually', ofcourse
this isn't the problem but I prefer to use debhelper as much as
possible.


The problem is that if I (/aiccu) have this problem than other
packages

should have the same problem and this would be a debpacker bug.
Is this a debhelper bug and should I report a bug or should I just
replace the code so it works for aiccu?

Thanks in advance for you advise.

Regards,

Reinier


--
Rodolfo García Peñas (kix)
http://www.kix.es


--
To UNSUBSCRIBE, email to debian-devel-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: df6633be3b632330215739de38f5380e@mail.kix.es">http ://lists.debian.org/df6633be3b632330215739de38f5380e@mail.kix.es
 
Old 07-19-2012, 08:52 AM
Michael Biebl
 
Default Bug #680861 - change postinst or bug in debhelper?

On 19.07.2012 10:00, Reinier Haasjes wrote:
> Hi All,
>
> I'm trying to resolve bug #680861 where the problem is that if the
> config of aiccu is incorrect and thus the program can't start it breaks
> the upgrade.

If the configuration is incorrect and aiccu fails because of that, I
think it is also correct if the postinst fails. Otherwise this problem
would go unnoticed.

> I want to change this to "invoke-rc.d aiccu start || true" but then I
> have to remove the "#DEBHELPER#" line and do it 'manually', ofcourse
> this isn't the problem but I prefer to use debhelper as much as possible.
>
> The problem is that if I (/aiccu) have this problem than other packages
> should have the same problem and this would be a debpacker bug.
> Is this a debhelper bug and should I report a bug or should I just
> replace the code so it works for aiccu?
>

You can use dh_installinit's --error-handler option for that.

But as said, I don't think it is a good idea to hide errors.


Michael

--
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?
 

Thread Tools




All times are GMT. The time now is 10:07 PM.

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