Hello,
Is it possible to log SIP sessions using sipcapture module to log files by log format instead of database ?
Thanks!
Hello,
On 6/9/12 8:59 PM, Konstantin M. wrote:
Hello,
Is it possible to log SIP sessions using sipcapture module to log files by log format instead of database ?
what do you mean by log format?
If you just want to store pure pcap files, then you can use tools such as ngrep, wireshark/tshark.
Cheers, Daniel
Hello Daniel,
No I don't want to store in pcap format, I have it already. I would like to have a text logs instead of database.
About log format, I would like to have a functionality like log4cpp, for example:
# Call Logging log4cplus.appender.CALL_LOG_APPENDER=log4cplus::NullAppender log4cplus.appender.CALL_LOG_APPENDER.Directory=logs/call-logs log4cplus.appender.CALL_LOG_APPENDER.ImmediateFlush=true log4cplus.appender.CALL_LOG_APPENDER.layout=log4cplus::PatternLayout log4cplus.appender.CALL_LOG_APPENDER.layout.ConversionPattern=%D{%Y-%m-%d %H:%M:%S:%%q} [%t] %p - %c : %m%n
I'm a very curious why we still have so absolete logging system ? There are too many cute logging frameworks. Why we don't switch to some soft of log4c or log4cpp ?
2012/6/12 Daniel-Constantin Mierla miconda@gmail.com
Hello,
On 6/9/12 8:59 PM, Konstantin M. wrote:
Hello,
Is it possible to log SIP sessions using sipcapture module to log files by log format instead of database ?
what do you mean by log format?
If you just want to store pure pcap files, then you can use tools such as ngrep, wireshark/tshark.
Cheers, Daniel
-- Daniel-Constantin Mierla - http://www.asipto.com http://twitter.com/#!/miconda - http://www.linkedin.com/in/**micondahttp://www.linkedin.com/in/miconda Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 - http://asipto.com/u/katu Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 - http://asipto.com/u/kpw
Hello,
I am a bit confused now. sipcapture role is to store the SIP signaling messages in database for the purpose of later analysis -- you can export pcap from the database later.
What is the obsolete logging system you think about?
If you look to log custom info messages, then see the xlog module:
* http://kamailio.org/docs/modules/3.3.x/modules_k/xlog.html
You can print your own message to syslog (or stderr), in the format you wish.
Cheers, Daniel
On 6/12/12 11:54 AM, Konstantin M. wrote:
Hello Daniel,
No I don't want to store in pcap format, I have it already. I would like to have a text logs instead of database.
About log format, I would like to have a functionality like log4cpp, for example:
# Call Logging log4cplus.appender.CALL_LOG_APPENDER=log4cplus::NullAppender log4cplus.appender.CALL_LOG_APPENDER.Directory=logs/call-logs log4cplus.appender.CALL_LOG_APPENDER.ImmediateFlush=true log4cplus.appender.CALL_LOG_APPENDER.layout=log4cplus::PatternLayout log4cplus.appender.CALL_LOG_APPENDER.layout.ConversionPattern=%D{%Y-%m-%d %H:%M:%S:%%q} [%t] %p - %c : %m%n
I'm a very curious why we still have so absolete logging system ? There are too many cute logging frameworks. Why we don't switch to some soft of log4c or log4cpp ?
2012/6/12 Daniel-Constantin Mierla <miconda@gmail.com mailto:miconda@gmail.com>
Hello, On 6/9/12 8:59 PM, Konstantin M. wrote: Hello, Is it possible to log SIP sessions using sipcapture module to log files by log format instead of database ? what do you mean by log format? If you just want to store pure pcap files, then you can use tools such as ngrep, wireshark/tshark. Cheers, Daniel -- Daniel-Constantin Mierla - http://www.asipto.com http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda> - http://www.linkedin.com/in/miconda Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 - http://asipto.com/u/katu Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 - http://asipto.com/u/kpw
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Hello Daniel,
2012/6/12 Daniel-Constantin Mierla miconda@gmail.com
Hello,
I am a bit confused now. sipcapture role is to store the SIP signaling messages in database for the purpose of later analysis -- you can export pcap from the database later.
Well, I don't have enough experience with sipcapture module but (maybe I'm wrong) I don't think it is a good idea to store so huge data in mysql in high loading environment. Rather that I would suggest to keep them in some flat databases, like mongo, redis, kassandra, etc... Eventually, by looking to the sources, I don't think there is another way except mysql...
What is the obsolete logging system you think about?
If you look to log custom info messages, then see the xlog module:
You can print your own message to syslog (or stderr), in the format you wish.
Yes, I'm using syslog but personally it's a backward way. Nowadays there is a lot of logging frameworks. I think that, unofficial, log4XXXX (where XXXX - one of c, cpp, java, python, etc) already a standard of logging system. When using syslog/logrotate - the only one way to modify a root settings, no way to configure only userland part by configuring a logging strategy inside application like a many software allows.
Cheers, Daniel
On 6/12/12 11:54 AM, Konstantin M. wrote:
Hello Daniel,
No I don't want to store in pcap format, I have it already. I would like to have a text logs instead of database.
About log format, I would like to have a functionality like log4cpp, for example:
# Call Logging log4cplus.appender.CALL_LOG_APPENDER=log4cplus::NullAppender log4cplus.appender.CALL_LOG_APPENDER.Directory=logs/call-logs log4cplus.appender.CALL_LOG_APPENDER.ImmediateFlush=true log4cplus.appender.CALL_LOG_APPENDER.layout=log4cplus::PatternLayout log4cplus.appender.CALL_LOG_APPENDER.layout.ConversionPattern=%D{%Y-%m-%d %H:%M:%S:%%q} [%t] %p - %c : %m%n
I'm a very curious why we still have so absolete logging system ? There are too many cute logging frameworks. Why we don't switch to some soft of log4c or log4cpp ?
2012/6/12 Daniel-Constantin Mierla miconda@gmail.com
Hello,
On 6/9/12 8:59 PM, Konstantin M. wrote:
Hello,
Is it possible to log SIP sessions using sipcapture module to log files by log format instead of database ?
what do you mean by log format?
If you just want to store pure pcap files, then you can use tools such as ngrep, wireshark/tshark.
Cheers, Daniel
-- Daniel-Constantin Mierla - http://www.asipto.com http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 - http://asipto.com/u/katu Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 - http://asipto.com/u/kpw
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing listsr-users@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla - http://www.asipto.comhttp://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 - http://asipto.com/u/katu Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 - http://asipto.com/u/kpw
Hi Konstantin,
what do you mean in "huge data" ? Currently you can easy capture 3K m/s on the middle size server.
anyway, if you want to save the sipcapture data to the plain file, just change DB type.
Wbr, Alexandr
6/12/2012 9:07 PM, Konstantin M. wrote:
Hello Daniel,
2012/6/12 Daniel-Constantin Mierla <miconda@gmail.com mailto:miconda@gmail.com>
Hello, I am a bit confused now. sipcapture role is to store the SIP signaling messages in database for the purpose of later analysis -- you can export pcap from the database later.
Well, I don't have enough experience with sipcapture module but (maybe I'm wrong) I don't think it is a good idea to store so huge data in mysql in high loading environment. Rather that I would suggest to keep them in some flat databases, like mongo, redis, kassandra, etc... Eventually, by looking to the sources, I don't think there is another way except mysql...
What is the obsolete logging system you think about? If you look to log custom info messages, then see the xlog module: * http://kamailio.org/docs/modules/3.3.x/modules_k/xlog.html You can print your own message to syslog (or stderr), in the format you wish.
Yes, I'm using syslog but personally it's a backward way. Nowadays there is a lot of logging frameworks. I think that, unofficial, log4XXXX (where XXXX - one of c, cpp, java, python, etc) already a standard of logging system. When using syslog/logrotate - the only one way to modify a root settings, no way to configure only userland part by configuring a logging strategy inside application like a many software allows.
Cheers, Daniel On 6/12/12 11:54 AM, Konstantin M. wrote:
Hello Daniel, No I don't want to store in pcap format, I have it already. I would like to have a text logs instead of database. About log format, I would like to have a functionality like log4cpp, for example: # Call Logging log4cplus.appender.CALL_LOG_APPENDER=log4cplus::NullAppender log4cplus.appender.CALL_LOG_APPENDER.Directory=logs/call-logs log4cplus.appender.CALL_LOG_APPENDER.ImmediateFlush=true log4cplus.appender.CALL_LOG_APPENDER.layout=log4cplus::PatternLayout log4cplus.appender.CALL_LOG_APPENDER.layout.ConversionPattern=%D{%Y-%m-%d %H:%M:%S:%%q} [%t] %p - %c : %m%n I'm a very curious why we still have so absolete logging system ? There are too many cute logging frameworks. Why we don't switch to some soft of log4c or log4cpp ? 2012/6/12 Daniel-Constantin Mierla <miconda@gmail.com <mailto:miconda@gmail.com>> Hello, On 6/9/12 8:59 PM, Konstantin M. wrote: Hello, Is it possible to log SIP sessions using sipcapture module to log files by log format instead of database ? what do you mean by log format? If you just want to store pure pcap files, then you can use tools such as ngrep, wireshark/tshark. Cheers, Daniel -- Daniel-Constantin Mierla - http://www.asipto.com http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda> - http://www.linkedin.com/in/miconda Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 - http://asipto.com/u/katu Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 - http://asipto.com/u/kpw _______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org <mailto:sr-users@lists.sip-router.org> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla -http://www.asipto.com http://twitter.com/#!/miconda <http://twitter.com/#%21/miconda> -http://www.linkedin.com/in/miconda Kamailio Advanced Training, Seattle, USA, Sep 23-26, 2012 -http://asipto.com/u/katu Kamailio Practical Workshop, Netherlands, Sep 10-12, 2012 -http://asipto.com/u/kpw
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Hello,
On 6/12/12 9:07 PM, Konstantin M. wrote:
Hello Daniel,
2012/6/12 Daniel-Constantin Mierla <miconda@gmail.com mailto:miconda@gmail.com>
Hello, I am a bit confused now. sipcapture role is to store the SIP signaling messages in database for the purpose of later analysis -- you can export pcap from the database later.
Well, I don't have enough experience with sipcapture module but (maybe I'm wrong) I don't think it is a good idea to store so huge data in mysql in high loading environment. Rather that I would suggest to keep them in some flat databases, like mongo, redis, kassandra, etc... Eventually, by looking to the sources, I don't think there is another way except mysql...
all the db modules implementing SRDB1 API can be used (mysql, postgres, unixodbc, flatstore, dbtext, sqlite, I guess casandra). I don't see any really benefits of flat databases over sql databases, in this case where searching on various keys is quite used.
What is the obsolete logging system you think about? If you look to log custom info messages, then see the xlog module: * http://kamailio.org/docs/modules/3.3.x/modules_k/xlog.html You can print your own message to syslog (or stderr), in the format you wish.
Yes, I'm using syslog but personally it's a backward way. Nowadays there is a lot of logging frameworks. I think that, unofficial, log4XXXX (where XXXX - one of c, cpp, java, python, etc) already a standard of logging system. When using syslog/logrotate - the only one way to modify a root settings, no way to configure only userland part by configuring a logging strategy inside application like a many software allows.
Have in mind that this project started more than 10 years ago, some decisions where made long time ago and people were happy with that none contributed alternatives. In other cases, you can see many options for more or less same feature.
I don't recall any other discussion about considering syslog no longer enough. But the beauty of open source is that anyone can contribute and we have a good reputation of being open in accepting the good ones. If it brings better logging system for you, might be the time to come on board and code a framework that will allow to change the logging system as desired.
Syslog will have to stay as an option, as one of the targets is portability, many running kamailio on embedded systems or there are very old deployments still in place, as well as people having monitoring tools based on current logging model. But if you can make it possible to decide which logging system to use, I can bet the contribution will be accepted.
Cheers, Daniel