Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
--- L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. https://www.avast.com/antivirus
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
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,
Actually 9 031 181.
Regards,
Igor.
De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel-Constantin Mierla Envoyé : mardi 14 février 2017 10:57 À : Kamailio (SER) - Users Mailing List sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
_____
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
_______________________________________________ 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
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel,
Actually 9 031 181.
Regards,
Igor.
*De :*sr-users [mailto:sr-users-bounces@lists.sip-router.org] *De la part de* Daniel-Constantin Mierla *Envoyé :* mardi 14 février 2017 10:57 *À :* Kamailio (SER) - Users Mailing List sr-users@lists.sip-router.org *Objet :* Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello, Two times in the last week, Kamailio reports MySQL errors like these: /usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003) /usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query /usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue. Anyone has already had this issue and had solved it? Regards, Igor. ------------------------------------------------------------------------ Avast logo <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> _______________________________________________ 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 www.twitter.com/miconda http://www.twitter.com/miconda -- www.linkedin.com/in/miconda http://www.linkedin.com/in/miconda Kamailio Advanced Training - Mar 6-8 (Europe) and Mar 20-22 (USA) - www.asipto.com http://www.asipto.com Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com http://www.kamailioworld.com
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
Hello,
There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries.
The structure is: id as primary and callid is an index.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mardi 14 février 2017 12:06 À : Igor Potjevlesch igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel,
Actually 9 031 181.
Regards,
Igor.
De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel-Constantin Mierla Envoyé : mardi 14 février 2017 10:57 À : Kamailio (SER) - Users Mailing List mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
_____
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
_______________________________________________ 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
Hello,
it doesn't have to be from kamailio.cfg, but any query from external tools, like cron jobs, billing applications, etc ...
Can you measure how long it takes to do a query from the command line? Just try to select the records by a call-id.
Also, there are some core parameters that will print log messages in case of slow queries/actions, see the core cookbook.
Moreover, the db_mysql module has some parameters to tune the timeouts.
Cheers, Daniel
On 14/02/2017 14:22, Igor Potjevlesch wrote:
Hello,
There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries.
The structure is: id as primary and callid is an index.
Regards,
Igor.
*De :*Daniel-Constantin Mierla [mailto:miconda@gmail.com] *Envoyé :* mardi 14 février 2017 12:06 *À :* Igor Potjevlesch igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org *Objet :* Re: [SR-Users] Lost of connection with MySQL?
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel, Actually 9 031 181. Regards, Igor. *De :*sr-users [mailto:sr-users-bounces@lists.sip-router.org] *De la part de* Daniel-Constantin Mierla *Envoyé :* mardi 14 février 2017 10:57 *À :* Kamailio (SER) - Users Mailing List <sr-users@lists.sip-router.org> <mailto:sr-users@lists.sip-router.org> *Objet :* Re: [SR-Users] Lost of connection with MySQL? Hello, do you have a lot of records inside the acc table? Cheers, Daniel On 14/02/2017 09:54, Igor Potjevlesch wrote: Hello, Two times in the last week, Kamailio reports MySQL errors like these: /usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003) /usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query /usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue. Anyone has already had this issue and had solved it? Regards, Igor. ------------------------------------------------------------------------ Avast logo <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> _______________________________________________ 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 www.twitter.com/miconda <http://www.twitter.com/miconda> -- www.linkedin.com/in/miconda <http://www.linkedin.com/in/miconda> Kamailio Advanced Training - Mar 6-8 (Europe) and Mar 20-22 (USA) - www.asipto.com <http://www.asipto.com> Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com <http://www.kamailioworld.com> ------------------------------------------------------------------------ Avast logo <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
-- Daniel-Constantin Mierla www.twitter.com/miconda http://www.twitter.com/miconda -- www.linkedin.com/in/miconda http://www.linkedin.com/in/miconda Kamailio Advanced Training - Mar 6-8 (Europe) and Mar 20-22 (USA) - www.asipto.com http://www.asipto.com Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com http://www.kamailioworld.com
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
Hello,
Indeed, I think there are some DB access external of kamailio.cfg.
If accounting process is implied in the freeze of SIP handling, and if aysnc accounting can solve this, it's my priority. Even if accounting fails due to the timeout you reminded.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mercredi 15 février 2017 08:57 À : Igor Potjevlesch igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it doesn't have to be from kamailio.cfg, but any query from external tools, like cron jobs, billing applications, etc ...
Can you measure how long it takes to do a query from the command line? Just try to select the records by a call-id.
Also, there are some core parameters that will print log messages in case of slow queries/actions, see the core cookbook.
Moreover, the db_mysql module has some parameters to tune the timeouts.
Cheers, Daniel
On 14/02/2017 14:22, Igor Potjevlesch wrote:
Hello,
There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries.
The structure is: id as primary and callid is an index.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mardi 14 février 2017 12:06 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel,
Actually 9 031 181.
Regards,
Igor.
De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel-Constantin Mierla Envoyé : mardi 14 février 2017 10:57 À : Kamailio (SER) - Users Mailing List mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
_____
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
_______________________________________________ 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
Hello,
as I said, if the execution if the query takes too long, then async mode doesn't really solve the problem completely -- the record will not be stored in db because the client library will cancel the query due to execution timeout. However, the async mode ensures that the sip traffic is routed, so at least you solve the sip signaling problems.
A complete solution is async mode for accounting together and fixing the database to do the queries under the timeout value you set to db_mysql module.
Cheers, Daniel
On 16/02/2017 12:16, Igor Potjevlesch wrote:
Hello,
Indeed, I think there are some DB access external of kamailio.cfg.
If accounting process is implied in the freeze of SIP handling, and if aysnc accounting can solve this, it's my priority. Even if accounting fails due to the timeout you reminded.
Regards,
Igor.
*De :*Daniel-Constantin Mierla [mailto:miconda@gmail.com] *Envoyé :* mercredi 15 février 2017 08:57 *À :* Igor Potjevlesch igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org *Objet :* Re: [SR-Users] Lost of connection with MySQL?
Hello,
it doesn't have to be from kamailio.cfg, but any query from external tools, like cron jobs, billing applications, etc ...
Can you measure how long it takes to do a query from the command line? Just try to select the records by a call-id.
Also, there are some core parameters that will print log messages in case of slow queries/actions, see the core cookbook.
Moreover, the db_mysql module has some parameters to tune the timeouts.
Cheers, Daniel
On 14/02/2017 14:22, Igor Potjevlesch wrote:
Hello, There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries. The structure is: id as primary and callid is an index. Regards, Igor. *De :*Daniel-Constantin Mierla [mailto:miconda@gmail.com] *Envoyé :* mardi 14 février 2017 12:06 *À :* Igor Potjevlesch <igor.potjevlesch@gmail.com> <mailto:igor.potjevlesch@gmail.com>; 'Kamailio (SER) - Users Mailing List' <sr-users@lists.sip-router.org> <mailto:sr-users@lists.sip-router.org> *Objet :* Re: [SR-Users] Lost of connection with MySQL? Hello, it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes? Have you created other constraints (e.g., unique keys) over the table? Cheers, Daniel On 14/02/2017 11:51, Igor Potjevlesch wrote: Hello Daniel, Actually 9 031 181. Regards, Igor. *De :*sr-users [mailto:sr-users-bounces@lists.sip-router.org] *De la part de* Daniel-Constantin Mierla *Envoyé :* mardi 14 février 2017 10:57 *À :* Kamailio (SER) - Users Mailing List <sr-users@lists.sip-router.org> <mailto:sr-users@lists.sip-router.org> *Objet :* Re: [SR-Users] Lost of connection with MySQL? Hello, do you have a lot of records inside the acc table? Cheers, Daniel On 14/02/2017 09:54, Igor Potjevlesch wrote: Hello, Two times in the last week, Kamailio reports MySQL errors like these: /usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003) /usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query /usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue. Anyone has already had this issue and had solved it? Regards, Igor. ------------------------------------------------------------------------ Avast logo <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> _______________________________________________ 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 www.twitter.com/miconda <http://www.twitter.com/miconda> -- www.linkedin.com/in/miconda <http://www.linkedin.com/in/miconda> Kamailio Advanced Training - Mar 6-8 (Europe) and Mar 20-22 (USA) - www.asipto.com <http://www.asipto.com> Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com <http://www.kamailioworld.com> ------------------------------------------------------------------------ Avast logo <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> -- Daniel-Constantin Mierla www.twitter.com/miconda <http://www.twitter.com/miconda> -- www.linkedin.com/in/miconda <http://www.linkedin.com/in/miconda> Kamailio Advanced Training - Mar 6-8 (Europe) and Mar 20-22 (USA) - www.asipto.com <http://www.asipto.com> Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com <http://www.kamailioworld.com> ------------------------------------------------------------------------ Avast logo <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com <https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient>
-- Daniel-Constantin Mierla www.twitter.com/miconda http://www.twitter.com/miconda -- www.linkedin.com/in/miconda http://www.linkedin.com/in/miconda Kamailio Advanced Training - Mar 6-8 (Europe) and Mar 20-22 (USA) - www.asipto.com http://www.asipto.com Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com http://www.kamailioworld.com
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
Hello,
Thank you Daniel, and Daniel :) for your advises and analyse of this problem.
I will also check if the DB replies before the timeout in db_mysql module.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : vendredi 17 février 2017 08:10 À : Igor Potjevlesch igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
as I said, if the execution if the query takes too long, then async mode doesn't really solve the problem completely -- the record will not be stored in db because the client library will cancel the query due to execution timeout. However, the async mode ensures that the sip traffic is routed, so at least you solve the sip signaling problems.
A complete solution is async mode for accounting together and fixing the database to do the queries under the timeout value you set to db_mysql module.
Cheers, Daniel
On 16/02/2017 12:16, Igor Potjevlesch wrote:
Hello,
Indeed, I think there are some DB access external of kamailio.cfg.
If accounting process is implied in the freeze of SIP handling, and if aysnc accounting can solve this, it's my priority. Even if accounting fails due to the timeout you reminded.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mercredi 15 février 2017 08:57 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it doesn't have to be from kamailio.cfg, but any query from external tools, like cron jobs, billing applications, etc ...
Can you measure how long it takes to do a query from the command line? Just try to select the records by a call-id.
Also, there are some core parameters that will print log messages in case of slow queries/actions, see the core cookbook.
Moreover, the db_mysql module has some parameters to tune the timeouts.
Cheers, Daniel
On 14/02/2017 14:22, Igor Potjevlesch wrote:
Hello,
There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries.
The structure is: id as primary and callid is an index.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mardi 14 février 2017 12:06 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel,
Actually 9 031 181.
Regards,
Igor.
De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel-Constantin Mierla Envoyé : mardi 14 février 2017 10:57 À : Kamailio (SER) - Users Mailing List mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
_____
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
_______________________________________________ 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
Hello,
Same issue this morning.
Feb 24 08:42:51 /usr/local/sbin/kamailio[25368]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:51 /usr/local/sbin/kamailio[25368]: ERROR: db_mysql [km_dbase.c:149]: db_mysql_async_exec_task(): failed to execute query [insert into acc_2017_2 (method,from_tag,to_tag,callid,sip_code,sip_reason,time,src_user,username,src] on async worker
Feb 24 08:42:51 /usr/local/sbin/kamailio[25299]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25259]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25275]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25297]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25287]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25290]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
So, even the async process has failed.
Could it be an issue on MySQL himself?
Regards,
Igor.
De : Igor Potjevlesch [mailto:igor.potjevlesch@gmail.com] Envoyé : vendredi 17 février 2017 17:25 À : miconda@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org Objet : RE: [SR-Users] Lost of connection with MySQL?
Hello,
Thank you Daniel, and Daniel :) for your advises and analyse of this problem.
I will also check if the DB replies before the timeout in db_mysql module.
Regards,
Igor.
De : Daniel-Constantin Mierla [ mailto:miconda@gmail.com mailto:miconda@gmail.com] Envoyé : vendredi 17 février 2017 08:10 À : Igor Potjevlesch < mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com>; 'Kamailio (SER) - Users Mailing List' < mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org> Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
as I said, if the execution if the query takes too long, then async mode doesn't really solve the problem completely -- the record will not be stored in db because the client library will cancel the query due to execution timeout. However, the async mode ensures that the sip traffic is routed, so at least you solve the sip signaling problems.
A complete solution is async mode for accounting together and fixing the database to do the queries under the timeout value you set to db_mysql module.
Cheers, Daniel
On 16/02/2017 12:16, Igor Potjevlesch wrote:
Hello,
Indeed, I think there are some DB access external of kamailio.cfg.
If accounting process is implied in the freeze of SIP handling, and if aysnc accounting can solve this, it's my priority. Even if accounting fails due to the timeout you reminded.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mercredi 15 février 2017 08:57 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it doesn't have to be from kamailio.cfg, but any query from external tools, like cron jobs, billing applications, etc ...
Can you measure how long it takes to do a query from the command line? Just try to select the records by a call-id.
Also, there are some core parameters that will print log messages in case of slow queries/actions, see the core cookbook.
Moreover, the db_mysql module has some parameters to tune the timeouts.
Cheers, Daniel
On 14/02/2017 14:22, Igor Potjevlesch wrote:
Hello,
There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries.
The structure is: id as primary and callid is an index.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mardi 14 février 2017 12:06 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel,
Actually 9 031 181.
Regards,
Igor.
De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel-Constantin Mierla Envoyé : mardi 14 février 2017 10:57 À : Kamailio (SER) - Users Mailing List mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
_____
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
_______________________________________________ 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
Hello,
Again this morning. It looks to be during the beginning of the peak. I don't have any idea where to search the issue. Any ideas?
Regards,
Igor.
De : Igor Potjevlesch [mailto:igor.potjevlesch@gmail.com] Envoyé : vendredi 24 février 2017 10:14 À : miconda@gmail.com; 'Kamailio (SER) - Users Mailing List' sr-users@lists.sip-router.org Objet : RE: [SR-Users] Lost of connection with MySQL?
Hello,
Same issue this morning.
Feb 24 08:42:51 /usr/local/sbin/kamailio[25368]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:51 /usr/local/sbin/kamailio[25368]: ERROR: db_mysql [km_dbase.c:149]: db_mysql_async_exec_task(): failed to execute query [insert into acc_2017_2 (method,from_tag,to_tag,callid,sip_code,sip_reason,time,src_user,username,src] on async worker
Feb 24 08:42:51 /usr/local/sbin/kamailio[25299]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25259]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25275]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25297]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25287]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
Feb 24 08:42:52 /usr/local/sbin/kamailio[25290]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
So, even the async process has failed.
Could it be an issue on MySQL himself?
Regards,
Igor.
De : Igor Potjevlesch [ mailto:igor.potjevlesch@gmail.com mailto:igor.potjevlesch@gmail.com] Envoyé : vendredi 17 février 2017 17:25 À : mailto:miconda@gmail.com miconda@gmail.com; 'Kamailio (SER) - Users Mailing List' < mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org> Objet : RE: [SR-Users] Lost of connection with MySQL?
Hello,
Thank you Daniel, and Daniel :) for your advises and analyse of this problem.
I will also check if the DB replies before the timeout in db_mysql module.
Regards,
Igor.
De : Daniel-Constantin Mierla [ mailto:miconda@gmail.com mailto:miconda@gmail.com] Envoyé : vendredi 17 février 2017 08:10 À : Igor Potjevlesch < mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com>; 'Kamailio (SER) - Users Mailing List' < mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org> Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
as I said, if the execution if the query takes too long, then async mode doesn't really solve the problem completely -- the record will not be stored in db because the client library will cancel the query due to execution timeout. However, the async mode ensures that the sip traffic is routed, so at least you solve the sip signaling problems.
A complete solution is async mode for accounting together and fixing the database to do the queries under the timeout value you set to db_mysql module.
Cheers, Daniel
On 16/02/2017 12:16, Igor Potjevlesch wrote:
Hello,
Indeed, I think there are some DB access external of kamailio.cfg.
If accounting process is implied in the freeze of SIP handling, and if aysnc accounting can solve this, it's my priority. Even if accounting fails due to the timeout you reminded.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mercredi 15 février 2017 08:57 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it doesn't have to be from kamailio.cfg, but any query from external tools, like cron jobs, billing applications, etc ...
Can you measure how long it takes to do a query from the command line? Just try to select the records by a call-id.
Also, there are some core parameters that will print log messages in case of slow queries/actions, see the core cookbook.
Moreover, the db_mysql module has some parameters to tune the timeouts.
Cheers, Daniel
On 14/02/2017 14:22, Igor Potjevlesch wrote:
Hello,
There is only queries on a replication server, so not the one reported in the errors, to make some fraud detections. But, directly from Kamailio config file, there's no queries.
The structure is: id as primary and callid is an index.
Regards,
Igor.
De : Daniel-Constantin Mierla [mailto:miconda@gmail.com] Envoyé : mardi 14 février 2017 12:06 À : Igor Potjevlesch mailto:igor.potjevlesch@gmail.com igor.potjevlesch@gmail.com; 'Kamailio (SER) - Users Mailing List' mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
it is a lot if you have over 9 million records. Do you run other periodical queries over acc, like generating full cdrs every N minutes?
Have you created other constraints (e.g., unique keys) over the table?
Cheers, Daniel
On 14/02/2017 11:51, Igor Potjevlesch wrote:
Hello Daniel,
Actually 9 031 181.
Regards,
Igor.
De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel-Constantin Mierla Envoyé : mardi 14 février 2017 10:57 À : Kamailio (SER) - Users Mailing List mailto:sr-users@lists.sip-router.org sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
Hello,
do you have a lot of records inside the acc table?
Cheers, Daniel
On 14/02/2017 09:54, Igor Potjevlesch wrote:
Hello,
Two times in the last week, Kamailio reports MySQL errors like these:
/usr/local/sbin/kamailio[19225]: ERROR: db_mysql [km_dbase.c:126]: db_mysql_submit_query(): driver error on query: Can't connect to MySQL server on '192.168.2.6' (4) (2003)
/usr/local/sbin/kamailio[19225]: ERROR: <core> [db_query.c:235]: db_do_insert_cmd(): error while submitting query
/usr/local/sbin/kamailio[19225]: ERROR: acc [acc.c:504]: acc_db_request(): failed to insert into database
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
Regards,
Igor.
_____
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. www.avast.com https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
_______________________________________________ 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
On Wed, Mar 01, 2017 at 09:55:52AM +0100, Igor Potjevlesch wrote:
Again this morning. It looks to be during the beginning of the peak. I don't have any idea where to search the issue. Any ideas?
The root cause has always been the mysqlserver in my case. I've seen the following jobs causing locks on tables: -generating CDRs from acc (custom cron job) -mysqldumps
Kamailio complaining is just a symptom (unless kamailio itself is causing locking issues).
I'd start by generating dumps of "show full processlist" every 15s to see what is going on.
Hello Daniel,
Thank you for your feedback. I will look deeper into the MySQL server.
Regards,
Igor.
-----Message d'origine----- De : sr-users [mailto:sr-users-bounces@lists.sip-router.org] De la part de Daniel Tryba Envoyé : mercredi 1 mars 2017 12:18 À : Kamailio (SER) - Users Mailing List sr-users@lists.sip-router.org Objet : Re: [SR-Users] Lost of connection with MySQL?
On Wed, Mar 01, 2017 at 09:55:52AM +0100, Igor Potjevlesch wrote:
Again this morning. It looks to be during the beginning of the peak. I don't have any idea where to search the issue. Any ideas?
The root cause has always been the mysqlserver in my case. I've seen the following jobs causing locks on tables: -generating CDRs from acc (custom cron job) -mysqldumps
Kamailio complaining is just a symptom (unless kamailio itself is causing locking issues).
I'd start by generating dumps of "show full processlist" every 15s to see what is going on.
_______________________________________________ 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
--- L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast. https://www.avast.com/antivirus
On Tue, Feb 14, 2017 at 09:54:42AM +0100, Igor Potjevlesch wrote: [mysql query fails]
These errors are repeated many times and cause Kamailio to hang and don't reply to SIP requests. A reboot of Kamailio solves the issue.
Anyone has already had this issue and had solved it?
This is "normal" behavior. The source of your problem is mysql though. You might have locks or other performance killer at that moment running mysql. My experience is that it wasn't necessary to restart kamailio, once the mysqldb started responding again, calls would start to flow again. In some instances kamailio crashed on these locked queries.
For acc there is a workaround is either to use async on mysql level: http://blog.miconda.eu/2014/10/kamailio-42-tips-8-asynchronous.html
db_insert_mode 1 doesn't work with InnoDB backends. If you use InnoDB set the mode to 2 and enable atleast 1 async worker (async_workers=1) See: http://www.kamailio.org/docs/modules/4.3.x/modules/acc.html#acc.p.db_insert_...
Hi,
Looks to be a good idea. I use MySQL and MyISAM, so I understand that async is supported.
How should I dimension the number of async_workers?
Regards,
On Tue, Feb 14, 2017 at 02:27:59PM +0100, Igor Potjevlesch wrote:
Looks to be a good idea. I use MySQL and MyISAM, so I understand that async is supported.
Async (db_insert_mode=2) is supported with any (acc)backend. With myisam you can use delayed inserts (db_insert_mode=1). But without even looking at the kamailio implementation I'd guess that 2 is the better choice in the hope that the sql operation is entirely done in an other thread, with 1 there might be the chance that setting up/reusing connections might block (since insert delayed is a feature on the mysql server side that just returns an OK before any writes to disk).
How should I dimension the number of async_workers?
I set it to 2, but for acc and a few async sql_ops calls that should be overkill. I have no metrics to make a better assumption on the number of worker threads.
On 14/02/2017 14:36, Daniel Tryba wrote:
On Tue, Feb 14, 2017 at 02:27:59PM +0100, Igor Potjevlesch wrote:
Looks to be a good idea. I use MySQL and MyISAM, so I understand that async is supported.
Async (db_insert_mode=2) is supported with any (acc)backend.
To be accurate, not all backends support it, because they need to export a function for async operations. I did it for mysql.
Cheers, Daniel
With myisam you can use delayed inserts (db_insert_mode=1). But without even looking at the kamailio implementation I'd guess that 2 is the better choice in the hope that the sql operation is entirely done in an other thread, with 1 there might be the chance that setting up/reusing connections might block (since insert delayed is a feature on the mysql server side that just returns an OK before any writes to disk).
How should I dimension the number of async_workers?
I set it to 2, but for acc and a few async sql_ops calls that should be overkill. I have no metrics to make a better assumption on the number of worker threads.
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
On 14/02/2017 14:36, Daniel Tryba wrote:
On Tue, Feb 14, 2017 at 02:27:59PM +0100, Igor Potjevlesch wrote:
Looks to be a good idea. I use MySQL and MyISAM, so I understand that async is supported.
Async (db_insert_mode=2) is supported with any (acc)backend. With myisam you can use delayed inserts (db_insert_mode=1). But without even looking at the kamailio implementation I'd guess that 2 is the better choice in the hope that the sql operation is entirely done in an other thread, with 1 there might be the chance that setting up/reusing connections might block (since insert delayed is a feature on the mysql server side that just returns an OK before any writes to disk).
How should I dimension the number of async_workers?
I set it to 2, but for acc and a few async sql_ops calls that should be overkill. I have no metrics to make a better assumption on the number of worker threads.
... ahh, forgot to say that even with async query, the insert can still fail if the db operations take too long, because of the timeout value set to db_mysql. So if the bottleneck is the mysql server, it doesn't matter how many async workers you create. I typically start 4, but use them for more than async sql queries.
Cheers, Daniel