Dunum
(Derek Mansbridge)
13 May 2018 16:34
1
Hi All
Tried to backup my data using “Setup | Backup |Create backup” but all I get is a fleeting message saying “Backup Flag Set” - nothing else!
Any thoughts?
Raspberry Pi + WD HDD running OpenEnergyMonitor.org | 9.8.27 | 2017.12.21
borpin
(Brian Orpin)
14 May 2018 09:14
2
Is this a self install or an EmonSD? Last time I looked, the backup script assumes it is an EmonPi based setup and the file paths are all hard coded.
Dunum
(Derek Mansbridge)
14 May 2018 17:41
3
borpin, thanks for your quick relpy.
Pre-built image (full version) - so I guess you’ve answered my question.
Is it possible to modify the scripts? Where are they? Is there an idiots guide to directory structure / file locations, etc. for this build?
From what I can see, my mysql database is at “/var/lib/mysql” but a quick look in “/home/pi/backup/config.cfg” suggests that this and most other things are coded to be in “/home/pi/data” - I don’t have such a folder! Is it a simple case of editing the cfg file?
borpin
(Brian Orpin)
14 May 2018 19:47
4
I knew I’d looked at this before.
I’ve just dropped a PR to try and make the backup module more general - It could do with a dev branch on this module for this work though. It is only a start to what needs done but the export script works when called from the command line. You could easily add in any other folders - was Timestore simply a folder to backup? The only other thing to watch would be that I commented out stopping the feedwriter service for the moment. Not sure if this was part of the early EmonCMS or not.
Just installed the backup module into an up to date EmonCMS installation. in preparation for an upgrade to Stretch.
First issue is that the file locations are hardcoded as /home/pi/backup. For me, this location is already in use so is not feasible. For others, the user may not be ‘pi’. This really needs to be configurable. I changed the locations I could find, but the export module will not run from the web interface. There is no message to say it is not running and has failed. There was a …
And the PR
emoncms:master
← borpin:master
opened 10:52PM - 27 Feb 18 UTC
The task is to make the backup module work on non pi systems.
I have modified… this so that the config file now resides in the php folder and is read by both the php side and the bash side. I am not sure if this is a security issue or not.
I have also added in some file exist checks for non EmonPi setups.
Phpfiwa was not backed up.
This now needs more development in identifying different base systems and reacting accordingly.
feedwriter is not stopped currently (commented out) as I don't have it installed. The service could be checked for existing & running.
As I say, just a start on this.
But no one picked it up.
The backup module is separate from the main core.
I’m not familiar with the Prebuilt image I’m afraid. My issues revolved around the install not being on a pi.
Dunum
(Derek Mansbridge)
18 May 2018 12:17
5
Hmmm. I guess I need to re-think my backup strategy.
Thanks anyway for you help.
1 Like