Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
3.2.30 adding plugins internal server error
#1
Hi Dan, hit a snag with a SIP rebuild I am doing..
new build of Raspian, with current (3.2.30) of SIP tried Wheezy, Jessie and Stretch, same result on all....configured language as English and saved and it complained unable to restart and said to restart via command line - which I did.
then browsed more plug ins and selected relay_board and on clicking install I get "internal server error" in firefox. In IE I get "cant reach this page"
I tried a couple of different plug ins with same outcome...

appears to be a permanent, repeatable fault. Hoping you are able to resolve this please....shout out if you need more info.

Same result even if I don't select language first..
console port output is shown below....


[email=pi@raspberrypi:~$]pi@raspberrypi:~$[/email] cd SIP
[email=pi@raspberrypi:~/SIP$]pi@raspberrypi:~/SIP$[/email] sudo python sip.py
ALARM from Example_Sender!: Just and example!
plugins loaded:
  mobile_app
  plugin_manager
  signaling_examples
  system_update
zones changed
[0, 0, 0, 0, 0, 0, 0, 0]
Starting timing loop
http://0.0.0.0:80/
10.19.2.16:63381 - - [11/Sep/2017 14:58:49] "HTTP/1.1 GET /" - 303 See Other
10.19.2.16:63381 - - [11/Sep/2017 14:58:51] "HTTP/1.1 GET /login" - 200 OK
10.19.2.16:63381 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/bootstrap-3.3.7/css/bootstrap.min.css" - 200 10.19.2.16:63386 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/themes/basic/base.css" - 200
10.19.2.16:63385 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/bootstrap-timepicker/css/bootstrap-timepicker.min.css" - 200 
10.19.2.16:63387 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/scripts/jquery-3.1.0.min.js" - 200
10.19.2.16:63388 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/bootstrap-3.3.7/js/bootstrap.min.js" - 200
10.19.2.16:63389 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/bootstrap-timepicker/js/bootstrap-timepicker.js" - 200
10.19.2.16:63385 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/scripts/behaviors.js" - 200 10.19.2.16:63388 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/scripts/intervalSelect.js" - 200
10.19.2.16:63386 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/scripts/schedule.js" - 200
10.19.2.16:63387 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/images/favicon-16x16.png" - 200
10.19.2.16:63381 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/themes/basic/logo.png" - 200
10.19.2.16:63387 - - [11/Sep/2017 14:58:52] "HTTP/1.1 GET /static/themes/basic/grass.jpg" - 200
someone logged in
10.19.2.16:63401 - - [11/Sep/2017 14:59:05] "HTTP/1.1 POST /login" - 303 See Other
10.19.2.16:63401 - - [11/Sep/2017 14:59:09] "HTTP/1.1 GET /" - 200 OK
10.19.2.16:63401 - - [11/Sep/2017 14:59:09] "HTTP/1.1 GET /static/themes/basic/home.png" - 200 10.19.2.16:63404 - - [11/Sep/2017 14:59:09] "HTTP/1.1 GET /static/themes/basic/on.png" - 200
10.19.2.16:63405 - - [11/Sep/2017 14:59:09] "HTTP/1.1 GET /api/status" - 200 OK
10.19.2.16:63401 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /vs" - 200 OK
10.19.2.16:63404 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/themes/basic/base.css" - 304 Not Modified10.19.2.16:63405 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/bootstrap-timepicker/css/bootstrap-timepicker.min.css" - 304 Not Modified10.19.2.16:63415 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/bootstrap-3.3.7/js/bootstrap.min.js" - 304 Not Modified
10.19.2.16:63401 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/bootstrap-3.3.7/css/bootstrap.min.css" - 304 Not Modified
10.19.2.16:63414 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/scripts/jquery-3.1.0.min.js" - 304 Not Modified10.19.2.16:63416 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/bootstrap-timepicker/js/bootstrap-timepicker.js" - 304 Not Modified

10.19.2.16:63415 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/scripts/intervalSelect.js" - 304 Not Modified
10.19.2.16:63404 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/scripts/behaviors.js" - 304 Not Modified
10.19.2.16:63405 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/scripts/schedule.js" - 304 Not Modified
 10.19.2.16:63414 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/images/favicon-16x16.png" - 304 Not Modified
