Gbak ultra slow when restoring on remote server ?

74 views
Skip to first unread message

Yordan Yanakiev

unread,
Nov 5, 2023, 5:52:21 AM11/5/23
to firebird-support
Hello.
I am trying to automatize some processes, and I wish to restore a local backup on remote server. 
If i am restoring it directly locally or on the server it goes quite fast - a few seconds, but if i do it from local to the server with the follow command :
gbak -c F:\Migrator\test6_MIG.fbk remote_server_ip/3050:C:\base\test2\test2.fdb -user test2 -password test2
it taking tens of minutes for a database with size just 22 mb.
What I am doing wrong ?

Dimitry Sibiryakov

unread,
Nov 5, 2023, 6:03:38 AM11/5/23
to firebird...@googlegroups.com
Yordan Yanakiev wrote 05.11.2023 11:52:
> gbak -c F:\Migrator\test6_MIG.fbk remote_server_ip/3050:C:\base\test2\test2.fdb
> -user test2 -password test2
> it taking tens of minutes for a database with size just 22 mb.
> What I am doing wrong ?

Nothing but in this situation you would better use fbsvcmgr like this:

fbsvcmgr.exe remote_server_ip/3050:service_mgr user test2 password test2
action_restore dbname C:\base\test2\test2.fdb bkp_file stdin
<F:\Migrator\test6_MIG.fbk

--
WBR, SD.

Yordan Yanakiev

unread,
Nov 5, 2023, 6:16:55 AM11/5/23
to firebird-support
Good lords ! This doing it almost like on my local PC ! :O
Is there something bad which can happens using  fbsvcmgr instead of gbak ?

Dimitry Sibiryakov

unread,
Nov 5, 2023, 6:19:59 AM11/5/23
to firebird...@googlegroups.com
Yordan Yanakiev wrote 05.11.2023 12:16:
> Is there something bad which can happens using fbsvcmgr instead of gbak ?

No. It uses the same gbak only on remote side sending backup file there as whole.

I guess your database has a lot of BLOBS and perhaps they have small
segments. This is known problem for Firebird over high latency network.

--
WBR, SD.

Mark Rotteveel

unread,
Nov 5, 2023, 6:29:34 AM11/5/23
to firebird...@googlegroups.com
Alternatively, use gbak with the `-se` switch, but in that case the
backup file must be on the remote server, not on your machine.

Mark
--
Mark Rotteveel

Yordan Yanakiev

unread,
Nov 5, 2023, 7:51:37 AM11/5/23
to firebird-support
Lovely ! Thank You   Dimitry Sibiryakov  and  Mark Rotteveel !!
Reply all
Reply to author
Forward
0 new messages