Stuff data from cloud back to remote? + Backups
-
Hey,
For some reason my dashboard did not come back after copying old /opt/mango to new PC.
How to diagnose / restore? Any thoughts / pointers?
Thanks,
Alex -
Hmm. How was your dashboard created? All files by default are in the /opt/mango directory, and "Dashboard Designer" or "Edit Pages" are stored in the jsonData table in the SQL database. I wonder if what happened is that the pages got lost for some reason in the jsonData table entry that track pages. I
would check the /ui/administration/json-store page to see the "UI Menu" and "UI Pages" items, and also to see if your missing pages are shown in the JSON store. If so, you can probably find a backup of the right UI Menu and Pages in a configuration backup (in jsonData item, XIDs "mangoUI-menu" and "mangoUI-pages", in
/opt/mango/backup/Mango-Configuration-*.json
) then import that., which should restore your dashboards to appearing in menus and having menu items and whatnot. -
Hi,
I will dig into the dashboard stuff as you suggest. However in the mean time I just added a new dashboard, just cut and pasted from a local xml copy.
Another issue, I think copying /opt/mango was not enough...
Getting weird errors. Guessing they are file permissions issues?
Can't create new data sources. Can't configure data sources. HTTP 500 errors?
-Alex
-
Another issue, I think copying /opt/mango was not enough...
That directory definitely contains all things configured in Mango (by default). You would have had to consciously store files elsewhere for that not to be sufficient.
There is almost certainly more information in your log file. If I had to take a shot from the hip though, the JSPs need to be recompiled which means deleting your Mango/work/jsp directory (can be done while Mango is running).
-
Hi,
I was thinking that copying the /opt/mango folder may need some permissions adjustments perhaps? I did not mean to say that the folder is not a self contained mango installation, as it certainly is.
I deleted the JSP folder. Apparently, the same errors as above still.
Which logs should I look at?
I see /opt/mango/logs
tsdb-series-74-shard-714-scan-report.....
I can post some log stuff here if you like.
As always, appreciate the help and guidance, I am learning new things all the time.
-Alex
-
Ah, sorry, I meant the ma.log file. That's the normal Mango log and usually what i mean if I'm not relative-path levels of specific. Mango/logs/ma.log and on some Windows machines Mango/bin/logs/ma.log
-
I was thinking that copying the /opt/mango folder may need some permissions adjustments perhaps?
Certainly possible. You can easily
sudo chown -R user:group /path/to/Mango
if that's the case. -
It looks like both my functional cloud mango and the remote mango we are trying to revive have root:root ownership of the /opt/mango folder... That should be OK right?
I am getting my hands on the log file here in a minute. Will edit this post.
-
The files inside the folder will matter too and so shall the user running Mango. As it sits I would wager only your root user can run Mango without having permissions issues.
If you change Mango to run under a less privileged user (better practice) you'll likely need to add that user to the dialout group so that you can use serial devices, and you'll probably need to give your Java executable the bind capability if you want to have restricted ports available for use.
-
I emailed a zip with logs to support@infiniteautomation.com
-Alex
-
Some of those errors look like you may need to add the dialout group to the user launching Mango. If you're running as the root user or have already added the 'dialout' group, then I'd wonder what operating system is this? The native library it's looking for in the
com.serotonin.util.LifecycleException: Comm configuration error. Check that your serial port DLL or libraries have been correctly installed. Could not initialize class jssc.SerialNativeInterface
log message that is spamming the ma.log you sent in should be included in the JSSC jar in Mango/lib/jssc-2.8.0.jar file.
There wasn't really much of interest in the three dated files. In one it looked like your DNS was acting up, in one it looked like there was a client error while using the dashboard designer (certainly can happen), and then one was just a normal boot.
-
Ok this thing is debian-esque:
https://www.mediawiki.compulab.com/index.php/IOT-GATE-iMX7_and_SBC-IOT-iMX7_NXP_i.MX7_SW_Resources
I will dig in.
-Alex
-
Okay. I figured this out:
(1) This is a small sort of Debian install, supported by Compulab, that is missing some Important Things.
(2) Part of this is an old (or incomplete) java that doesn't have all the bits to make Mango happy.I fixed this by:
(1) apt-get update--
Which failed, because the people at Compulab didn't register their certs right, so I had to put the cert data in manually.
(2) apt-get update worked.
(3) apt-get install java then did the business.We can now configure our data sources without the 500 error.
However, that opened up the next thing, which seems to be something odd in the serial ports for this device. Was hoping I'd have more time to figure this out, but I'll post this as another thread.
Cheers,
-Greg Linder -
Hi Greg, thanks for sharing what resolved it!