10.19.2.16:63405 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/themes/basic/grass.jpg" - 304 Not Modified
10.19.2.16:63401 - - [11/Sep/2017 14:59:17] "HTTP/1.1 GET /static/themes/basic/logo.png" - 304 Not Modified
10.19.2.16:63401 - - [11/Sep/2017 14:59:22] "HTTP/1.1 GET /vo" - 200 OK
10.19.2.16:63401 - - [11/Sep/2017 14:59:22] "HTTP/1.1 GET /static/themes/basic/collapsed.png" - 200
10.19.2.16:63401 - - [11/Sep/2017 14:59:22] "HTTP/1.1 GET /static/themes/basic/expanded.png" - 200
10.19.2.16:63427 - - [11/Sep/2017 14:59:37] "HTTP/1.1 GET /" - 200 OK
10.19.2.16:63427 - - [11/Sep/2017 14:59:37] "HTTP/1.1 GET /static/themes/basic/home.png" - 304 Not Modified10.19.2.16:63428 - - [11/Sep/2017 14:59:37] "HTTP/1.1 GET /static/themes/basic/on.png" - 304 Not Modified
10.19.2.16:63429 - - [11/Sep/2017 14:59:38] "HTTP/1.1 GET /api/status" - 200 OK
10.19.2.16:63427 - - [11/Sep/2017 14:59:39] "HTTP/1.1 GET /static/themes/basic/off.png" - 200
10.19.2.16:63427 - - [11/Sep/2017 14:59:43] "HTTP/1.1 GET /plugins" - 200 OK
10.19.2.16:63428 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/themes/basic/base.css" - 304 Not Modified10.19.2.16:63427 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/bootstrap-3.3.7/css/bootstrap.min.css" - 304 Not Modified10.19.2.16:63434 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/scripts/jquery-3.1.0.min.js" - 304 Not Modified10.19.2.16:63429 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/bootstrap-timepicker/css/bootstrap-timepicker.min.css" - 304 Not Modified
10.19.2.16:63435 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/bootstrap-3.3.7/js/bootstrap.min.js" - 304 Not Modified

10.19.2.16:63436 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/bootstrap-timepicker/js/bootstrap-timepicker.js" - 304 Not Modified
10.19.2.16:63429 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/scripts/intervalSelect.js" - 304 Not Modified10.19.2.16:63427 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/scripts/schedule.js" - 304 Not Modified10.19.2.16:63428 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/scripts/behaviors.js" - 304 Not Modified
10.19.2.16:63434 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/images/favicon-16x16.png" - 304 Not Modified

10.19.2.16:63429 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/themes/basic/grass.jpg" - 304 Not Modified10.19.2.16:63427 - - [11/Sep/2017 14:59:44] "HTTP/1.1 GET /static/themes/basic/logo.png" - 304 Not Modified
10.19.2.16:63427 - - [11/Sep/2017 14:59:47] "HTTP/1.1 GET /browse-plugins" - 200 OK
Install qdict:  <Storage {'relay_board': u'on'}>
relay_board
Traceback (most recent call last):
  File "/home/pi/SIP/web/application.py", line 239, in process
    return self.handle()
  File "/home/pi/SIP/web/application.py", line 230, in handle
    return self._delegate(fn, self.fvars, args)
  File "/home/pi/SIP/web/application.py", line 423, in _delegate
    return handle_class(cls)
  File "/home/pi/SIP/web/application.py", line 399, in handle_class
    return tocall(*args)
  File "/home/pi/SIP/plugins/plugin_manager.py", line 156, in GET
    response = urllib.urlopen('https://raw.github.com/Dan-in-CA/SIP_plugins/master/'+p+'/'+p+'.manifest')
  File "/usr/lib/python2.7/urllib.py", line 86, in urlopen
    return opener.open(url)
  File "/usr/lib/python2.7/urllib.py", line 207, in open
    return getattr(self, name)(url)
  File "/usr/lib/python2.7/urllib.py", line 450, in open_https
    return self.http_error(url, fp, errcode, errmsg, headers)
  File "/usr/lib/python2.7/urllib.py", line 371, in http_error
    result = method(url, fp, errcode, errmsg, headers)
  File "/usr/lib/python2.7/urllib.py", line 664, in http_error_301
    return self.http_error_302(url, fp, errcode, errmsg, headers, data)
  File "/usr/lib/python2.7/urllib.py", line 634, in http_error_302
    data)
  File "/usr/lib/python2.7/urllib.py", line 660, in redirect_internal
    return self.open(newurl)
  File "/usr/lib/python2.7/urllib.py", line 207, in open
    return getattr(self, name)(url)
  File "/usr/lib/python2.7/urllib.py", line 436, in open_https
    h.endheaders(data)
  File "/usr/lib/python2.7/httplib.py", line 958, in endheaders
    self._send_output(message_body)
  File "/usr/lib/python2.7/httplib.py", line 818, in _send_output
    self.send(msg)
  File "/usr/lib/python2.7/httplib.py", line 780, in send
    self.connect()
  File "/usr/lib/python2.7/httplib.py", line 1165, in connect
    self.sock = ssl.wrap_socket(sock, self.key_file, self.cert_file)
  File "/usr/lib/python2.7/ssl.py", line 381, in wrap_socket
    ciphers=ciphers)
  File "/usr/lib/python2.7/ssl.py", line 143, in __init__
    self.do_handshake()
  File "/usr/lib/python2.7/ssl.py", line 305, in do_handshake
    self._sslobj.do_handshake()
