Closed (won't fix)
Project:
Backup and Migrate
Version:
7.x-2.x-dev
Component:
Miscellaneous
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
13 May 2011 at 13:35 UTC
Updated:
9 Nov 2014 at 15:01 UTC
Jump to comment: Most recent
Comments
Comment #1
tuccio commentedThe SQLite database is just a single file located in your filesystem (by default it is /sites/default/files/.ht.sqlite) so in order to backup the db all you have to do is copy that single file. To find the location of the SQLite file in case you changed the default path, you can look at settings.php.
Comment #2
raulmuroc commentedMaybe this should be a group discussion.
Ok, i know how to backup and restore = copy and paste. But what I have want to modify it through phpmyadmin? Because host provider doesn't detect it. Is there another appart of: http://drupal.org/project/dbtng_migrator converting to mysql, modifying, converting to sqlite with the risk it entails of losing data, bad conversion, etc?
Comment #3
raulmuroc commentedComment #4
Talkless commentedI would like to suggest reconsidering SQLite backup support.
It's not that simple. First of all, it's not single file all the times, it creates -journal or -wal files during transactions. And even if you try to copy journal/WAL files also, it's not quite safe either, because.. well... database is in changing state.
Please see section 1.2 in How To Corrupt An SQLite Database File:
So, if you have very simple shared PHP hosting, without access to shell, and without possibility to stop web server to make sure no new transactions will be started, it is dangerous to rely on simple file copy.
As a side note, if someone wants to make atomic SQLite dump, can try to use this snippet:
But most probably shell_exec() / exec() will disabled in shared hosting...
Another alternative would be opening (NORMAL/EXCLUSIVE ?) transaction in PDO and copying a file during transaction?