Advertisement:

Author Topic: Restoring a Backup  (Read 562 times)

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Restoring a Backup
« on: February 12, 2020, 05:01:12 AM »
I recently upgraded my server, so I made a backup of the data, FTP'd the entire site to a local machine, upgraded the server, reinstalled 2.0.17, uploaded the database dump and added back the theme.

The only problem is that the boards look fine - the theme has worked - and the database appears to have the correct data in it, but the actual boards still show only the default single board and message. The various categories, boards and messages are in the database but the front end is stuck with the fresh install messages and structure.

Did I forget to change a file to writable somewhere? Any idea what has happened and - more importantly - how to fix it?
Many thanks.

Offline Illori

  • Project Manager
  • SMF Legend
  • *
  • Posts: 52,483
Re: Restoring a Backup
« Reply #1 on: February 12, 2020, 05:05:15 AM »
did you restore your backup to the same database that is being used by the install? it sounds like you have not.

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #2 on: February 12, 2020, 05:40:58 AM »
I only have the one database on that site.

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #3 on: February 12, 2020, 05:56:55 AM »
Well.... This is embarrassing......  ;D

So, I DO only have the one database for the site. When I made the backup, I went through phpMyAdmin.
When I restored it, I tried to do this through Plesk, and it clearly didnt work even though Plesk said that it did.

So.... Now I tried importing through phpMyAdmin I get the following error:
#1046 - No database selected

When I try to import through Plesk, I get a different error:
ERROR 1062 (23000) at line 43: Duplicate entry '1' for key 'PRIMARY'
program 'mysql' finished with non-zero exit code: 1

I realise that its my account causing the problem in the second case.
Any suggestions to solve this?

Many thanks.

EDIT - I am going to try a fresh install, and use the same prefix as the backup, then remove the entire database and create a new one to house the backup......
« Last Edit: February 12, 2020, 06:08:58 AM by CyberShadow »

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #4 on: February 12, 2020, 06:52:39 AM »
UPDATE - I removed the previous install, and reinstalled the forum fresh, using the same table prefix as the backup, then removed the database, created a blank one and reinstated the database backup.

Partial success. The database appears to have accepted the backup data and the topics, boards and threads are all present. However, it has now messed with the theme, and I am just getting the white page with no format links and text. So reinstating the backup messed with the link to the theme directory?

Online Gary

  • Sorceress's Knight
  • Customizer
  • SMF Super Hero
  • *
  • Posts: 18,283
  • Gender: Male
  • So this is the luck of the draw...
    • Gazmanafc on Facebook
    • garygadsdon on LinkedIn
    • @Gazmanafc on Twitter
    • The Bongo Comics Fan Forum
Re: Restoring a Backup
« Reply #5 on: February 12, 2020, 07:18:17 AM »
It sounds like your paths to directories haven't been reset, run repair_settings.php from the download page to do that.
Gary M. Gadsdon
Do NOT PM me unless I say so

War of the Simpsons
Bongo Comics Fan Forum
Youtube Let's Plays

^ YT is changing monetisation policy, help reach 1000 sub threshold.

Offline Illori

  • Project Manager
  • SMF Legend
  • *
  • Posts: 52,483
Re: Restoring a Backup
« Reply #6 on: February 12, 2020, 07:20:57 AM »

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #7 on: February 12, 2020, 08:02:12 AM »
Thank you both so much. It showed me where the problem was so I could fix it. I had nerfed the subdomain and the paths were all messed up.

I appreciate your assistance and time. Thanks.

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #8 on: February 13, 2020, 02:33:23 AM »
While the boards now appear to be working, there is an issue. Every time I attempt to post or edit a post, I initially get a '403 no permission' error, and then the boards crash (and take down my email with them). I assume that I have not set a write permission correctly, but I can post, it just takes a few attempts and it crashes more often than it works.

This would appear to be a database issue, as the rest of the static site is fine and it affects email too, but the permissions for the database were fine when the boards were in maintenance mode and I wasn't posting to them.

Thanks.

Offline m4z

  • 98.8% chimp
  • Localizer
  • Sophist Member
  • *
  • Posts: 1,102
  • /mɛs/
Re: Restoring a Backup
« Reply #9 on: February 13, 2020, 04:54:22 AM »
What do you mean by "my email", a webmailer software living on the same server?
"Faith is what you have in things that don't exist."
--Homer Simpson

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #10 on: February 14, 2020, 12:41:50 AM »
I am running a VPS across several domains. One domain has the SMF software, a second has my email account. I just tried again. My boards are offline, but I tried to edit a post that I made yesterday. First attempt resulted in a 403 no permission error. Then I tried to preview, got the same response. Tried to edit again, and the server timed out. Attempted to refresh my email and the server timed out there too.

So, it seems that I cant edit a post, and if I try it just overloads the server (including other sites and my email).

Thanks.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 59,311
  • Gender: Male
    • Kindred-999 on GitHub
Re: Restoring a Backup
« Reply #11 on: February 14, 2020, 12:43:40 PM »
sounds like some bad configurations of the server
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #12 on: February 19, 2020, 08:49:13 AM »
I removed the database user, used repair_settings to check the database password and set up the database user again to verify the correct connections.....

This seems to have solved the access issue and I can now post and edit posts fine... no 403 errors so far, anyway. However, the formatting of a post is messed up. I wrote this with the correct new lines and spacing, but this is how it is displayed (see attachment). When I edit the post, it displays in the editor also badly formatted, and when I correct it, it doesn't change up update.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 59,311
  • Gender: Male
    • Kindred-999 on GitHub
Re: Restoring a Backup
« Reply #13 on: February 19, 2020, 09:11:43 AM »
are you using the wysiwyg?  If so, don't...  the 2.0 wysiwyg is so broken that we completely removed and replaced it in 2.1 since it was more work to fix it than to replace it.
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Offline CyberShadow

  • Semi-Newbie
  • *
  • Posts: 78
Re: Restoring a Backup
« Reply #14 on: February 20, 2020, 04:16:15 AM »
are you using the wysiwyg?  If so, don't...  the 2.0 wysiwyg is so broken that we completely removed and replaced it in 2.1 since it was more work to fix it than to replace it.

Fantastic! That solved it.
Many thanks to all in this thread who helped me out.