Check out the LimeSurvey source code on GitHub!

General Backup question

More
5 years 4 months ago #67393 by lister171254
I have looked in the manual for this, but cannot find a reasonably detailed answer to the following questions.

1) If I do a nightly dump of the mysql DB, is there and easy way to restore the questionnaire?
2) If I export the full database via the Limesurvey feature, how can this be restored

Thanks

Please Log in to join the conversation.

More
5 years 4 months ago #67396 by DenisChenu
You can purge all database and reimport it via phpmyadmin for example if you are on mysql.

It's like all database system: purge, reimport

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).

Please Log in to join the conversation.

More
5 years 4 months ago #67403 by Mazi
There are no inbuild functions at Limesurvey to import such a backup, but all database systems can import the generated .sql files.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 4 months ago #67410 by lister171254
I just thought that given that there is the builtin funtionality of doing a full database export (great feature) there would be a built in feature the import the database (or a particular survey including the responses

Please Log in to join the conversation.

More
5 years 4 months ago #67411 by lister171254
yes, thanks for the suggestions, but isn't there more to this? What about the web side of things. I'm talking about a system failure where I need to restore the Survey.

I guess the answer is that I need to restore both the web directories + the DB

Please Log in to join the conversation.

More
5 years 4 months ago #67412 by Mazi
All survey data is stored at the database. So if something breaks and you have a DB backup, all is fine.
Of course, when modifying the core files you should always create backups, but those files are only touched when updating to a newer version (while data is usually not touched during update).


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 4 months ago #67415 by lister171254
Thanks, but am still not entirely clear how this will work. Maybe an example will clarify this.

Let's start with a Survey called Survey-A. I'm backing the database up every night and after two weeks I decide to try and restore Survey-A at another site to ensure the backups work. If I have Limesurvey already running at the other site, what would be the steps to restore Survey-A at the new site (assuming the core files are the same. Will restoring the DB be the only thing I have to do?

Thanks

Please Log in to join the conversation.

More
5 years 4 months ago #67426 by Mazi
At the test system you can simply import the database backup and then change config.php database settings so that the test system grabs the data from the newly imported database for testing.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 4 months ago #67481 by lister171254
I'm clearly missing something here. I'm running V1.91 on Linux with mysql and Apache.

So far I have

1) a brand new web environment, create empty db with user and correct access rights, import the export via Mysql Administrator to the schema I just created. Result is that I get an "Unable to connect" error in Firefox

2) a brand new web environment, create empty db with user and correct access rights. Run the install script and then import the export via Mysql Administrator to the same schema I created during this step. Result is that I get an "Unable to connect" error in Firefox

Thanks

Please Log in to join the conversation.

More
5 years 4 months ago #67489 by Mazi
At the exported DB, what did you use as:
a) database name
b) database prefix

Please also post your DB settings from config.php.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 3 months ago - 5 years 3 months ago #67550 by lister171254

File Attachment:

File Name: config.php.txt
File Size:4 KB

I've exported/dumped the DB as follows:

1) Via the Full DB export in LimeSurvey
2) via the standard mysql dump

Results for both are the same.

When I import, I've tried a new schema or using an existing schema, I've successfully connected via the command line using the credentials in the attached config.php

Set debug to 1, but that doesn't seem to log to any of the obvious places.


Thanks
Attachments:
Last Edit: 5 years 3 months ago by c_schmitz.

Please Log in to join the conversation.

More
5 years 3 months ago #67558 by Mazi
No attachment :-(


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 3 months ago #67573 by lister171254
Sorry, with time difference I'm not at work anymore

BTW, I don't think the upload accepts php file, so renamed it to .txt file and then edited the message. Not sure if that's the problem.

Will paste the whole file in the message.
Cheers

Please Log in to join the conversation.

More
5 years 3 months ago #67586 by Mazi
You are right, .php files are not allowed (for security reasons).
Simply copy-paste those settings.

In general the settings should match at both systems, otherwise the system will be looking at the wriong DB/tables.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

More
5 years 3 months ago - 5 years 3 months ago #67661 by lister171254
As usual, the problem is in the chair:-)

I had the wrong database in the config file

I've now connected to the restored DB, but cannot see the Survey.

After dropping the schema and re-importing the full database dump generated from within Limesurvey I now get the message that
The LimeSurvey database does exist but it seems to be empty. Please run the install script to create the necessary tables.


So decided to start from scratch

1) Installed new instance : OK
2) Imported full dump exported from Limesurvey : OK
3) Cannot see the survey as the full export only contains the attached; no survey table as far as I can see; everything is prefixed by v1_


Attachments:
Last Edit: 5 years 3 months ago by lister171254. Reason: more info

Please Log in to join the conversation.

Imprint                   Privacy policy         General Terms & Conditions         Revocation information and revocation form