IOError: [Errno socket error] [Errno 1] _ssl.c:504: error:140773E8:SSL routines:SSL23_GET_SERVER_HELLO:reason(1000)
10.19.2.16:63427 - - [11/Sep/2017 14:59:56] "HTTP/1.1 GET /inst-plugins" - 500 Internal Server Error
10.19.2.16:63427 - - [11/Sep/2017 14:59:56] "HTTP/1.1 GET /favicon.ico" - 303 See Other
10.19.2.16:63427 - - [11/Sep/2017 14:59:56] "HTTP/1.1 GET /favicon.ico" - 303 See Other
10.19.2.16:63427 - - [11/Sep/2017 14:59:56] "HTTP/1.1 GET /" - 200 OK
[email=^Cpi@raspberrypi:~/SIP$]^Cpi@raspberrypi:~/SIP$[/email]

Hi Dan...
I grabbed another 3.2.28 SIP I have - updated it to 3.2.30....now it has same issue as described above. Sad
So the issue definitely appears related to the 3.2.30 version (based on my experiences)

Note to self - take an image of the current version before upgrading and breaking it...doh! Sad
Reply
#2
I tried installing the relay_board plugin here on Jessie with SIP version 3.2.30 and it installed with no problem.

First off, the auto-restart SIP uses is dependent on having SIP set up to start automatically on boot. For Jessie and stretch it means having a systemd script installed as described in the SIP documentation wiki under "The recommended method":
https://github.com/Dan-in-CA/SIP/wiki/Installation

If you stop SIP with "systemctl stop sip" and start SIP from the command line you will be able to see any error messages but you will need to restart SIP manually as you have done.


As far as the error you are getting when you try to install plugins. It looks like some sort of security problem. The IOError in the console log you provided has some limes that mention "ssl" which indicates it is security related. I am not sure how to get around this.

You may be able to install the plugin manually to get things working. The Relay_board plugin consists of 3 files from the SIP plugins GitHub repository:
https://github.com/Dan-in-CA/sip_plugins

To install the plugin manually try:

Log into SIP/plugins/manifests
then issue the command
wget https://raw.github.com/Dan-in-CA/SIP_plu...d.manifest

use "cd .." to go up one level to SIP/plugins and issue the command
wget https://raw.github.com/Dan-in-CA/SIP_plu...y_board.py

Then log into SIP/templates and issue the command
wget https://raw.github.com/Dan-in-CA/SIP_plu...board.html

The above steps should download the necessary files to their proper locations. You should be able to enable the plugin from the plugins page.

Let me know how it goes.

Dan
Reply
#3
(2017 Sep 11, 04:00 PM)dan Wrote: I tried installing the relay_board plugin here on Jessie with SIP version 3.2.30 and it installed with no problem.

First off, the auto-restart SIP uses is dependent on having SIP set up to start automatically on boot. For Jessie and stretch it means having a systemd script installed as described in the SIP documentation wiki under "The recommended method":
https://github.com/Dan-in-CA/SIP/wiki/Installation

If you stop SIP with "systemctl stop sip" and start SIP from the command line you will be able to see any error messages but you will need to restart SIP manually as you have done.


