The account balance is not being deducted from any of the accounts


#1

Hello,

I have setup Yeti on a new server and the calls are running fine without any issue but when i checked the balance of the customers it is not being deducted. any suggestions ?


#2

pgqd is not running or cdr_billing is not running.


#3

how do i check that ? I am sorry i am new to postgres. i have worked with mysql but not postgresql


#4

ps aux | grep pgq
ps aux | grep cdr_billing


#5

Below is what i see, should i open any ports on the firewall ?

image


#6

I was right - pgqd is not running. See https://yeti-switch.org/docs/en/installation/cdr-database.html#pgqd-ticker


#7

is this correct ? I also enabled pgqd at startup and rebooted.

image


#8

yes.


#9

Ok, but still the balance is as it is.


#10

show tail /var/log/yeti-cdr-billing.log


#11


#12

Billing queue contains 1069038 events, you should wait until they will be processed.


#13

I just checked the log again and still there are 1069038 events, Should i wait or something is stuck ?

image


#14

Now i get blank. The Balance is still not decreasing, I have set reverse billing as false in Destination rates.

image


#15

@dmitry.s , any suggestions ?


#16

It depends on process cdr_billing. If cdr_billing is running - wait.


#17

I checked the logs, it is blank now, but the balance is still not decreasing.
image

does this has something to do with the balance ?


#18

I am really confused as i have shifted a client on yeti and since yesterday i dont have a track of their usage.


#19

Looks like you have no enough RAM and cdr_billing process crashed(killed by OOM killer) when tried to load batch with 1M events. In normal situation pgqd create batches with 10-100 events.
There are few solutions:

  • drop this huge batch. Then your previous calls will be not billed. You can create report and calculate balance by CDRs.
  • process events manualy

#20

Here is the config of the server. What can i do to bill the previous once, if that does not work, how can i drop the batch and then have the cdr billing done automatically ?