[asterisk-bugs] [JIRA] (ASTERISK-21777) Asterisk tries to transcode video instead of audio

Leif Madsen (JIRA) noreply at issues.asterisk.org
Mon Jul 22 09:35:10 CDT 2013


    [ https://issues.asterisk.org/jira/browse/ASTERISK-21777?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=208122#comment-208122 ] 

Leif Madsen commented on ASTERISK-21777:
----------------------------------------

h2. Overview

This is very easy to reproduce. You just need to have codecs between end points which are mutually exclusive. A simple scenario:

peer 1:  supports ilbc (or g.729, or something not ulaw)
peer 2:  supports ulaw

Both peers support h264.


h3. Failing Scenario
Asterisk is configured with:


*peer 1*
{noformat}
disallow=all
allow=ilbc
allow=h264
{noformat}

*peer 2*
{noformat}
disallow=all
allow=ulaw
allow=h264
{noformat}

If you place a call at this point, you will get the weird transcoding error of Asterisk trying to transcode from an audio codec into a video codec. Of course this doesn't make any sense, and even if it did, Asterisk can't transcode into video.

h3. Working scenario
Leave everything the same on both end points. Peer 1 *only* supports ilbc and h264. Peer 2 *only* supports ulaw and h264.

Change the peer lists to have a mutually inclusive list of codecs:

{noformat}
disallow=all
allow=ilbc
allow=ulaw
allow=h264
{noformat}

With this configuration, the peer 1 will only offer ilbc and will then setup audio to Asterisk via ilbc. The offer to peer 2 will configure itself as only being able to speak ulaw. From what I can tell in the {{core show channel SIP/peer1-00001}} and {{core show channel SIP/peer2-00002}} output, Asterisk is speaking ilbc to peer 1, and ulaw to peer 2.

Without this mutually inclusive list, then the peers will get the weird one way audio and crazy WARNING spam on the screen.

I reproduced this with Asterisk 1.8.18.0, but it looks like the exact same issue all the way though to 11.3.0 as well.
                
> Asterisk tries to transcode video instead of audio
> --------------------------------------------------
>
>                 Key: ASTERISK-21777
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-21777
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Core/CodecInterface
>    Affects Versions: 11.3.0
>         Environment: Centos 6.4
>            Reporter: Nick Ruggles
>
> Asterisk keeps trying to transcode video into audio.
> Im trying to pass a call from peer 1, to peer 2.
> peer 1 has following enabled.
> disallow = all
> allow = g722,ulaw,alaw,h264
> peer 2 has the following enabled
> disallow = all
> allow = speex,ulaw,alaw,h264
> Unfortunately, i have to have g722 enabled on peer 1, and disabled on peer 2.
> Now i would have a successfull call if either, asterisk transcoded the g722 to ulaw or speex, or if asterisk negotiated the whole call to run on ulaw.
> instead i get these messages
> {noformat}
>    -- Executing [8008 at Servers:1] Answer("SIP/peer1-0000007c", "") in new stack
>     -- Executing [8008 at Servers:2] Dial("SIP/peer1-0000007c", "SIP/peer2/8008") in new stack
>   == Using SIP VIDEO CoS mark 6
>   == Using SIP RTP TOS bits 184
>   == Using SIP RTP CoS mark 5
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
>     -- Called SIP/peer2/8008
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:5081 ast_write: Codec mismatch on channel SIP/peer2-0000007d setting write format to g722 from unknown native formats (h264)
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:5309 set_format: Unable to find a codec translation path from (h264) to (g722)
> [May 10 09:17:00] WARNING[8952][C-00000042]: chan_sip.c:7280 sip_write: Asked to transmit frame type g722, while native formats is (h264) read/write = unknown/unknown
>     -- SIP/peer2-0000007d is ringing
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:5081 ast_write: Codec mismatch on channel SIP/peer2-0000007d setting write format to g722 from unknown native formats (h264)
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:5309 set_format: Unable to find a codec translation path from (h264) to (g722)
> [May 10 09:17:00] WARNING[8952][C-00000042]: chan_sip.c:7280 sip_write: Asked to transmit frame type g722, while native formats is (h264) read/write = unknown/unknown
> [May 10 09:17:00] WARNING[16119][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (nothing) formats
> [May 10 09:17:00] WARNING[16119][C-00000042]: channel.c:5309 set_format: Unable to find a codec translation path from (ulaw|h264) to (nothing)
> [May 10 09:17:00] WARNING[16119][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (nothing) formats
> [May 10 09:17:00] WARNING[16119][C-00000042]: channel.c:5309 set_format: Unable to find a codec translation path from (ulaw|h264) to (nothing)
>     -- SIP/peer2-0000007d answered SIP/peer1-0000007c
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
>     -- Locally bridging SIP/peer1-0000007c and SIP/peer2-0000007d
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:5081 ast_write: Codec mismatch on channel SIP/peer2-0000007d setting write format to g722 from h264 native formats (ulaw|h264)
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:940 ast_best_codec: Don't know any of (h264) formats
> [May 10 09:17:00] WARNING[8952][C-00000042]: channel.c:5081 ast_write: Codec mismatch on channel SIP/peer2-0000007d setting write format to g722 from h264 native formats (ulaw|h264)
> {noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.asterisk.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira



More information about the asterisk-bugs mailing list