Bug#605507: your mail

2010-12-19 Thread Jonas Smedegaard

On Mon, Dec 20, 2010 at 12:26:59PM +0900, d+...@vdr.jp wrote:

On Fri, Dec 17, 2010 at 04:35:33PM +0100, Julien Cristau wrote:

> @@ -45,6 +45,9 @@
>  # Tightened permissions for the config file
>  chmod -R ug=rw,o=,ug+X /etc/icecast2/icecast.xml
>
> +# avoid to fail on invoke-rc.d icecast2 start when upgrading see Bug#605507
> +sleep 3
> +

What is this supposed to achieve?


When upgrading icecast2, stop (in prerm) and start (in postinst) process.
In some case, icecast2 gets signal and stops after a while.
If icecast2 process still exists, start fails.
So it waits for process really stopping.
Old icecast2's init does not have "--retry TERM/5/0/30" option,
so I put "sleep 3" in postinst for upgrading icecast2.



Ahh, thanks for clarifying - I was wondering too.

In that case it is probably better to do something like this in preinst 
or postinst (doublecheck that it works - below is only pseudocode!):


if [ "$1" = "upgrade" ] && dpkg --compare-versions "$2" le 2.3.2-6; then
  pkill icecast2
fi


 - Jonas

--
 * Jonas Smedegaard - idealist & Internet-arkitekt
 * Tlf.: +45 40843136  Website: http://dr.jones.dk/

 [x] quote me freely  [ ] ask before reusing  [ ] keep private


signature.asc
Description: Digital signature
___
pkg-multimedia-maintainers mailing list
pkg-multimedia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/mailman/listinfo/pkg-multimedia-maintainers


Bug#605507: your mail

2010-12-19 Thread d+deb
On Fri, Dec 17, 2010 at 04:35:33PM +0100, Julien Cristau wrote:
> > @@ -45,6 +45,9 @@
> >  # Tightened permissions for the config file
> >  chmod -R ug=rw,o=,ug+X /etc/icecast2/icecast.xml
> >  
> > +# avoid to fail on invoke-rc.d icecast2 start when upgrading see Bug#605507
> > +sleep 3
> > +
> 
> What is this supposed to achieve?

When upgrading icecast2, stop (in prerm) and start (in postinst) process.
In some case, icecast2 gets signal and stops after a while.
If icecast2 process still exists, start fails.
So it waits for process really stopping.
Old icecast2's init does not have "--retry TERM/5/0/30" option,
so I put "sleep 3" in postinst for upgrading icecast2.
-- 
Regards,
dai

GPG Fingerprint = 0B29 D88E 42E6 B765 B8D8 EA50 7839 619D D439 668E


signature.asc
Description: Digital signature
___
pkg-multimedia-maintainers mailing list
pkg-multimedia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/mailman/listinfo/pkg-multimedia-maintainers


Bug#605507: your mail

2010-12-17 Thread Julien Cristau
On Mon, Dec  6, 2010 at 19:06:59 +0900, d+...@vdr.jp wrote:

> tags 605507 + patch
> thanks
> 
> Hi,
> 
> Here is third try.
> Would you please try it?
> 
> diff -u icecast2-2.3.2/debian/icecast2.init 
> icecast2-2.3.2/debian/icecast2.init
> --- icecast2-2.3.2/debian/icecast2.init   2010-12-06 18:48:19.0 
> +0900
> +++ icecast2-2.3.2/debian/icecast2.init   2010-12-06 18:38:24.0 
> +0900
> @@ -51,7 +51,8 @@
>   ;;
>stop)
>   echo -n "Stopping $DESC: "
> - start-stop-daemon --stop --oknodo --quiet --exec $DAEMON
> + # Send TERM after 5 seconds, wait at most 30 seconds.
> + start-stop-daemon --stop --oknodo --retry TERM/5/0/30 --quiet --exec 
> $DAEMON
>   echo "$NAME."
>   ;;
>reload|force-reload)
> diff -u icecast2-2.3.2/debian/icecast2.postinst 
> icecast2-2.3.2/debian/icecast2.postinst
> --- icecast2-2.3.2/debian/icecast2.postinst   2010-12-06 18:48:19.0 
> +0900
> +++ icecast2-2.3.2/debian/icecast2.postinst   2010-12-06 18:52:07.0 
> +0900
> @@ -45,6 +45,9 @@
>  # Tightened permissions for the config file
>  chmod -R ug=rw,o=,ug+X /etc/icecast2/icecast.xml
>  
> +# avoid to fail on invoke-rc.d icecast2 start when upgrading see Bug#605507
> +sleep 3
> +

What is this supposed to achieve?

>  #DEBHELPER#
>  
>  exit 0
> 
Cheers,
Julien


signature.asc
Description: Digital signature
___
pkg-multimedia-maintainers mailing list
pkg-multimedia-maintainers@lists.alioth.debian.org
http://lists.alioth.debian.org/mailman/listinfo/pkg-multimedia-maintainers