Site Not working sql deleted need fix

Discussion in 'Programming' started by tech4, Jul 30, 2009.

  1. #1
    I am not sure if this is a piece of work or what?

    I accidentally deleted some sql user/file
    didn't make a backup. Now the site is non functional. Everything is there, but ... a must see. www.allfoodmenu.com

    Can you fix it? base on the error
    Free review.

    Let me know.

    Update.

    Okay I have the backup of the sql in a full backup .tar only able to open in linux, Ineed someone to extract that to retrieve the SQL file. the backup is inside my server (full backup) I contacted my server and they are looking into it. Bull shit taking them so long. I can do a directory backup but cannot do a full backup. I cannot open a .tar file.

    File is inside server, if anyone has hosting experience can do this, I give you a free review. Open up my files for me. Thsi requires a linux/unix.

    Not possible with windows.

    And Ihave a DPpoint member from India who wants to do this for $20/hr. Another Bullshit.
     
    Last edited: Jul 30, 2009
    tech4, Jul 30, 2009 IP
  2. carolynheath

    carolynheath Peon

    Messages:
    680
    Likes Received:
    63
    Best Answers:
    0
    Trophy Points:
    0
    As Seller:
    100% - 0
    As Buyer:
    100% - 0
    #2
    Well, $20 an hour to extract a tarball would only come down to a few cents, as it doesn't take but a second of work ;). Shoot me the file and I'll help you out for free.
     
    carolynheath, Jul 30, 2009 IP
  3. eli03

    eli03 Well-Known Member

    Messages:
    2,887
    Likes Received:
    98
    Best Answers:
    0
    Trophy Points:
    175
    As Seller:
    100% - 0
    As Buyer:
    100% - 0
    #3
    use winrar to extract the files from the tar file but if you have big files it's better to untar it on linux, you must have shell access to this. If you still need help just pm me. thanks
     
    eli03, Jul 31, 2009 IP
  4. tech4

    tech4 Well-Known Member

    Messages:
    544
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    125
    As Seller:
    100% - 0
    As Buyer:
    100% - 0
    #4
    Well after hours and days. My host finally restored my site to its prehistoric age. So I was able to extract the .sql file with the connection strings that I deleted.

    They were like this

    Users in food
    allfoodm_aston (Privileges: ALL PRIVILEGES)

    Connection Strings
    Perl $dbh = DBI->connect("DBI:mysql:allfoodm_food:localhost",
    "allfoodm_aston","<PASSWORD HERE>");
    PHP $dbh=mysql_connect ("localhost", "allfoodm_aston",
    "<PASSWORD HERE>") or die('Cannot connect to the database because: ' . mysql_error());
    mysql_select_db ("allfoodm_food");

    allfoodm_travel (Privileges: ALL PRIVILEGES)

    Connection Strings
    Perl $dbh = DBI->connect("DBI:mysql:allfoodm_food:localhost",
    "allfoodm_travel","<PASSWORD HERE>");
    PHP $dbh=mysql_connect ("localhost", "allfoodm_travel",
    "<PASSWORD HERE>") or die('Cannot connect to the database because: ' . mysql_error());
    mysql_select_db ("allfoodm_food");


    What I did was upload a file called allfoodm_food.sql it was the latest, without the strings (I deleted them)
    So there was also the prehistoric allfoodm_food.sql on it with the strings.

    Somehow server recognizes it and merges them? or the host does that? Now site works.

    What a headache. Waiting days...

    Thanks everyone for their help. :)

    Luckily I had the backup. but it was an outdated one.
     
    tech4, Jul 31, 2009 IP