Forum

Results 1 to 3 of 3
  1. #1
    Join Date
    January 2009
    Location
    Graz
    Posts
    19

    Server quits silently with MariaDB setting wait_timeout < 1620 and DB Server restart

    --- Steps to reproduce: ---

    in /etc/mysql/my.cnf set wait_timeout less than 1620, eg.:

    wait_timeout = 60

    restart mysql and restart teamspeak server

    the teamspeak server will silently stop after one minute without leving anything in the logs.
    (the same silent quit also happens everytime the mysql server is restarted even if the server is just idleing without any clients connected.)


    --- Enviroment: ---

    Debian Jessie (current stable) MariaDB 10.0.20

    ldd libts3db_mariadb.so
    linux-vdso.so.1 (0x00007ffe91fdc000)
    libmariadb.so.2 => /usr/lib/x86_64-linux-gnu/libmariadb.so.2 (0x00007fdf7a25e000)
    libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fdf79f5d000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fdf79bb4000)
    /lib64/ld-linux-x86-64.so.2 (0x00007fdf7a7a6000)
    libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fdf79999000)
    libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fdf7977c000)
    libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fdf79578000)
    libssl.so.1.0.0 => /usr/lib/x86_64-linux-gnu/libssl.so.1.0.0 (0x00007fdf79318000)
    libcrypto.so.1.0.0 => /usr/lib/x86_64-linux-gnu/libcrypto.so.1.0.0 (0x00007fdf78f1d000)


    --- Expected Behaviour: ---

    If the MariaDB Server closes the connection after some timeout, tss3 should reconnect.

    If the MariaDB Server is gone (e.g. for a restart) tss3 should also try to reconnect (but after a few seconds) some information in the logs before quitting would also be very nice.

    (Alternatively tss3 could keep the connection alive by doing a "SELECT 1", every 30 seconds but this would not help on the mysql restart issue)


    --- Background: ---

    On a server with some websites, mail/ftp users using mysql e.g. for authentication and recipient maps it can happen that there are many open connections with most of them just sleeping. In order to reduce the number of sleeping connections it is a best practice to lower the wait_timeout to something smaller than the default of 28800 (8 hours) instead of just rising the max_connections limit. Having the timeout at e.g. 600 seconds is a reasonable good value on such a system, or on busy servers (e.g. with websites leaving lots of unused mysql connections open) it may also be wise to set it even lower to prevent DOS.

  2. #2
    Join Date
    June 2008
    Posts
    17,926
    Normally the server should write something in the instance log.

    What i know is, that we have a wanted instance shutdown, when databse can not be read or written.
    We can not give support, when your databse is not availble for the server. Even when it is only 10 seconds.
    When sending me private messages: Please make sure to include reference link to your forum thread or post.

    TeamSpeak FAQ || What should i report, when i open a client thread?

  3. #3
    Join Date
    January 2009
    Location
    Graz
    Posts
    19
    Quote Originally Posted by dante696 View Post
    Normally the server should write something in the instance log.
    no. nothing in the logs

    Code:
    cat ts3server_2015-09-22__08_32_57.882980_*
    
    2015-09-22 08:32:57.883030|INFO    |ServerLibPriv |   | TeamSpeak 3 Server 3.0.11.4 (2015-08-18 13:30:34)
    2015-09-22 08:32:57.883110|INFO    |ServerLibPriv |   | SystemInformation: Linux 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u2 (2015-07-17) x86_64 Binary: 64bit
    2015-09-22 08:32:57.883137|INFO    |ServerLibPriv |   | Using hardware aes
    2015-09-22 08:32:57.883977|INFO    |DatabaseQuery |   | dbPlugin name:    MariaDB plugin, (c)TeamSpeak Systems GmbH
    2015-09-22 08:32:57.884009|INFO    |DatabaseQuery |   | dbPlugin version: 1
    2015-09-22 08:32:58.053866|INFO    |Accounting    |   | Licensing Information
    2015-09-22 08:32:58.053905|INFO    |Accounting    |   | type              : Non-profit
    2015-09-22 08:32:58.053931|INFO    |Accounting    |   | starting date     : Tue Jun 16 00:00:00 2015
    2015-09-22 08:32:58.053953|INFO    |Accounting    |   | ending date       : Tue Dec 22 00:00:00 2015
    2015-09-22 08:32:58.053975|INFO    |Accounting    |   | max virtualservers: 10
    2015-09-22 08:32:58.053994|INFO    |Accounting    |   | max slots         : 512
    2015-09-22 08:32:58.441150|INFO    |              |   | Puzzle precompute time: 379
    2015-09-22 08:32:58.441249|INFO    |FileManager   |   | listening on 123.123.123.123:30033
    2015-09-22 08:32:58.502782|INFO    |CIDRManager   |   | updated query_ip_whitelist ips: 127.0.0.1, 234.234.234.234, 
    2015-09-22 08:32:58.503283|INFO    |Query         |   | listening on 123.123.123.123:10011
    2015-09-22 08:32:58.469278|INFO    |VirtualServer |  1| listening on 123.123.123.123:54321
    2015-09-22 08:32:58.489309|INFO    |VirtualServer |  2| listening on 123.123.123.123:23456
    2015-09-22 08:32:58.502672|INFO    |VirtualServer |  3| listening on 123.123.123.123:12000
    
    
    ts3server.ini
    --------------
    
    machine_id=
    default_voice_port=54321
    voice_ip=123.123.123.123
    licensepath=
    filetransfer_port=30033
    filetransfer_ip=123.123.123.123
    query_port=10011
    query_ip=123.123.123.123
    dbplugin=ts3db_mariadb
    dbpluginparameter=ts3db_mariadb.ini
    dbsqlpath=sql/
    dbsqlcreatepath=create_mariadb/
    logpath=logs
    logquerycommands=1
    dbclientkeepdays=30
    
    
    ts3db_mariadb.ini
    --------------------
    
    [config]
    host='127.0.0.1'
    port='3306'
    username='ts3'
    password='****************'
    database='ts3'
    socket='/var/run/mysqld/mysqld.sock'


    Quote Originally Posted by dante696 View Post
    What i know is, that we have a wanted instance shutdown, when databse can not be read or written.
    We can not give support, when your databse is not availble for the server. Even when it is only 10 seconds.
    the server also shuts down silently if the database is accessible but the connection is closed by the database server because of a long time without any activity. instead of making a new connection, tss3 just quits, leaving nothing in the logs.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [No Bug] Server Crash on Database-Server restart (MariaDB) ?
    By brrrt in forum Server Support
    Replies: 2
    Last Post: August 31st, 2015, 04:26 PM
  2. TS3-Server stops after about 24 minutes using MariaDB
    By whfor in forum Linux / FreeBSD
    Replies: 2
    Last Post: April 15th, 2015, 03:53 PM
  3. Teamspeak server shutdown randomly (3.0.11.1 MariaDB)
    By xxFankxx in forum Server Support
    Replies: 4
    Last Post: December 12th, 2014, 01:00 AM
  4. TS3 server Debian MariaDB not working (Permissions bug?)
    By triggerim in forum Linux / FreeBSD
    Replies: 4
    Last Post: July 12th, 2014, 01:22 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •