Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ngrep Call trace from User 1002 to 1003
- T 2017/12/07 21:04:15.040062 127.0.0.1:8448 -> 127.0.0.1:51169 [AP]
- 247:{"event":"CGR_AUTH_REQUEST",
- .."tr_index":"36746",
- .."tr_label":"1617032884",
- .."cgr_reqtype":"*postpaid",
- .."cgr_tenant":"cgrates.org",
- .."cgr_account":"1002",
- .."cgr_destination":"1003",
- .."cgr_setuptime":"1512680655",
- .."cgr_computelcr":"true"},
- ##
- T 2017/12/07 21:04:15.092227 127.0.0.1:51169 -> 127.0.0.1:8448 [AP]
- 188:{"Event":"CGR_AUTH_REPLY","TransactionIndex":36746,"TransactionLabel":1617032884,"MaxSessionTime":-1,"Suppliers":"suppl2,suppl1","ResourceAllocated":true,"AllocationMessage":"","Error":""},
- ##
- T 2017/12/07 21:04:17.494932 127.0.0.1:8448 -> 127.0.0.1:51169 [AP]
- 285:{"event":"CGR_CALL_START",
- .."callid":"XEP~wBI5Ro",
- .."from_tag":"2WshLT~N~",
- .."h_entry":"2827",
- .."h_id":"5183",
- .."cgr_reqtype":"*postpaid",
- .."cgr_tenant":"cgrates.org",
- .."cgr_account":"1002",
- .."cgr_destination":"1003",
- .."cgr_answertime":"1512680657",
- .."cgr_supplier":"suppl2"},
- ##
- ##
- T 2017/12/07 21:04:27.319707 127.0.0.1:8448 -> 127.0.0.1:51169 [AP]
- 299:{"event":"CGR_CALL_END",
- .."callid":"XEP~wBI5Ro",
- .."from_tag":"2WshLT~N~",
- .."cgr_reqtype":"*postpaid",
- .."cgr_tenant":"cgrates.org",
- .."cgr_account":"1002",
- .."cgr_destination":"1003",
- .."cgr_answertime":"1512680657",
- .."cgr_duration":"10",
- .."cgr_supplier":"suppl2",
- .."cgr_disconnectcause":"0"},
- #
- Resulting CDRs in mongo stordb
- db.cdrs.find({"originid":"XEP~wBI5Ro;2WshLT~N~"})
- /* 1 */
- {
- "_id" : ObjectId("5a29acdb6ca97563a9aba95d"),
- "cgrid" : "023f5fa987ebf729c22aef33dabf51de5ba2a5ef",
- "runid" : "*raw",
- "orderid" : NumberLong(1512679888381637369),
- "originhost" : "127.0.0.1",
- "source" : "KAMAILIO_CGR_CALL_END",
- "originid" : "XEP~wBI5Ro;2WshLT~N~",
- "tor" : "*voice",
- "requesttype" : "*postpaid",
- "direction" : "*out",
- "tenant" : "cgrates.org",
- "category" : "call",
- "account" : "1002",
- "subject" : "1002",
- "destination" : "1003",
- "setuptime" : ISODate("2017-12-07T21:04:17.000Z"),
- "pdd" : NumberLong(0),
- "answertime" : ISODate("2017-12-07T21:04:17.000Z"),
- "usage" : NumberLong(10000000000),
- "supplier" : "suppl2",
- "disconnectcause" : "0",
- "extrafields" : {},
- "costsource" : "",
- "cost" : -1.0,
- "costdetails" : null,
- "accountsummary" : null,
- "extrainfo" : "",
- "rated" : false,
- "partial" : false
- }
- /* 2 */
- {
- "_id" : ObjectId("5a29acdb6ca97563a9aba962"),
- "cgrid" : "023f5fa987ebf729c22aef33dabf51de5ba2a5ef",
- "runid" : "*default",
- "orderid" : NumberLong(1512679888381637369),
- "originhost" : "127.0.0.1",
- "source" : "KAMAILIO_CGR_CALL_END",
- "originid" : "XEP~wBI5Ro;2WshLT~N~",
- "tor" : "*voice",
- "requesttype" : "*postpaid",
- "direction" : "*out",
- "tenant" : "cgrates.org",
- "category" : "call",
- "account" : "1002",
- "subject" : "1002",
- "destination" : "1003",
- "setuptime" : ISODate("2017-12-07T21:04:17.000Z"),
- "pdd" : NumberLong(0),
- "answertime" : ISODate("2017-12-07T21:04:17.000Z"),
- "usage" : NumberLong(10000000000),
- "supplier" : "suppl2",
- "disconnectcause" : "0",
- "extrafields" : {},
- "costsource" : "CDRS",
- "cost" : 0.3,
- "costdetails" : {
- "direction" : "*out",
- "category" : "call",
- "tenant" : "cgrates.org",
- "subject" : "1002",
- "account" : "1002",
- "destination" : "1003",
- "tor" : "*voice",
- "cost" : 0.3,
- "timespans" : [
- {
- "timestart" : ISODate("2017-12-07T21:04:17.000Z"),
- "timeend" : ISODate("2017-12-07T21:05:17.000Z"),
- "cost" : 0.3,
- "rateinterval" : {
- "timing" : {
- "years" : [],
- "months" : [],
- "monthdays" : [],
- "weekdays" : [
- 1,
- 2,
- 3,
- 4,
- 5
- ],
- "starttime" : "19:00:00",
- "endtime" : ""
- },
- "rating" : {
- "connectfee" : 0.2,
- "roundingmethod" : "*up",
- "roundingdecimals" : 4,
- "maxcost" : 0.0,
- "maxcoststrategy" : "",
- "rates" : [
- {
- "groupintervalstart" : NumberLong(0),
- "value" : 0.1,
- "rateincrement" : NumberLong(60000000000),
- "rateunit" : NumberLong(60000000000)
- },
- {
- "groupintervalstart" : NumberLong(60000000000),
- "value" : 0.05,
- "rateincrement" : NumberLong(1000000000),
- "rateunit" : NumberLong(60000000000)
- }
- ]
- },
- "weight" : 10.0
- },
- "durationindex" : NumberLong(60000000000),
- "increments" : [
- {
- "duration" : NumberLong(0),
- "cost" : 0.2,
- "balanceinfo" : {
- "unit" : null,
- "monetary" : {
- "uuid" : "8bd9649d-1026-4305-a976-98e64c1c0552",
- "id" : "",
- "value" : 8.9,
- "rateinterval" : null
- },
- "accountid" : "cgrates.org:1002"
- },
- "compressfactor" : 1
- },
- {
- "duration" : NumberLong(60000000000),
- "cost" : 0.1,
- "balanceinfo" : {
- "unit" : null,
- "monetary" : {
- "uuid" : "8bd9649d-1026-4305-a976-98e64c1c0552",
- "id" : "",
- "value" : 8.8,
- "rateinterval" : null
- },
- "accountid" : "cgrates.org:1002"
- },
- "compressfactor" : 1
- }
- ],
- "roundincrement" : null,
- "matchedsubject" : "*out:cgrates.org:call:*any",
- "matchedprefix" : "10",
- "matcheddestid" : "DST_FS",
- "ratingplanid" : "RP_RETAIL1",
- "compressfactor" : 1
- }
- ],
- "ratedusage" : 60.0,
- "accountsummary" : {
- "tenant" : "cgrates.org",
- "id" : "1002",
- "balancesummaries" : [
- {
- "uuid" : "8bd9649d-1026-4305-a976-98e64c1c0552",
- "id" : "8bd9649d-1026-4305-a976-98e64c1c0552",
- "type" : "*monetary",
- "value" : 8.8,
- "disabled" : false
- }
- ],
- "allownegative" : false,
- "disabled" : false
- }
- },
- "accountsummary" : null,
- "extrainfo" : "",
- "rated" : false,
- "partial" : false
- }
Add Comment
Please, Sign In to add comment