NSG-Media-Recording

 

 

Mediarec Overview:

Mediarec is a media recording daemon which is being integrated with NSG to start media recording once call is received depending upon the sip session created on per call basis.

 

Start Mediarec Service

To start the service:

  1. Make sure you have configuration is proper.

  2. Execute command: service medairec start

 

Stop Mediarec Service

To stop the service:

  1. Execute command: service mediarec stop.

 

Monitor Mediarec service status

To monitor the service:

  1. Execute command: service mediarec status

The control shows the following information about the service:

 Status              Stopped                       mediarec is in stop state
                        Start                             medairec is in start state          
                        subsystem locked        mediarec pid file is not properly deleted

 

Configuration

Mediarec configuration file is present at /etc/mediarec/mediarec.xml

Below is the configuration parameters w.r.t. mediarec inside mediarec.xml :

Parameters                                          Description

recording-folder                                  Gives the folder name where recorded files need to saved

server                                                  ftp server address where recorded files needs to be uploaded

user                                                     ftp server login id
password                                             ftp server password
base-local-directory                             directory on local system where recorded files are present
base-remote-directory                         directory on ftp server where recorded files need to be                  
                                                             uploaded

ftp-upload-period                                 after how many every milli seconds the recorded files need to 
                                                              be uploaded on ftp server

Below is the example of ftp section in  mediarec configuration file:
<ftp>

<!-- Server address to which ftp recordings needs to be upload -->
<param name="server" value="<xyz.com>"/>

  <!-- Login ID from ftp address if any -->
  <param name="user" value="<user-id>"/>

  <!-- Password for login ID in order to login to FTP server -->
  <param name="password" value="<pwd>"/>

  <!-- Local directory of NSG where recordings are present -->
 <param name="base-local-directory" value="/usr/local/media-nsg//recordings"/>

  <!-- Address of remote directory where recorded files needs to be uplaoded -->
 <param name="base-remote-directory" value="/customer/"/>

  <!-- Time interval in seconds after which recorded files needs to be uploaded -->
 <param name="ftp-upload-period" value="3600"/>

 </ftp>

 

There are some other parameters that needs to be configured in “nsg/conf/sip_profiles/internal.xml” in order to start recording files when calls is received as given below:

Parameter                               Description
media-rec                                if yes then media-recording is enable else not 
rec-direction                            This parameter is to guide medairec daemon in which direction media
                                                recording needs to be performed allowable values are: “rxtx/rx/tx

 

Below is the sample configuration w.r.t. mediarec configuration in internal.xml:
<!-- Record Media/Calls once rtp is gets active. By default media/call recording is off -->
<param name="media-rec" value="yes"/>

<!-- In which direction media/call needs to be recorded: 1) rx  2) tx  or 3) rxtx-->
<param name="rec-direction" value="rxtx"/>

 

Return to Documentation Home I Return to Sangoma Support