Skip to content

ALC-1002: Connection lost

The connection to the server dropped, or the server stopped answering, while Alcuin was using it. Your tabs, unsaved queries and the rows already on screen stay where they are.

A banner across the top of the window reads Connection lost. Reconnecting…, with Your tabs and unsaved queries are safe. Rows already loaded stay on screen. If a transaction was open, it adds A transaction was open when the connection dropped; the server rolled it back. Alcuin tries again every few seconds, backing off to every 10 seconds, and the banner clears itself when the server answers. Retry now tries at once.

A banner under the top bar reading Connection lost. Reconnecting… Your tabs and unsaved queries are safe. Rows already loaded stay on screen., with a Retry now button.

The banner while Alcuin reconnects. Retry now tries at once.

The request that was running when the connection dropped fails with one of these messages:

  • The connection was lost. Run again to reconnect.: a query tab’s statement.
  • The connection was lost, and with it the open transaction: nothing in it was committed. Run again to reconnect.: the tab had a transaction open.
  • The server stopped answering. Try again.: a read of the database’s structure, or a page of a table’s rows, got no answer within two minutes, so Alcuin gave up on the connection.
  • Could not reach the server. Try again.: Alcuin tried to reconnect and the server was still unreachable.
  • The connection dropped before the changes were committed. Nothing changed; apply them again.: staged row changes were being committed.
  • The connection was closed.: the connection was closed while a tab waited for it.
  • Alcuin’s engine restarted while this was running. Try again.: Alcuin’s own engine process restarted while the request was running.
  • A network error from the operating system, such as read ECONNRESET, read ETIMEDOUT, EHOSTUNREACH or Connection terminated unexpectedly.

After an engine restart, Alcuin reopens the connection and shows The engine restarted and reconnected. If the connection had been unlocked, the message adds Editing is locked again; unlock it to make changes.

  • The network dropped: Wi-Fi changed, a VPN disconnected, or the computer slept.
  • The server restarted, failed over to a replica, or ended the session (an administrator, or an idle timeout set on the server).
  • A pooler, load balancer or firewall between you and the server closed a connection it considered idle.
  • The SSH tunnel closed.
  • The server is overloaded and did not answer a structure read or a table page within two minutes.
  • Alcuin’s engine process restarted.
  1. Wait for the banner to clear, or click Retry now.
  2. Run the statement again. A query tab opens a new session on its next run.
  3. If a transaction was open, the server rolled it back and nothing in it was committed. Run the whole transaction again from BEGIN.
  4. Staged row changes stay staged. If the message says Nothing changed, commit them again. If the connection dropped during the commit itself, see ALC-1005.
  5. If the connection was unlocked before an engine restart, unlock it again with Unlock editing….

If the banner does not clear, the server cannot be reached at all. Open the connection’s settings and click Test connection; Connection errors by message explains each message it reports.

If connections drop often, look for idle timeouts on a pooler, load balancer or firewall, and check the server’s log for the time of the drop. The server-side settings idle_session_timeout and idle_in_transaction_session_timeout also end sessions.

The engine reports this as ENGINE_CONNECTION_LOST. Quote either name in an issue.