[asterisk-users] IOPS required by Asterisk for Call Recording

Amit amit at avhan.com
Fri Jan 24 23:26:01 CST 2014


Thanks for response.
How do I derive the requirement? I need to size IO system to record multiple calls concurrently.
I ran test with following configuration
Quad Core Xeon with 4GB RAM
250GB SATA disk (No RAID)
Linux (CentOS 5.9)
Asterisk 1.8.20

I failed to record more than 80 calls.

If I run test with simple IVR, I achieved 400+ calls with same server.
So write seem to be an issue.
Is there any way to tune / optimize / configure for better write performance?

I am not sure if I need to post this query on developers list? Please guide...

Regards
Amit Patkar

Message: 1
Date: Fri, 24 Jan 2014 11:46:39 -0400
From: Mike<ispbuilder at gmail.com>
To: Asterisk Users Mailing List - Non-Commercial Discussion
	<asterisk-users at lists.digium.com>
Subject: Re: [asterisk-users] IOPS required by Asterisk for Call
	Recording
Message-ID:<52E28ADF.8020409 at gmail.com>
Content-Type: text/plain; charset="iso-8859-1"

On 14-01-24 11:16 AM, Amit wrote:

> If I assume that Asterisk will write data on disk every second for
> each call, I will need disk array to support minimum of 500 IOPS.
> Where as if Asterisk push data every 2 seconds, I can deal with array
> supporting 250 IOPS.
> But if I assume that Asterisk will write data on disk for every RTP
> packet received, as and when received, I will need disk IO system with
> approx 25000 IOPS assuming 20 ms RTP packet.

You're assuming that asterisk will perform an fsync() after each write.
If asterisk writes without an fsync after each write, then the OS will
schedule writes intelligently based on RAM/disk IO available rather than
scheduling each one as a separate write.

Looking at the code for ast_writestream() there doesn't appear to be an
fsync() type call after each write, but someone more familiar with the
internals of Asterisk would be better able to verify that.

-- Looking for (employment|contract) work in the Internet industry, 
preferably working remotely. Building / Supporting the net since 2400 
baud was the hot thing. Ask for a resume! ispbuilder at gmail.com 
-------------- next part -------------- An HTML attachment was 
scrubbed... URL: 
<http://lists.digium.com/pipermail/asterisk-users/attachments/20140124/590804b7/attachment-0001.html> 
------------------------------ Message: 2 Date: Fri, 24 Jan 2014 
16:34:17 +0000 From: A J Stiles <asterisk_list at earthshod.co.uk> To: 
"Asterisk Users Mailing List - Non-Commercial Discussion" 
<asterisk-users at lists.digium.com> Subject: Re: [asterisk-users] IOPS 
required by Asterisk for Call Recording Message-ID: 
<201401241634.17311.asterisk_list at earthshod.co.uk> Content-Type: 
Text/Plain; charset="iso-8859-6" On Friday 24 January 2014, Mike wrote:

> On 14-01-24 11:16 AM, Amit wrote:
>> If I assume that Asterisk will write data on disk every second for
>> each call, I will need disk array to support minimum of 500 IOPS.
>> Where as if Asterisk push data every 2 seconds, I can deal with array
>> supporting 250 IOPS.
>> But if I assume that Asterisk will write data on disk for every RTP
>> packet received, as and when received, I will need disk IO system with
>> approx 25000 IOPS assuming 20 ms RTP packet.
> You're assuming that asterisk will perform an fsync() after each write.
> If asterisk writes without an fsync after each write, then the OS will
> schedule writes intelligently based on RAM/disk IO available rather than
> scheduling each one as a separate write.
>
> Looking at the code for ast_writestream() there doesn't appear to be an
> fsync() type call after each write, but someone more familiar with the
> internals of Asterisk would be better able to verify that.

If you are running on Linux, don't forget that Linux's default behaviour is to
cache all disk writes until the machine is rebooted or the RAM is needed for
something else, and service read operations from the cache.  In fact, it's
entirely possible for a temporary file to be written, read and deleted without
ever going anywhere near a molecule of oxide.

Solaris has the opposite default caching strategy -- it assumes the worst
about filesystem integrity, and write operations block until decaching and
verifying have finished.


-- AJS Answers come *after* questions.






*Thanks & Regards,*
Amit Patkar


On 1/24/2014 8:46 PM, Amit wrote:
> Hi
>
> What are the disk IOPS required for Asterisk call recording?
> I am trying to find out number of disks required in RAID array to 
> record 500 calls.
> Is there any formula to calculate IOPS required by Asterisk call 
> recording? This will help me to find IOPS for different scale.
>
> If I assume that Asterisk will write data on disk every second for 
> each call, I will need disk array to support minimum of 500 IOPS. 
> Where as if Asterisk push data every 2 seconds, I can deal with array 
> supporting 250 IOPS.
> But if I assume that Asterisk will write data on disk for every RTP 
> packet received, as and when received, I will need disk IO system with 
> approx 25000 IOPS assuming 20 ms RTP packet.
>
> Please assist me on this requirement.
>
> *Thanks & Regards,*
> Amit Patkar
>


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20140125/605ff7f9/attachment.html>


More information about the asterisk-users mailing list