No message in cli

Hi,

I started my * experience with asterisk@home 2.0 on a dedicated server.
I configured all and it worked well.

Now, I want to migrate all this configuration to my Gentoo server.
All seems to work fine, but, I have no info message in cli.
On asterisk@home, I could see (with colors), all calls passed.
If I set debug, I have all debug informations, but that’s not what I want.

Any idea please ?

Thanks

PS : sorry for my bad english. As you can see, it’s not my native language :wink:

I’m so stupid.

I just had to start cli mode with verbose level.

In fact, asterisk init script from AAH is different from Gentoo. It already have the -vvv option.
But, if I had this option in my /etc/conf.d/asterisk, the init script doesn’t launch it as a daemon.
So I just have now to start cli by asterisk -c -vvv, but, I have no color on this one :frowning:
I don’t know why.

depends on how you start it. You can always invoke it from the CLI by typing set verbose 3, that will give you the output for call processing.

Yes, but with no color…

are you using the safe_asterisk script to start it? Are you using an init script (so you can do service asterisk start)? You can add to either one,
export TERM=vt100 to either one near the top and you will get your color back!

No safe_asterisk, just init script from gentoo package.
I had export TERM=vt100 in the script, but no more color.

Here is this script :

[code]#!/sbin/runscript

Copyright 1999-2004 Gentoo Foundation

Distributed under the terms of the GNU General Public License v2

$Header: /var/cvsroot/gentoo-x86/net-misc/asterisk/files/1.0.0/asterisk.rc6.sec,v 1.4 2005/08/24 21:13:56 dragonheart Exp $

export TERM=vt100

depend() {
need net
use zaptel mysql postgresql
}

start() {
local OPTS USER GROUP

    if [[ -n "${ASTERISK_NICE}" ]]; then
            if [[ ${ASTERISK_NICE} -ge -20 ]] && \
               [[ ${ASTERISK_NICE} -le  19 ]]; then
                    OPTS="--nicelevel ${ASTERISK_NICE}"
            else
                    eerror "Nice value must be between -20 and 19"
            fi
    fi

    if [[ -n "${ASTERISK_USER}" ]]; then
            USER=${ASTERISK_USER/:*/}
            GROUP=$(echo $ASTERISK_USER | awk -F: '/.*:.*/ { print $2 }')
            if [[ -n "${USER}" ]]; then
                    ASTERISK_OPTS="${ASTERISK_OPTS} -U ${USER}"
            fi
            if [[ -n "${GROUP}" ]]; then
                    ASTERISK_OPTS="${ASTERISK_OPTS} -G ${GROUP}"
                    GROUP=":${GROUP}"       # make it look nice...
            fi
            ebegin "Starting asterisk PBX (as ${USER}${GROUP})"
    else
            ebegin "Starting asterisk PBX (as root)"
    fi
            start-stop-daemon --start --exec /usr/sbin/asterisk \
                    ${OPTS} -- ${ASTERISK_OPTS}
    eend $?

}

stop() {
ebegin "Stopping asterisk PBX"
start-stop-daemon --stop --pidfile /var/run/asterisk/asterisk.pid
eend $?
}[/code]

But it is very specific to gentoo.

i think perhaps asterisk has to run on a TTY to get color?

I don’t know at all.

I’ll put a bug in gentoo tracker.

its not really a bug as much as a config issue… you need to tell asterisk to run on TTYx. Its a command line option as i recall.

So it is a bug from the gentoo init script :wink:

I don’t have to modify this script. It comes from gentoo ebuild for asterisk.

ahh :smiley:

:smile:

I never thought it was a asterisk bug, because all is fine in asterisk@home, but not with gentoo package, same version 1.2.

But my english is so bad that I’m usualy not understood :wink: