[asterisk-bugs] [Asterisk 0019032]: Voicemail messages (ODBC), incorrect sequence, msgnum=0 missing! Messages Over written

Asterisk Bug Tracker noreply at bugs.digium.com
Tue Mar 29 04:48:17 CDT 2011


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=19032 
====================================================================== 
Reported By:                alecdavis
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   19032
Category:                   Applications/app_voicemail/ODBC
Reproducibility:            random
Severity:                   major
Priority:                   high
Status:                     new
Asterisk Version:           SVN 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2011-03-28 18:53 CDT
Last Modified:              2011-03-29 04:48 CDT
====================================================================== 
Summary:                    Voicemail messages (ODBC), incorrect sequence,
msgnum=0 missing! Messages Over written
Description: 
Repeatble: Asterisk 1.8.2.3 and Trunk

Users are unable to receive any further messages, until I have updated the
database, so that the msgnum is 0.

Users are unable to clear mailbox, Voicemail reports 1 new message, but
they are unable to clear it.

When trying to clear it, we get console message
2011-03-29 09:57:19.780] WARNING[22841]: app_voicemail.c:7570
play_message: No origtime?!

This seems exacltly like https://issues.asterisk.org/view.php?id=18740 but the
fix there only covers file based
storage.
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
related to          0018582 Problem reading a message which was pre...
====================================================================== 

---------------------------------------------------------------------- 
 (0133158) alecdavis (manager) - 2011-03-29 04:48
 https://issues.asterisk.org/view.php?id=19032#c133158 
---------------------------------------------------------------------- 
This example is 3 messages pre existed.

Rang in to listen to messages and deleted 1 message, while on a another
phone left another message.

Notice a gap between message 1 and 3.
  
<pre>mysql> select id,dir,msgnum,mailboxuser,origtime from voicemessages
where mailboxuser = '8612' order by msgnum;
+----+--------------------------------------------------+--------+-------------+------------+
| id | dir                                              | msgnum |
mailboxuser | origtime   |
+----+--------------------------------------------------+--------+-------------+------------+
| 17 | /var/spool/asterisk/voicemail/default/8612/INBOX |      0 | 8612   
    | 1301369768 |
| 18 | /var/spool/asterisk/voicemail/default/8612/INBOX |      1 | 8612   
    | 1301370616 |
| 19 | /var/spool/asterisk/voicemail/default/8612/INBOX |      2 | 8612   
    | 1301390537 |
| 20 | /var/spool/asterisk/voicemail/default/8612/INBOX |      3 | 8612   
    | 1301390749 |
+----+--------------------------------------------------+--------+-------------+------------+
4 rows in set (0.00 sec)

mysql> select id,dir,msgnum,mailboxuser,origtime from voicemessages where
mailboxuser = '8612' order by msgnum;
+----+--------------------------------------------------+--------+-------------+------------+
| id | dir                                              | msgnum |
mailboxuser | origtime   |
+----+--------------------------------------------------+--------+-------------+------------+
| 18 | /var/spool/asterisk/voicemail/default/8612/INBOX |      0 | 8612   
    | 1301370616 |
| 19 | /var/spool/asterisk/voicemail/default/8612/INBOX |      1 | 8612   
    | 1301390537 |
| 20 | /var/spool/asterisk/voicemail/default/8612/INBOX |      3 | 8612   
    | 1301390749 |
+----+--------------------------------------------------+--------+-------------+------------+
3 rows in set (0.00 sec)
</pre>

The problem appears to be in close_mailbox
Where close_mailbox only uses the number of messages that existed when the
mailbox was opened, but in the background another message was added by a
caller. 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2011-03-29 04:48 alecdavis      Note Added: 0133158                          
======================================================================




More information about the asterisk-bugs mailing list