[Home]

Summary:ASTERISK-24329: Music On Hold announcement cuts intro of music the first time it is played
Reporter:Thomas Frederiksen (ToMMeR)Labels:
Date Opened:2014-09-16 05:36:30Date Closed:2020-09-23 09:01:29
Priority:MinorRegression?
Status:Closed/CompleteComponents:Resources/res_musiconhold
Versions:SVN 11.12.0 11.15.1 Frequency of
Occurrence
Constant
Related
Issues:
is caused byASTERISK-27774 res_musiconhold: Music on hold restarts after every announcement
Environment:CentOSAttachments:
Description:musiconhold.conf is configured like this:
mode=files
sort=random
announcement=announement-file-path

When the caller enters musiconhold it seems the announcement and musiconhold starts simultaneously so that when the announcement ends the user doesn't hear the beginning of the musiconhold music. It cuts the intro of the music.
The musiconhold file should not start until the announcement has ended.

If the user waits until the first musiconhold file ends then the announcement is played correctly again and the next musiconhold file is played AFTER the announcement, as expected.

The problem only exists when the first musiconhold file is played / the announcement is played for the first time in a channel
Comments:By: Rusty Newton (rnewton) 2014-09-23 09:56:52.462-0500

Confirmed. Also, a note that it does not occur in Asterisk 12+.

By: Jean Aunis - Prescom (PrescomJA) 2016-08-22 10:52:50.602-0500

I have the same problem with Asterisk 13.7.2. My announcement has a length of 20 seconds, and I have a single sound file in the music on hold class with a duration of 10 seconds. At the end of the announcement, this file is not played at all and I can see in the CLI :
-- Stopped music on hold on SIP/XXXXXX

If I add 20 seconds of silence (the length of the announcement) at the beginning of this file, it works "correctly" : the file starts being read immediately after the silence.

By: Friendly Automation (friendly-automation) 2017-12-15 10:13:33.858-0600

Change 7582 merged by Jenkins2:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/7582|https://gerrit.asterisk.org/7582]

By: Friendly Automation (friendly-automation) 2017-12-15 10:26:35.926-0600

Change 7583 merged by Jenkins2:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/7583|https://gerrit.asterisk.org/7583]

By: Friendly Automation (friendly-automation) 2017-12-15 10:32:24.232-0600

Change 7584 merged by Jenkins2:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/7584|https://gerrit.asterisk.org/7584]

By: Marco Tarini (tarmak) 2018-02-01 09:56:31.813-0600

Hello,

this patch caused a problem (from my point of view) at moh.
I use asterisk 1.13.19 (the problem werent present in 1.13.17
I dont use announcement.
I use a contest where are the following instructions:
play 2 seconds of moh
do some curl
play 2 second of moh
ecc...
in  loop until got some good response from the curl.
Before this patch the music worked correctly, but now every time i do the play, the music start from the beginning.
I think that at the line 334 of asterisk/res/res_musiconhold.c (1.13.19) should be added come control before reset samples to 0.


By: Kevin Harwell (kharwell) 2018-04-17 13:51:35.756-0500

Re-opened due to the original patch causing other problems and being partially reverted. See ASTERISK-27774 for more details.

By: Sean Bright (seanbright) 2020-09-18 15:07:02.765-0500

The new review takes in to account both [~tarmak]'s comments from this issue as well as [~lvl]'s from ASTERISK-27774.

By: Friendly Automation (friendly-automation) 2020-09-23 09:01:31.353-0500

Change 14931 merged by Friendly Automation:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/c/asterisk/+/14931|https://gerrit.asterisk.org/c/asterisk/+/14931]

By: Friendly Automation (friendly-automation) 2020-09-23 10:04:44.056-0500

Change 14975 merged by Joshua Colp:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/c/asterisk/+/14975|https://gerrit.asterisk.org/c/asterisk/+/14975]

By: Friendly Automation (friendly-automation) 2020-09-23 10:05:02.483-0500

Change 14974 merged by Joshua Colp:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/c/asterisk/+/14974|https://gerrit.asterisk.org/c/asterisk/+/14974]

By: Friendly Automation (friendly-automation) 2020-09-23 10:05:23.268-0500

Change 14977 merged by Joshua Colp:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/c/asterisk/+/14977|https://gerrit.asterisk.org/c/asterisk/+/14977]

By: Friendly Automation (friendly-automation) 2020-09-23 11:27:12.514-0500

Change 14976 merged by Friendly Automation:
res_musiconhold: Start playlist after initial announcement

[https://gerrit.asterisk.org/c/asterisk/+/14976|https://gerrit.asterisk.org/c/asterisk/+/14976]