Server fails to start on FreeBSD

Discussion in 'Server Discussion' started by jrronimo, Jun 4, 2019.

  1. jrronimo

    jrronimo Level 0

    Joined:
    Jun 4, 2019
    Messages:
    2
    Hello all!

    I have previously used TShock successfully to host Terraria from my FreeBSD server. It's been quite a while since I started the server up though, so I downloaded 4.3.26 and ran

    $mono --server --gc=sgen -O=all TerrariaServer.exe -port 7790 -maxplayers 8 -world "/home/jrr/My Games/Terraria/Worlds/hotdogs-af.wld"​

    which yields the following:

    TerrariaAPI Version: 2.1.0.0 (Protocol v1.3.5.3 (194), OTAPI 1.3.5.3)
    TShock was improperly shut down. Please use the exit command in the future to prevent this.
    Port overridden by startup argument. Set to 7790
    Startup parameter overrode maximum player slot configuration value.​

    ....and I can't find any information about what's going on. I installed the latest mono as well, which is mono-5.10.1.57_1

    Oh, and the most recent log is having a problem with MySQL it would appear:

    Code:
    2019-06-04 16:42:27 - TShock: INFO: TShock was improperly shut down. Please use the exit command in the future to prevent this.
    2019-06-04 16:42:27 - <>c: INFO: Port overridden by startup argument. Set to 7790
    2019-06-04 16:42:27 - TShock: ERROR: Fatal Startup Exception
    2019-06-04 16:42:27 - TShock: ERROR: System.Exception: Fatal TShock initialization exception: failed to connect to MySQL database. See inner exception for details. ---> System.DllNotFoundException: libsqlite3.so
      at (wrapper managed-to-native) Mono.Data.Sqlite.UnsafeNativeMethods.sqlite3_open_v2(byte[],intptr&,int,intptr)
      at Mono.Data.Sqlite.SQLite3.Open (System.String strFilename, Mono.Data.Sqlite.SQLiteOpenFlagsEnum flags, System.Int32 maxPoolSize, System.Boolean usePool) [0x00046] in <2f714ef98a8f4e73b149f84ee80555a1>:0
      at Mono.Data.Sqlite.SqliteConnection.Open () [0x0021a] in <2f714ef98a8f4e73b149f84ee80555a1>:0
      at TShockAPI.DB.DbExt.QueryReader (System.Data.IDbConnection olddb, System.String query, System.Object[] args) [0x00007] in <ada224128ad446d0bd7a8e65ac0083cb>:0
       --- End of inner exception stack trace ---
      at TShockAPI.DB.DbExt.QueryReader (System.Data.IDbConnection olddb, System.String query, System.Object[] args) [0x0006a] in <ada224128ad446d0bd7a8e65ac0083cb>:0
      at TShockAPI.DB.SqlTableCreator.GetColumns (TShockAPI.DB.SqlTable table) [0x00035] in <ada224128ad446d0bd7a8e65ac0083cb>:0
      at TShockAPI.DB.SqlTableCreator.EnsureTableStructure (TShockAPI.DB.SqlTable table) [0x0000d] in <ada224128ad446d0bd7a8e65ac0083cb>:0
      at TShockAPI.DB.BanManager..ctor (System.Data.IDbConnection db) [0x000ca] in <ada224128ad446d0bd7a8e65ac0083cb>:0
      at TShockAPI.TShock.Initialize () [0x0039a] in <ada224128ad446d0bd7a8e65ac0083cb>:0

    I... don't know what else to do to troubleshoot this. Any ideas?
     
    #1 jrronimo, Jun 4, 2019
    Last edited: Jun 4, 2019
  2. jrronimo

    jrronimo Level 0

    Joined:
    Jun 4, 2019
    Messages:
    2
    Hey, found the fix myself. Hooray! I'll leave this here in case anyone else runs into this and can't find the solution:

    From the Log file, was the line:

    Code:
    2019-06-04 16:42:27 - TShock: ERROR: System.Exception: Fatal TShock initialization exception: failed to connect to MySQL database. See inner exception for details. ---> System.DllNotFoundException: libsqlite3.so
    Turns out sqlite3 wasn't installed on my system! D:

    So:
    Code:
    #pkg install sqlite3
    and everything is happy afterwards!