As far as the error you are getting when you try to install plugins. It looks like some sort of security problem. The IOError in the console log you provided has some limes that mention "ssl" which indicates it is security related. I am not sure how to get around this.

You may be able to install the plugin manually to get things working. The Relay_board plugin consists of 3 files from the SIP plugins GitHub repository:
https://github.com/Dan-in-CA/sip_plugins

To install the plugin manually try:

Log into SIP/plugins/manifests
then issue the command
wget https://raw.github.com/Dan-in-CA/SIP_plu...d.manifest

get this in return.....
pi@SIPPI:~/SIP/plugins/manifests$ wget https://raw.github.com/Dan-in-CA/SIP_plu...d.manifest

--2017-09-12 05:34:49--  https://raw.github.com/Dan-in-CA/SIP_plu...d.manifest
Resolving raw.github.com (raw.github.com)... 151.101.80.133
Connecting to raw.github.com (raw.github.com)|151.101.80.133|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://raw.githubusercontent.com/Dan-in...d.manifest [following]
--2017-09-12 05:34:49--  https://raw.githubusercontent.com/Dan-in...d.manifest
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 2001:8002:e32:f002::f5ff, 61.9.133.209
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|2001:8002:e32:f002::f5ff|:443... connected.
GnuTLS: A TLS fatal alert has been received.
GnuTLS: received alert [0]: Close notify
Unable to establish SSL connection.
pi@SIPPI:~/SIP/plugins/manifests$

Not quite what I was expecting........do I proceed with the next two...let's try the next one...


use "cd .." to go up one level to SIP/plugins and issue the command
wget https://raw.github.com/Dan-in-CA/SIP_plu...y_board.py

and I get
pi@SIPPI:~/SIP/plugins/manifests$ cd ..

pi@SIPPI:~/SIP/plugins$ wget https://raw.github.com/Dan-in-CA/SIP_plu...y_board.py
--2017-09-12 05:36:56--  https://raw.github.com/Dan-in-CA/SIP_plu...y_board.py
Resolving raw.github.com (raw.github.com)... 151.101.80.133
Connecting to raw.github.com (raw.github.com)|151.101.80.133|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://raw.githubusercontent.com/Dan-in...y_board.py [following]
--2017-09-12 05:36:56--  https://raw.githubusercontent.com/Dan-in...y_board.py
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 2001:8002:e32:f002::f5ff, 61.9.133.209
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|2001:8002:e32:f002::f5ff|:443... connected.
GnuTLS: A TLS fatal alert has been received.
GnuTLS: received alert [0]: Close notify
Unable to establish SSL connection.
pi@SIPPI:~/SIP/plugins$

I smell an SSL rat......rebooting my router and re-checking...

Then log into SIP/templates and issue the command
wget https://raw.github.com/Dan-in-CA/SIP_plu...board.html

The above steps should download the necessary files to their proper locations. You should be able to enable the plugin from the plugins page.

Let me know how it goes.

Dan
Reply
#4
(2017 Sep 12, 05:38 AM)draggaj Wrote: [quote pid='439' dateline='1505145615']
Hi Dan,
This issue appears to be (my) network or ISP related...both Pi's are connected via Ethernet to my local network and NBN FTTN /Telstra BigPond Router....and consistently fail as described above.

I then redirected one of the Pis Wifi to my mobile phone hotspot and this worked perfectly, either using the manual commands you provided (thanks for those) as well as using the GUI.

A google on this issue shows that it has been popping up since at least 2008 for various git related apps on Pi and various other debian devices....one developer even changed wget updates to curl based to get around the issue.....bit extreme.

At this point, I am no closer to finding out what on my local network is preventing wget's / SSL working...it worked a few weeks ago. Over the same infrastructure I also run a company based VPN client without issue and also happily use SSL based brwoser session without a problem....
When time permits I do a bit more diagnostics on this. I've got the (rather messy) workaround that I can use, but need to get to the bottom of this.

So apologies for taking your time on this....and of course, if I find the root cause, I'll call it out.

If there are other NBN FTTN /Telstra BigPond users out there using SIP, I'd be interested if they too have any issues like this at the moment...
Thanks
Bob

[/quote]
Reply
#5
Hi Bob,

Thanks for the feedback. No need to apologize security is a good thing.

I'm sure This information will help other users..

Dan
Reply


Forum Jump:


Users browsing this thread: 4 Guest(s)