Workaround for the 5 minute timeouts


#1

Posted the details on the github site.

Just update /etc/dhcp/dhclient.conf and add the lines below. You get a temporary 1 second or so interruption but that is about all the impact the user will see @ 5 minutes. This workaround retains both the DHCP connectivity as well as the static IP.

lease {
interface "eth0";
fixed-address 192.168.254.1;
option subnet-mask 255.255.255.0;
option routers 192.168.254.1;
renew 2 2037/1/12 00:00:01;
rebind 2 2037/1/12 00:00:01;
expire 2 2037/1/12 00:00:01;
}


#2

This is great Brian! We’ll try it out tomorrow.

Rock on!

Eric


#3

Hi Brian,

After I last uploaded the BB software I did not have the time out problem, but after I upgraded that software the time out problem came back. I have not tried to upgrade again because I don't know if the upgrade has the timeout problem fixed.

Frank


#4

Hi Brian,

I have done more tests.

I added your code but it did not help when connected direct using the medialink adapters to the BB.

My Toshiba Qosmio laptop running windows xp media center edition sp3.

When connected direct everything works but I may loose video before 5 min. timeout.

At 5 min. time out everything locks up.

When laptop is connected to my wireless router I do not get 5 min. timeouts but will loose video at sometime. If I close Chrome and reconnect with cockpit everything works until the video decides to go out again.

I get the same operation as above if I use my HP Media Center PC m7680n desktop running windows xp media center edition sp3 if I go through my wireless router.

I get the same operation as above if I use my HP Pavilion Elite HPE desktop running windows 7 Home Premium if I go through my wireless router and has 5 min. timeout connected direct when using the medialink adapters to the BB.

It looks like all 3 computers act the same when connected through the router using the medialink adapters to the BB and all 3 computers act the same when connected direct using the medialink adapters to the BB.

Frank


#5

Od. The fix is outside the openrov cockpit software. So if you applied the code workaround above nothing short of rewritting the sd card image should undo it.

Can you post the results of a "ifconfig" command?


#6

Hi Brian, We have a big storm coming thru so not know when I'll get back to you


#7

Hi Brian,

The storms have gone through with no damage here.

When it comes to the software I need my hand held when doing something. How and where should I run the "ifconfig" command.

Frank


#8

after you ssh in to the ROV. Just type 'ifconfig' and cut and paste the output from that command.


#9

Hi Brian,

Here is the ifconfig output.

eth0 Link encap:Ethernet HWaddr bc:6a:29:e1:58:aa
inet addr:192.168.1.105 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::be6a:29ff:fee1:58aa/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5555 errors:0 dropped:0 overruns:0 frame:0
TX packets:10549 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:422191 (422.1 KB) TX bytes:15619859 (15.6 MB)

eth0:0 Link encap:Ethernet HWaddr bc:6a:29:e1:58:aa
inet addr:192.168.254.1 Bcast:192.168.254.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:25 errors:0 dropped:0 overruns:0 frame:0
TX packets:25 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:3680 (3.6 KB) TX bytes:3680 (3.6 KB)

Frank


#10

Thank you Brian.

This solution works as a charm!


#11

Hi Brian,

I reformatted my SD card and uploaded the BB software. I was able to get to the cockpit and was able to see the video but it was the old code. I did a manual update and got "npm ERR". I then did line 6 of the manual update instructions and got the errors below. Then I did line 7.

Error: ENOSPC, write
npm ERR! node-xmpp@0.4.5 postinstall: `browserify -d -o node-xmpp-browser.js lib/node-xmpp-browserify.js`
npm ERR! `sh "-c" "browserify -d -o node-xmpp-browser.js lib/node-xmpp-browserify.js"` failed with 1
npm ERR!
npm ERR! Failed at the node-xmpp@0.4.5 postinstall script.
npm ERR! This is most likely a problem with the node-xmpp package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! browserify -d -o node-xmpp-browser.js lib/node-xmpp-browserify.js
npm ERR! You can get their info via:
npm ERR! npm owner ls node-xmpp
npm ERR! There is likely additional logging output above.

npm ERR! System Linux 3.2.33-psp26
npm ERR! command "/opt/node/bin/node" "/opt/node/bin/npm" "install"
npm ERR! cwd /opt/openrov
npm ERR! node -v v0.8.15
npm ERR! npm -v 1.1.66
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /opt/openrov/npm-debug.log
npm ERR! not ok code 0

I now cannot get to the cockpit. So now I'm worse off then I was.

I had 2 errors that I did not save a copy of when I did the previous upgrade that had the new cockpit and it was working accept for the 5 min. timeout even after adding your fix .

I don't know what to do now.

Frank


#12

Well thats no fun. First time I've seen an error around this particular package. I will double check tomorrow to see what version of the node-xmpp I compiled against to see if there has been a breaking upgrade since then on the originating git repo. If so I can easily fix it to the working version number and get you going again. At first glance I am seeing a bunch of updates so it may be that we need to pin the library to version 0.4.0 or earlier which can be done by modifying the packages.json and specifying the particular version number.

In the meantime, you can try running 'sudo /opt/node/bin/npm install node-xmpp@0.4.0' from /opt/openrov/src folder directly. Technically is should try installing an earlier version.


#13

Hi Brian,

I tried you suggestion and did not get anywhere. I think I'll go reformat the SD card and install the image then wait to here from you.

Frank


#14

Just letting you know that I have this queued right behind a bug on the Heads Up display that I'm working. I've not forgotten.


#15

Hi,

i tried the update also yesterday, and i am in the same situation.

no cockpit anymore.

is there any news about the new image with all the updates?

frank


#16

Unfortunately my coding experience is over 25 years old. How do I go about adding this code to my system? I have looked around and cannot find that file you refer to so I'm missing a big chunk. I'm about ready to button up number 309 for wet testing and am still having to reboot the BB every 5 minutes. My BB image was loaded this last weekend so it should be the latest one.


#17

Hi John

connect to the BB using a utility like putty.exe and do SSH.

log in

User rov

Password OpenROV

Just update /etc/dhcp/dhclient.conf and add the lines below. You get a temporary 1 second or so interruption but that is about all the impact the user will see @ 5 minutes. This workaround retains both the DHCP connectivity as well as the static IP.
lease {
interface "eth0";
fixed-address 192.168.254.1;
option subnet-mask 255.255.255.0;
option routers 192.168.254.1;
renew 2 2037/1/12 00:00:01;
rebind 2 2037/1/12 00:00:01;
expire 2 2037/1/12 00:00:01;
}

#18

Is it possible to do this directly to the SD card? I dont have the BB here with me right now and I have another SD card here with the image on it.


#19

If you have a linux system and mount the SD Card you could modify that file using vi. or some other editor. I am not sure if this can be done from a windows system but maybe someone else can answer that.


#20

So far that looks like it is working like a champ. I’m approaching 30 minutes uptime with no hiccups so far.