Performance / MySQL Partitions / Foreign Keys

Discussion in 'General discussions' started by assuncao, Nov 22, 2018.

  1. assuncao

    assuncao Member

    Joined:
    Aug 17, 2016
    Messages:
    52
    Likes Received:
    7
    S.E:
    Expired
    L.T:
    Regular
    L.C:
    1
    Hi everyone,

    I'm here to ask if does anyone know if the Foreign Keys can be removed without any problem from the tables. Would it be a problem? I would like to create partitions in my database and foreign keys aren't allowed in the tables. It is getting bigger and almost becoming unusable. My scenario:

    SERVER 1 (FRONTEND): 20GB RAM, 8 CPUs, SSD
    SERVER 2 (DATABASE) 20GB RAM, 8 CPUs, SSD

    Some info (in rows):
    mw_campaign_delivery_log: 40M
    mw_list_subscriber: 2M
    mw_list_field_value: 450000000M (yes, almost half a billion)

    Does anyone have any suggestion to improve MW?
     
  2. twisted1919

    twisted1919 Administrator Staff Member

    Joined:
    Dec 27, 2014
    Messages:
    9,697
    Likes Received:
    2,268
    Take a look at https://kb.mailwizz.com/articles/performance-improvements/
    As a side effect, if you remove fk's from mw_list_field_value then when you will remove a subscriber or more from your database, it won't automatically remove records from this table, you have to do it manually.
     
  3. frm.mwz

    frm.mwz Well-Known Member

    Joined:
    Mar 8, 2016
    Messages:
    3,532
    Likes Received:
    656
    S.E:
    2019-05-17 04:02:46
    L.T:
    Regular
    L.C:
    7
    Try amazon aurora, one the fastest DBMS ;)
     

Share This Page