$ ./scripts/remote-gdb 10.0.1.100:9999 ./build_dir/target-x86_64_glibc-2.27/urbackup-server-2.4.13/urbackupsrv
Using target x86_64 (glibc, -2.27)
GNU gdb (GDB) 11.1
Copyright (C) 2021 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "--host=x86_64-pc-linux-gnu --target=x86_64-openwrt-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./build_dir/target-x86_64_glibc-2.27/urbackup-server-2.4.13/urbackupsrv...
0x00007ffff7fd8090 in _start ()
from /root/Entware/scripts/../staging_dir/target-x86_64_glibc-2.27/root-x64-3.2/opt/lib/ld-linux-x86-64.so.2
(gdb) set remote exec-file /opt/bin/urbackupsrv
(gdb) set args run -u admin -v debug
(gdb) run
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /root/Entware/build_dir/target-x86_64_glibc-2.27/urbackup-server-2.4.13/urbackupsrv run -u admin -v debug
[New Thread 9407.9409]
[New Thread 9407.9410]
Thread 1 "urbackupsrv" received signal SIGSEGV, Segmentation fault.
0x000000000055dece in sqlite3WalFindFrame (pWal=0xbdb948, pgno=1, piRead=piRead@entry=0x7fffffffb394) at sqlite/sqlite3.c:60697
60697 for(iKey=walHash(pgno); sLoc.aHash[iKey]; iKey=walNextHash(iKey)){
(gdb) bt
#0 0x000000000055dece in sqlite3WalFindFrame (pWal=0xbdb948, pgno=1, piRead=piRead@entry=0x7fffffffb394)
at sqlite/sqlite3.c:60697
#1 0x000000000055e002 in readDbPage (pPg=pPg@entry=0xbf0f88) at sqlite/sqlite3.c:53112
#2 0x000000000056608f in getPageNormal (pPager=0xbbc758, pgno=1, ppPage=0x7fffffffb400, flags=<optimized out>)
at sqlite/sqlite3.c:55607
#3 0x0000000000525fdd in sqlite3PagerGet (flags=0, ppPage=0x7fffffffb400, pgno=1, pPager=<optimized out>)
at sqlite/sqlite3.c:55722
#4 btreeGetPage (pBt=pBt@entry=0xbba518, pgno=pgno@entry=1, ppPage=ppPage@entry=0x7fffffffb460, flags=flags@entry=0)
at sqlite/sqlite3.c:64699
#5 0x0000000000567291 in lockBtree (pBt=0xbba518) at sqlite/sqlite3.c:65657
#6 sqlite3BtreeBeginTrans (p=0xbba448, wrflag=wrflag@entry=0, pSchemaVersion=pSchemaVersion@entry=0x0)
at sqlite/sqlite3.c:493
#7 0x0000000000595211 in sqlite3InitOne (db=0xbbbe08, iDb=iDb@entry=0, pzErrMsg=pzErrMsg@entry=0x7fffffffc248,
mFlags=mFlags@entry=0) at sqlite/sqlite3.c:122405
#8 0x00000000005953cc in sqlite3Init (db=db@entry=0xbbbe08, pzErrMsg=pzErrMsg@entry=0x7fffffffc248)
at sqlite/sqlite3.c:122590
#9 0x000000000059540f in sqlite3ReadSchema (pParse=pParse@entry=0x7fffffffc240) at sqlite/sqlite3.c:122616
#10 0x00000000005a1a50 in sqlite3Pragma (pParse=pParse@entry=0x7fffffffc240, pId1=pId1@entry=0x7fffffffb888,
pId2=pId2@entry=0x7fffffffb8a0, pValue=pValue@entry=0x7fffffffb8d0, minusFlag=minusFlag@entry=0)
at sqlite/sqlite3.c:120139
#11 0x00000000005a4567 in yy_reduce (yyLookahead=<optimized out>, pParse=0x7fffffffc240, yyruleno=232,
yypParser=0x7fffffffb840, yyLookaheadToken=...) at sqlite/sqlite3.c:149648
#12 sqlite3Parser (yyminor=..., yymajor=<optimized out>, yyp=0x7fffffffb840) at sqlite/sqlite3.c:19102
#13 sqlite3RunParser (pParse=0x7fffffffc240, zSql=0xbdb371 "", pzErrMsg=0x7fffffffc238) at sqlite/sqlite3.c:20225
#14 0x00000000005a97d4 in sqlite3Prepare (db=db@entry=0xbbbe08, zSql=zSql@entry=0xbbc308 "PRAGMA synchronous=NORMAL",
nBytes=nBytes@entry=25, prepFlags=prepFlags@entry=128, pReprepare=pReprepare@entry=0x0,
ppStmt=ppStmt@entry=0x7fffffffc4e8, pzTail=0x7fffffffc4f0) at sqlite/sqlite3.c:122806
#15 0x00000000005a9c0f in sqlite3LockAndPrepare (db=0xbbbe08, zSql=0xbbc308 "PRAGMA synchronous=NORMAL", nBytes=25,
prepFlags=prepFlags@entry=128, pOld=pOld@entry=0x0, ppStmt=ppStmt@entry=0x7fffffffc4e8, pzTail=0x7fffffffc4f0)
at sqlite/sqlite3.c:122906
--Type <RET> for more, q to quit, c to continue without paging--
#16 0x00000000005a9f46 in sqlite3_prepare_v2 (db=<optimized out>, zSql=<optimized out>, nBytes=<optimized out>,
ppStmt=ppStmt@entry=0x7fffffffc4e8, pzTail=pzTail@entry=0x7fffffffc4f0) at sqlite/sqlite3.c:122989
#17 0x00000000004c8c76 in CDatabase::Prepare (this=this@entry=0xbbbc90, pQuery=..., autodestroy=autodestroy@entry=false)
at Database.cpp:341
#18 0x00000000004c6d78 in CDatabase::Write (this=0xbbbc90, pQuery=...) at Database.cpp:232
#19 0x00000000004ca84b in CDatabase::Open (this=this@entry=0xbbbc90, pFile=..., attach=...,
allocation_chunk_size=allocation_chunk_size@entry=52428800, p_single_user_mutex=p_single_user_mutex@entry=0xbbb990,
p_lock_mutex=p_lock_mutex@entry=0xbb7da0, p_lock_count=0xbbb860, p_unlock_cond=0xbb8e70, p_params=...)
at /root/Entware/staging_dir/toolchain-x86_64_gcc-8.4.0_glibc-2.27/x86_64-openwrt-linux-gnu/include/c++/8.4.0/ext/new_allocator.h:79
#20 0x00000000004d715f in CServer::getDatabase (this=this@entry=0xb76dc0, tid=<optimized out>,
pIdentifier=pIdentifier@entry=23) at Server.cpp:917
#21 0x00000000006270b6 in open_server_database (init_db=<optimized out>) at urbackupserver/dllmain.cpp:239
#22 0x0000000000631ae0 in LoadActions_urbackupserver (pServer=<optimized out>) at urbackupserver/dllmain.cpp:644
#23 0x00000000004daaae in CServer::LoadStaticPlugins (this=this@entry=0xb76dc0) at Server.cpp:2246
#24 0x00000000004f0748 in main_fkt (argc=<optimized out>, argv=<optimized out>) at main.cpp:554
#25 0x00000000004f2d7d in main_fkt_catch (argc=<optimized out>, argv=<optimized out>) at main.cpp:130
#26 0x000000000082db01 in run_real_main (args=...) at urbackupserver/cmdline_preprocessor.cpp:98
#27 0x00000000008396e7 in action_run (args=...) at urbackupserver/cmdline_preprocessor.cpp:531
#28 0x00000000004bfd3d in main (argc=<optimized out>, argv=0x7fffffffe898) at urbackupserver/cmdline_preprocessor.cpp:1270
(gdb)
A lot more context in the original Entware issue.