I expect it to work. What could happen is that the underlying nodejs will be installed in a newer version. Its dependencies might not be compatible with frontail resp. its required npm modules.
But this is nothing that can be influenced by using the menu.
If you have a tested backup (i.e. you know how to restore from it and you’ve shown it to be complete), that fear can go away. If things blow up you are only out a little bit of time to go back to where you started.
Limping along patching this existing system is probably something to fear more than starting fresh and importing.
If you don’t have a backup than that’s really something to make you afraid and you shouldn’t even be contemplating mucking around with the system.
That’s a variant of the XY problem then here. You’re asking for a solution to a wrongly defined problem.
On a Pi it’s soooo much easier and - unlike what you’re asking for here so far- without(!) risk to install a second fresh system on another SD card and just try.
You can fall back to the old card at any time.
I would argue that the problem statement of having an option to purge frontail and reinstall is not given yet. The why can have multiple reasons, agree.
yes that was just my idea, to get a fresh installation on another sdcard and transfer the backup there.
And once backup is through on new sd card i will defintiely check this out to have a conclusion.
frontailBase="$(npm list -g | head -n 1)/node_modules/frontail"
if ! (id -u ${frontailUser} &> /dev/null || cond_redirect useradd --groups "${username:-openhabian}",openhab -s /bin/bash -d /var/tmp ${frontailUser}); then echo "FAILED (adduser)"; return 1; fi
echo -n "$(timestamp) [openHABian] Installing openHAB Log Viewer (frontail)... "
if [[ -d $frontailBase ]]; then
cond_echo "Removing any old installations... "
cond_redirect npm uninstall -g frontail
fi
This is part of the openhabian-code that installs frontail. Before the installation is done it is checked if frontail is already installed. In case it is installed it will be removed before installing it again.
So the command to deinstall frontail on command line using npm would be: npm uninstall -g frontail
Knowing the location where is is installed ( see the other post ) you can check if it is removed.
You don’t. This will only backup the OH config but not the system.
But it’s the OS, the system under and around OH you’re putting at risk when messing with frontail. Or any of the upgrades you have made.
XY again.
It’s one way of exporting the OH config, yes (btw there’s a menu option, too).
Name it initial.zip and put it on the boot partition before you boot from your fresh SD to get it auto-imported on install.
However you said you use this to backup your system, that’s what my response was to.
You don’t backup your system so today you will have no means of restoring it should your attempts to remove frontail cause any damage.
Ok i get your point. Thanks for clarification.
Re initial.zip: so that means if i copy it to boot, it picks it up automatically on reboot?
I would have copied it to /var/lib/openhab/backups and used menu 51.
Not what I meant. Like @mstormi said, you are mucking around with your operating system. You have a non-zero chance that something will go wrong and you’ll end up with a non-bootable SD card. If that happens, you’ll want a backup of the whole SD card so you can simply plug in that card and try again, taking note not to do what you just did to ruin the system the first time.
If you have a full backup of the whole system that is tested and known to be complete and uncorrupted, you are free to experiment with abandon. If you destroy everything, you are only a quick SD card swap away from being back where you started.
Because I’m a masochist How can I install that shiny Frontail. I didn’t found documentation anywhere.
My use case: I develop add-on with IntelliJ (because unable to get Eclipse working after 3 days). I’ve downloaded OH 4.1 snapshot to my Windows 10, unzipped it and running it using start.bat. I like to view the logs at the same time as I give commands to OH in console (so I can’t run log:tail at the same time).
Everything works like a charm in openHabian, but my dev env is Windows. Or should I install openHabian on virtual machine in my Windows PC and use that as an test environment?
It would be far easier to use powershell to tail the logs. See How to watch and look through logging which has both Linux and Windows commands. Or you can tail the logs from an WSL2 terminal.
Beyond that, Frontail is a third party service so details on how to install it on Windows can be found at Frontail’s sites.