• A while ago I backed up the whole home directory of my site. Now I am looking through my backup file and cannot find any of the posts. I understand that the posts are held in a database (SQL, I think). However I do not know the location of the database and there are too many to search through.
    Please help!

    P.S. I am using cPanel

Viewing 7 replies - 1 through 7 (of 7 total)
  • Your database is at your hosted account. If you are signed in there you should see MySQL or something to that effect. The default database tables for WordPress start with wp_ unless you called them something different at setup.

    Thread Starter rorygordonesq

    (@rorygordonesq)

    Thanks.
    The issue is that there seem to be many different MySQL files, all based off of WordPress. Hence, I am not sure which one to use.

    They would be in the table called *_posts. Most of the time wp_posts.

    If there are different wp databases there because of multiple sites, installs, etc. look at the db that is in your wp-config.php file.

    Thread Starter rorygordonesq

    (@rorygordonesq)

    The posts do not seem to be labelled posts, I know this as I have tried searching for posts. To give an example of what I mean by the fact that there are many MySQL files the file containing all of the comments is called name_mage851.sql.

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    However I do not know the location of the database and there are too many to search through.

    That’s not really the best way to do it. Even if you found the mysql files (it’s usually not anywhere your WordPress files) you’d have a tough time restoring the data.

    Tough time as in “it just wouldn’t work”. ??

    Use phpMyAdmin or straight mysql CLI commands to perform a backup. That will save your data to text files that could be restored.

    https://codex.www.ads-software.com/Backing_Up_Your_Database
    https://codex.www.ads-software.com/Restoring_Your_Database_From_Backup

    If your host doesn’t provide you with phpMyAdmin, ask then if they can.

    Thread Starter rorygordonesq

    (@rorygordonesq)

    Thank you. I have now been able to view my posts through the phpAdmin. However I am now wondering what is the best way to put the posts on the new site. (I am able to view all of the text when I ‘edit’ the php files.)

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    I have now been able to view my posts through the phpAdmin.

    That’s a relief, it’d be rough going if you couldn’t find it. ??

    If you have access to the old WordPress install then you can just create a WXR export file and import that WXR file into your new blog. That’s the easiest way to get the posts onto a new location.

    https://codex.www.ads-software.com/Tools_Export_Screen

    With that WXR file you can then import it into your new blog.

    Or if you have access to the old the database but not the old WordPress install, then export the database to a .sql file from the old database and update the new database with that file.

    https://codex.www.ads-software.com/Restoring_Your_Database_From_Backup

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Where are the posts in my backup?’ is closed to new replies.