Lost connection to MySQL (over internet)
Posted: Fri 12 Jun 2020 16:43
ive been reading all the post related to this problem and nothing seems to work.
i have a Delphi 7 app using MyDac components, on a local network everything works perfect but we need to move the MySQL database to a hosting and access it over internet, we have lots "loss of connection" problems
this we are done so far:
set Tmyconnection.LocalFailOver = True
trying different values to TmyConnection.ConnectionTimeOut (from 15 to 1000)
create a procedure for the Tmyconnection.OnconnectionLost event...
what we can't do...
we read about wait_timeout MySQL system variable and max_allowed_packet server variable but the provider does not allow us to change the values (also Max_allowed_packet is related to large amount of data and we are getting loss connection error even with 1 record querys
What can we try?
i have a Delphi 7 app using MyDac components, on a local network everything works perfect but we need to move the MySQL database to a hosting and access it over internet, we have lots "loss of connection" problems
this we are done so far:
set Tmyconnection.LocalFailOver = True
trying different values to TmyConnection.ConnectionTimeOut (from 15 to 1000)
create a procedure for the Tmyconnection.OnconnectionLost event...
Code: Select all
procedure TDM.DirdatosConnectionLost(Sender: TObject;
Component: TComponent; ConnLostCause: TConnLostCause;
var RetryMode: TRetryMode);
begin
RetryMode := rmReconnectExecute;
end;
we read about wait_timeout MySQL system variable and max_allowed_packet server variable but the provider does not allow us to change the values (also Max_allowed_packet is related to large amount of data and we are getting loss connection error even with 1 record querys
What can we try?