Can one forum write to two databases?

Discussion in 'Databases' started by toronto905, Dec 2, 2009.

  1. #1
    Here are the details:

    -I have an SMF forum
    -It runs on MySQL database.

    I would like to do it so that the forum is writting to two instead of one database. This so that I have a backup, in case one database fails, I can simply switch to the other one.

    More like mirroring.

    Is this even possible?


    Thanks,
     
    toronto905, Dec 2, 2009 IP
  2. bluebenz

    bluebenz Well-Known Member

    Messages:
    876
    Likes Received:
    9
    Best Answers:
    2
    Trophy Points:
    138
    #2
    I think it will involving scripting.
    or,
    Try your asking host, probably they have auto backup..

    Good luck :)
     
    bluebenz, Dec 2, 2009 IP
  3. Brandon Sheley

    Brandon Sheley Illustrious Member

    Messages:
    9,721
    Likes Received:
    612
    Best Answers:
    2
    Trophy Points:
    420
    #3
    yes, shouldn't be a problem
    but if you're worried about a DB failing, I suggest getting a better host ;)
     
    Brandon Sheley, Dec 2, 2009 IP
  4. cahya77

    cahya77 Member

    Messages:
    80
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    36
    #4
    yeah,,
    writing into 2 databases will need more time...
    it can influences your aplication performance,,,,
     
    cahya77, Dec 15, 2009 IP
  5. nstewart

    nstewart Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Try to use something similar to MySQL Replicator. You don't have to change SMF to write in 2 databases. You could use a synchronization tool/script
     
    nstewart, Dec 15, 2009 IP
  6. Internal09

    Internal09 Member

    Messages:
    256
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    35
    #6
    Yes it is possible. I am sure that there is a config file and if you add another database name I think it might work but remember to backup the original.
     
    Internal09, Dec 15, 2009 IP
  7. joshcrowder

    joshcrowder Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    You can, you wouldn't do it on the save of an entry you'd probably do it on the server itself.
     
    joshcrowder, Dec 17, 2009 IP