Cruisers Forum
 

Go Back   Cruisers & Sailing Forums > Seamanship, Navigation & Boat Handling > OpenCPN
Cruiser Wiki Click Here to Login
Register Vendors FAQ Community Calendar Today's Posts Log in

Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 14-01-2020, 06:14   #1
Registered User

Join Date: Oct 2019
Posts: 5
Opencpn 5 issue after repeated reboots on 3 Pi's

I have a working Raspberry pi for my yacht with opencpn. I have a second that is a mirror of the first and a third that I am getting openplotter to work.

After the recent storm in Ireland, our power was up and down and I discovered that all 3 lost their config and using the template to restore to last known working didn't work.

I was not at home at the time and therefore could not prevent the issue but why did opencpn lose it's working config after repeated restarts. Of course now, I will get a UPS hat or something for the main working Pi.
thecivvie is offline   Reply With Quote
Old 14-01-2020, 06:57   #2
Registered User
 
Dsanduril's Avatar

Join Date: Aug 2011
Location: Petersburg, AK
Boat: Outremer 50S
Posts: 4,229
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

I would suspect SD card corruption on the Pi' s. If the power down/up/down occurs during a boot cycle the SD card is usually toast. There's a lot of activity back and forth during start up and the file system is quite vulnerable during that process. Once startup is complete things settle down and are usually quite solid even through a power failure. But if one occurs during the boot process...
Dsanduril is offline   Reply With Quote
Old 14-01-2020, 08:56   #3
Registered User

Join Date: Jan 2018
Location: Belgium
Boat: Raider 18 Cuddy
Posts: 68
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

Better use a SSD HAT on USB
I always switch of the power of the boat, never shutdown PI first, no problem in 2 years use.

http://www.cruisersforum.com/forums/...pn-208244.html
Ben S is offline   Reply With Quote
Old 14-01-2020, 10:38   #4
Registered User

Join Date: Nov 2015
Location: Ireland
Posts: 467
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

Put a USB with a battery on your Pi and set it up to automatically shutdown when the power to the battery goes off. I have that arrangement on our boat (also in Ireland) and it’s been turned on and off frequently for three years now without problem. The battery can be very small as it only has to power the Pi for 20 seconds or so.
AedanC is offline   Reply With Quote
Old 14-01-2020, 10:40   #5
Registered User
 
pinguino's Avatar

Join Date: May 2009
Location: SE Spain
Boat: Jeanneau SO 32I
Posts: 125
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

It would be nice to add a couple of buttons in the settings to be able to create backups of the configuration file and recover it in case of accidental loss. It is a quite recurrent problem in boards like the Rpi that do not have backup batteries and it is relatively easy to disconnect them without realizing it.

Personally I have checked that errors in the SD in such cases are not as frequent as I thought but the loss of the opencpn configuration file is guaranteed.

And some users of the android version complain about the same.
pinguino is offline   Reply With Quote
Old 14-01-2020, 11:04   #6
Registered User

Join Date: Oct 2019
Posts: 5
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

Sorry, I should have said that one was on a SSD via usb cable adapter and the other 2 flash drives. I will add a battery hat to the main one. Will keep the rest off for now.

TBH, I don't know why I leave them powered up all the time
thecivvie is offline   Reply With Quote
Old 23-01-2020, 05:33   #7
Registered User
 
transmitterdan's Avatar

Join Date: Oct 2011
Boat: Valiant 42
Posts: 6,008
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

Quote:
Originally Posted by pinguino View Post
It would be nice to add a couple of buttons in the settings to be able to create backups of the configuration file and recover it in case of accidental loss. It is a quite recurrent problem in boards like the Rpi that do not have backup batteries and it is relatively easy to disconnect them without realizing it.



Personally I have checked that errors in the SD in such cases are not as frequent as I thought but the loss of the opencpn configuration file is guaranteed.



And some users of the android version complain about the same.
^^^^^ thumb thumb
transmitterdan is offline   Reply With Quote
Old 23-01-2020, 07:30   #8
cruiser

Join Date: Nov 2007
Location: Probably in an anchorage or a boatyard..
Boat: Ebbtide 33' steel cutter
Posts: 5,030
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

Quote:
Originally Posted by transmitterdan View Post
^^^^^ thumb thumb
Simple to do in node-red, hopefully somewhere down the line there'll be an online repository for handy node-red flows, plus openplotter V2 has paved the way to implement user apps, so once the dust settles could well be someone writes a few lines of code to do backups. I did it on V1 with node-red automated to once a week but the Pi is that reliable, not once had probs with SD card over must be 3 or 4 years constantly turned on onboard, haven't got round to sorting out out again. A spare SD card with the complete system copied over is the ultimate backup should the worst happen.
conachair is offline   Reply With Quote
Old 24-01-2020, 23:29   #9
Registered User
 
rooiedirk's Avatar

Join Date: Aug 2010
Location: Netherlands
Boat: Oneoff
Posts: 511
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

I made my rpi using a readonly filesystem for the / and /boot, while the /home directory is read/write but in raid-5.

This means on the system files you should never have a coruption, while the /home directory is divided over 3 partions (double data, and one recovery info)

I always just switch the power off, and up to now no problems


Here is an image of my system. Using a 16Gb SD card



https://drive.google.com/file/d/10F1...vBnOprmz_/view
__________________
Navigation is know where you are and what to do to get where you want.
But also: Know where you don't want to be and what to do to don't get there.
rooiedirk is offline   Reply With Quote
Old 26-01-2020, 06:16   #10
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,632
Images: 2
Re: Opencpn 5 issue after repeated reboots on 3 Pi's

Related. See https://opencpn.org/wiki/dokuwiki/do...linux_shutdown
rgleason is offline   Reply With Quote
Reply

Tags
enc, opencpn


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Raymarine MFD reboots theBigKahuna Marine Electronics 2 10-11-2019 07:38
Raymarine Radar reboots all the time Lagoon440Bora Marine Electronics 8 23-10-2016 18:47
Raymarine E120 Beeps, freezes and Reboots IanClarke Marine Electronics 25 20-08-2016 23:49

Advertise Here


All times are GMT -7. The time now is 05:14.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.