cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2452
Views
20
Helpful
15
Replies
Highlighted

CMS 2.x configure for write and export CDR on CDR Receiver

Dear all,

I have configured the CMS 2.0.7 (ex Acano) and everything works, I now have to configure the CDR to control calls statistics. I followed the CDR and API guides to create the CDR Receiver ... like this http://10.10.10.10/CMSCDR. We have tried via GUI and via API....

API 2.0 - CDR 2.0

I don't have Acano Manager,it is not necessary according to the guide.
The CMS does not report connection errors.

I have not found what are the characteristics of "CDR Receiver", IIS, WEBDAV, Apache, SFTP, FTP, Share...etc.

If the CMS has to write the files, how it does?

Any help is appreciated.

Thanks a lot

Massimo 

15 REPLIES 15
Beginner

Hi Massimo,

Hi Massimo,

You don't need Acano Manager but, you do need something that can receive the CDR data and parse it. Essentially you need a web service that will accept POST requests from the CMS and then handle the data in a useful way.

What is http://10.10.10.10 in your post?

Acano/CMS do not store the CDR data in a file that you can access, so the CDR receiver is required.

If you're at all familiar with python, I wrote a small script which run's as a listener that you can configure as the CDR receiver, it can be found here: https://github.com/jasonneurohr/acano_cdr_receiver

Jason

Beginner

Hi Jason,

Hi Jason,

Please explain how to use your cdr receiver script.

Thank you

Beginner

Assuming you have python

Assuming you have python installed and working, and you have the python file in the directory C:\CDRs.

python C:\CDRs\cdr_receiver.py -f C:\CDRs\cdr_log.txt

This will start the listener on TCP port 9999 (so make sure this is open on any host firewall or firewall between the CMS and the server running the script). CDRs will be written to the cdr_log.txt file in the same directory (designated by the -f <file_path>)

Then in CMS either through web admin or the API, add a CDR receiver in the form of http://<ip_address_of_receiver_host>:9999/<CMS Name>

Jason

Beginner

Hi Jason

Hi Jason

I can't run acano_cdr_receiver.py because it is <!DOCTYPE html>.

Please suggest for edit or setting script.

Thank you so much

Beginner

It sounds like you haven't

It sounds like you haven't downloaded it properly. Simplest method is to go to the repo page here: https://github.com/jasonneurohr/acano_cdr_receiver

On the right side, there is a green button called Clone or download, Click that.

Click Download ZIP

Once downloaded, extract the zip file and then try what I described above again.

Jason

Beginner

Hi Jason,

Hi Jason,

It's work. I'm beginner for python. Thank you so much.

HI Jason,

HI Jason,

Thanks for the script, may i know what is <CMS Name> in the above example? where do we need to pass server address?

Beginner

Hi Suresh,

Hi Suresh,

In this version of the script <CMS Name> is not used currently. It is for future use if the script is extended. The intention is for <CMS Name> to be the hostname of the server to uniquely identify it via the POST URL request itself.

Jason

Beginner

Re: Assuming you have python

Hi Jason,

 

I trying enable the CRD with the step of your post, but I couldn't do it. 

 

Where do I need to apply this command?

python C:\CDRs\cdr_receiver.py -f C:\CDRs\cdr_log.txt

 

I have installed the python 3.7.1

Do I need to do something with file acano_cdr_receiver.py and cdr_log.txt.

I just put both of them in the path c:CDRs.

 

Thanks,

 

 

Contributor

Thanks Jason. 

Thanks Jason. 

This is most useful. 

Quick question though. I simply want to write out the inputs (rather than convert to JSON) as I've written an XML parser. I assume the input is contained in post_body and I can call write_to_disk with it immediately after this line:

post_body = self.rfile.read(content_len) 

Please let me know

Thanks

Craig

Beginner

Thanks for the script.

Thanks for the script.

After executing, I am always getting:

Traceback (most recent call last):
File "C:\CMS_CDRs\cms_cdr_receiver.py", line 354, in <module>
main(sys.argv[1:])
File "C:\CMS_CDRs\cms_cdr_receiver.py", line 351, in main
httpd.serve_forever()
File "C:\Python27\lib\SocketServer.py", line 231, in serve_forever
poll_interval)
File "C:\Python27\lib\SocketServer.py", line 150, in _eintr_retry
return func(*args)

Can you help please?

Regards,

Petar

Beginner

Hi Petar,

Hi Petar,

Please try using Python version 3.5.

Thanks

Jason

Beginner

Re: Hi Petar,

Hi Jason,

 

after executing, I got the message:

 

Traceback (most recent call last):
File "C:\cmscdr\acano_cdr_receiver.py", line 2, in <module>
import xmltodict
ImportError: No module named 'xmltodict'

 

please help, thanks.

Beginner

Re: Hi Petar,

sudo apt-get install python3-pip

sudo pip3 install wechatpy

python3 acano_cdr_receiver.py -f cms.txt

and it's work for me!

Everyone's tags (1)
CreatePlease to create content
Content for Community-Ad
July's Community Spotlight Awards