I'm sure you've thought about this, but I'll throw it out because not all programmers have. You want to make sure that if anything has gone wrong on startup, you don't auto overwrite any of the backups. (even if the user tries something that causes an INI change before he realizes what has happened) I had a CAD program that did that.
Announcement
Collapse
No announcement yet.
Lost ALL Devices....
Collapse
This topic is closed.
X
X
-
Originally posted by mnsandler View Postguys,
i'm working on archiving up to 5 copies of the insteon.ini. A new archive will be created after any transaction performed within the plugin...
Suggestion
- run a counter of the number of changes
- every 10 minutes (parameter?), if counter exceeds max (parameter?), create archive, else keep counting
- every 60 minutes (parameter?) or at shutdown, if counter > 0, force an archive
Not perfect, but food for thought.
Comment
-
- i don't plan on archiving anything at startup since that is when any problems with the active ini will present itself.
- a transaction is any programming task (when the UI refreshes until you get a Continue btn) that occurs within the plugin: add, remove a device or group, adding or deleting links, changing settings, etc. A transaction is not an individual cmd sent.
I would like to keep this simple: maybe we should consider a single archive per day. I don't want to over engineer this function. I still believe its the system owners responsibility to backup their homeseer configuration on a regular basis. i would consider building an event action to allow the user to schedule these archives as well.Mark
HS3 Pro 4.2.19.5
Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD
Comment
-
Originally posted by mnsandler View Post...i would consider building an event action to allow the user to schedule these archives as well.
Comment
-
I think creating a backup after every transaction would be fine. If you are not chaining anything then no need to back it up again. If it got overwirtten blank by HS crashing you would just copy over the last one.
Here is a question though. How is the .ini related to the HS db? I'm not sure why the devices go away when the .ini gets overwritten. Would the devices not still exist in HS? What if you don't have a HS backup that matches the .ini file you recover?
Comment
-
Originally posted by chadg View PostHere is a question though. How is the .ini related to the HS db? I'm not sure why the devices go away when the .ini gets overwritten. Would the devices not still exist in HS? What if you don't have a HS backup that matches the .ini file you recover?
the ini saves the insteon configuration of the devices. during startup, the plugin checks for and removes any hs device that does not exist in the ini. this is why everything gets deleted if the ini is blank. i suppose i could turn this off; but that doesn't solve the problem if you don't have a current ini to restore.
this is why you need to backup the hs database and insteon.ini together so you can restore them together from a consistent point in time. But in general, if you haven't added or deleted any devices, then any current ini will do, but you may have to reread the links and settings of the devices.
i think the ini has been a very useful storage mechanism especially with the migration from hs2 to hs3, but it does have its shortfalls.Mark
HS3 Pro 4.2.19.5
Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD
Comment
-
Originally posted by mnsandler View Post... during startup, the plugin checks for and removes any hs device that does not exist in the ini. this is why everything gets deleted if the ini is blank. ...
I am/was again toying with the idea of trying to go to HS3. However, I think this is enough for me to pause that thought. I think that the archive workaround will help a lot (particularly if you don't delete devices when it happens), but it still will require manual intervention when it happens. Right now, I am too dependent on HS2 to have it go down and not come back while I am gone.
Comment
-
Originally posted by joegr View PostCould you turn it off if the ini is missing or blank?
I am/was again toying with the idea of trying to go to HS3. However, I think this is enough for me to pause that thought. I think that the archive workaround will help a lot (particularly if you don't delete devices when it happens), but it still will require manual intervention when it happens. Right now, I am too dependent on HS2 to have it go down and not come back while I am gone.
I have been running hs3 for 2 years now, and have never lost my configuration. i make daily backups and have my hs server on a working UPS. So in the event something does happens, i can restore my homeseer database and insteon.ini from the same point in time.
from my perspective, the only reason not to migration to hs3 is if there is hs2 functionality you can't duplicate in hs3.Mark
HS3 Pro 4.2.19.5
Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD
Comment
-
Guys,
I added Beta 3.0.5.74 to the Updater.
there is a Backup Config event action, and an Configuration Changed trigger.
you can use the trigger to keep count of the changes (with a hs counter), and then backup the config when the counter hits your threshold, or you can just set a standard trigger to backup the config on a periodic basis (e.g. every day at midnight).
the backups will be insteonX.ini where X is 1 to 5 then they will recycleMark
HS3 Pro 4.2.19.5
Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD
Comment
-
Originally posted by mnsandler View PostGuys,
I added Beta 3.0.5.74 to the Updater.
there is a Backup Config event action, and an Configuration Changed trigger.
you can use the trigger to keep count of the changes (with a hs counter), and then backup the config when the counter hits your threshold, or you can just set a standard trigger to backup the config on a periodic basis (e.g. every day at midnight).
the backups will be insteonX.ini where X is 1 to 5 then they will recycle
Comment
-
any feedback on the new plugin config backup featureMark
HS3 Pro 4.2.19.5
Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD
Comment
-
Originally posted by mnsandler View Postany feedback on the new plugin config backup feature
I did notice that whenever a change occurs, insteon.ini = insteon1.ini, so in effect the feature offers 4 previous versions + the current one. I had anticipated that insteon.ini would be the equivalent of insteon0.ini.
Not significant given there are 4 previous versions.
Great feature, thanks!
Comment
-
I'll try this solution, but I think HS dropped the ball here and I'm a bit annoyed
I keep losing my .ini file and HS keeps turning off my plugins
I'm getting really annoyed at all of this. Home automation needs to be more robust than that.
Last time I complained about this, Rupp just jumped in and tried to have me troubleshoot my PC
It's clear that homeseer doesn't protect files that it's using and needs some sort of more robust config storage system.Joe (zimmer62)
BLSecurtiy, AC-RF2, RCS Serial Thermostats, RFXCOM SMarthome SwitchLinc, mcsXap, Global Cache GC100, SqueezeBox, TWA_ONKYOINTEGRA, BLLogMonitor, BLPlugins, BLRadar, BLSpeech, BLZLog.aspx, HSTouch (Windows, iPhone, iPod), USB Mimo touchscreens, VMWare Server, Vortexbox, Windows Home Server, MyMovies, Windows Media Center, X10, ZWave, and much much much more.
Comment
-
Originally posted by zimmer62 View PostI'll try this solution, but I think HS dropped the ball here and I'm a bit annoyed
I keep losing my .ini file and HS keeps turning off my plugins
I'm getting really annoyed at all of this. Home automation needs to be more robust than that.
Last time I complained about this, Rupp just jumped in and tried to have me troubleshoot my PC
It's clear that homeseer doesn't protect files that it's using and needs some sort of more robust config storage system.Mark
HS3 Pro 4.2.19.5
Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD
Comment
Comment