#782438 timidity-daemon: fails to start at boot-up but timidity starts manually ok

#782438#5
Date:
2015-04-12 08:58:21 UTC
From:
To:
Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?

Having timidity-daemon installed.

   * What exactly did you do (or not do) that was effective (or
     ineffective)?

tried running the start-up script manually, resulted in no timidity
daemon running:

# sh -x /etc/init.d/timidity start
+ . /lib/lsb/init-functions
+++ run-parts --lsbsysinit --list /lib/lsb/init-functions.d
++ for hook in '$(run-parts --lsbsysinit --list /lib/lsb/init-functions.d 2>/dev/null)'
++ '[' -r /lib/lsb/init-functions.d/20-left-info-blocks ']'
++ . /lib/lsb/init-functions.d/20-left-info-blocks
++ FANCYTTY=
++ '[' -e /etc/lsb-base-logging.sh ']'
++ true
+ NAME=timidity
+ PATH=/sbin:/bin:/usr/sbin:/usr/bin
+ DAEMON=/usr/bin/timidity
+ DESC='TiMidity++ ALSA midi emulation'
+ PIDFILE=/var/run/timidity/timidity.pid
+ set -e
+ test -x /usr/bin/timidity
+ TIM_ALSASEQ=true
+ TIM_ALSASEQPARAMS=-B2,8
+ '[' -r /etc/default/timidity ']'
+ . /etc/default/timidity
++ SERVER_HOME=/etc/timidity
++ SERVER_USER=timidity
++ SERVER_NAME='TiMidity++ MIDI sequencer service'
++ SERVER_GROUP=timidity
++ ADDGROUP=audio
++ TIM_ALSASEQPARAMS=-Os
+ '[' true '!=' true ']'
+ '[' -z timidity ']'
+ '[' -z timidity ']'
+ getent passwd
+ grep -q '^timidity:'
+ getent group
+ grep -q '^timidity:'
+ PARAMS='-Os -iAD'
+ START='--start --chuid timidity --quiet --exec /usr/bin/timidity --pidfile /var/run/timidity/timidity.pid -- -Os -iAD'
+ case "$1" in
+ '[' -d /proc/asound ']'
+ '[' -d /dev/snd/ ']'
+ log_begin_msg 'Starting TiMidity++ ALSA midi emulation...'
+ log_begin_msg_pre 'Starting TiMidity++ ALSA midi emulation...'
+ log_daemon_msg_pre 'Starting TiMidity++ ALSA midi emulation...'
+ log_use_fancy_output
+ TPUT=/usr/bin/tput
+ EXPR=/usr/bin/expr
+ '[' -t 1 ']'
+ '[' xxterm '!=' x ']'
+ '[' xxterm '!=' xdumb ']'
+ '[' -x /usr/bin/tput ']'
+ '[' -x /usr/bin/expr ']'
+ /usr/bin/tput hpa 60
+ /usr/bin/tput setaf 1
+ '[' -z ']'
+ FANCYTTY=1
+ case "$FANCYTTY" in
+ true
+ echo -n '[....] '
[....] + '[' -z 'Starting TiMidity++ ALSA midi emulation...' ']'
+ echo -n 'Starting TiMidity++ ALSA midi emulation...'
Starting TiMidity++ ALSA midi emulation...+ log_begin_msg_post 'Starting TiMidity++ ALSA midi emulation...'
+ :
+ mkdir -p /var/run/timidity
+ chown timidity /var/run/timidity
+ start-stop-daemon --start --chuid timidity --quiet --exec /usr/bin/timidity --pidfile /var/run/timidity/timidity.pid -- -Os -iAD
+ log_end_msg 0
+ '[' -z 0 ']'
+ local retval
+ retval=0
+ log_end_msg_pre 0
+ log_use_fancy_output
+ TPUT=/usr/bin/tput
+ EXPR=/usr/bin/expr
+ '[' -t 1 ']'
+ '[' xxterm '!=' x ']'
+ '[' xxterm '!=' xdumb ']'
+ '[' -x /usr/bin/tput ']'
+ '[' -x /usr/bin/expr ']'
+ /usr/bin/tput hpa 60
+ /usr/bin/tput setaf 1
+ '[' -z 1 ']'
+ true
+ case "$FANCYTTY" in
+ true
++ /usr/bin/tput setaf 1
+ RED=''
++ /usr/bin/tput setaf 2
+ GREEN=''
++ /usr/bin/tput setaf 3
+ YELLOW=''
++ /usr/bin/tput op
+ NORMAL=''
+ /usr/bin/tput civis
+ /usr/bin/tput sc
+ /usr/bin/tput hpa 0
+ '[' 0 -eq 0 ']'
+ /bin/echo -ne '[ ok '
[ ok + /usr/bin/tput rc
+ /usr/bin/tput cnorm
+ log_use_fancy_output
+ TPUT=/usr/bin/tput
+ EXPR=/usr/bin/expr
+ '[' -t 1 ']'
+ '[' xxterm '!=' x ']'
+ '[' xxterm '!=' xdumb ']'
+ '[' -x /usr/bin/tput ']'
+ '[' -x /usr/bin/expr ']'
+ /usr/bin/tput hpa 60
+ /usr/bin/tput setaf 1
+ '[' -z 1 ']'
+ true
+ case "$FANCYTTY" in
+ true
++ /usr/bin/tput setaf 1
+ RED=''
++ /usr/bin/tput setaf 3
+ YELLOW=''
++ /usr/bin/tput op
+ NORMAL=''
+ '[' 0 -eq 0 ']'
+ echo .
.
+ log_end_msg_post 0
+ :
+ return 0
+ exit 0

Starting manually using:

#  /usr/bin/timidity -Os -iAD
Requested buffer size 32768, fragment size 8192
ALSA pcm 'default' set buffer size 30104, period size 3760 bytes
TiMidity starting in ALSA server mode
Opening sequencer port: 128:0 128:1 128:2 128:3
Requested buffer size 32768, fragment size 8192
ALSA pcm 'default' set buffer size 30104, period size 3760 bytes
Requested buffer size 32768, fragment size 8192
ALSA pcm 'default' set buffer size 30104, period size 3760 bytes
Playing time: ~65 seconds

worked fine with Rosegarden

   * What was the outcome of this action?
   * What outcome did you expect instead?

*** End of the template - remove these template lines ***

#782438#10
Date:
2015-04-12 13:25:44 UTC
From:
To:
Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?

After starting timidity manually as mentioned in the previous message,
timidity could be successfully restarted via the init script (even though
it didn't get started at boot-up or attempting to run the init script).

# checkrestart

The following packages seem to have definitions that could be used
to restart their services:
timidity:
        7466    /usr/bin/timidity

These are the initd scripts:
service timidity restart

am64:/usr/src/linux# service timidity restart
[ ok ] Stopping TiMidity++ ALSA midi emulation....
[ ok ] Starting TiMidity++ ALSA midi emulation....

am64:/usr/src/linux# ps -ef|grep timidity
timidity 18558     1  0 22:47 pts/3    00:00:00 /usr/bin/timidity -Os -iAD
root     18775  7674  0 22:47 pts/3    00:00:00 grep timidity


   * What exactly did you do (or not do) that was effective (or
     ineffective)?
   * What was the outcome of this action?
   * What outcome did you expect instead?

*** End of the template - remove these template lines ***

#782438#15
Date:
2015-04-12 18:11:03 UTC
From:
To:
control: severity -1 important

Given the straightforward workaround, this isn't a grave issue.

Best wishes,
Mike