On Saturday, October 8, 2016 at 8:23:56 PM UTC-7, Sam Roza wrote:
>
>
>
> On Saturday, October 8, 2016 at 6:57:49 PM UTC-7, mwall wrote:
>>
>> btw, here it is with a better sed expression for the filter:
>>
>> ngrep -l -q -d eth0 '0004a369e0d6' | sed '/mac=/!d' | xargs -n 1 curl 
>> http://localhost:9999 -s -d
>>
>> m
>>
>
> Ah yes. That filter is a bit more efficient, isn't it? I've confirmed it 
> works, too.
>
> Unfortunately, I get nothing but empty queue messages in syslog. :
>
> ~~~
> root@raspberrypi:/home/pi# ngrep -l -q -d eth0 '0004a369e0d6' | sed 
> '/mac=/!d' | xargs -n 1 curl http://localhost:9999 -s -d
> ~~~
>
> Oct  8 20:09:20 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:09:30 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:09:40 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:09:50 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:09:50 raspberrypi rsyslogd-2007: action 'action 17' suspended, 
> next retry is Sat Oct  8 20:11:20 2016 [try http://www.rsyslog.com/e/2007 
> ]
> Oct  8 20:10:00 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:10:10 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:10:20 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:10:30 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:10:40 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:10:50 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:11:00 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:11:10 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:11:20 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:11:20 raspberrypi rsyslogd-2007: action 'action 17' suspended, 
> next retry is Sat Oct  8 20:12:50 2016 [try http://www.rsyslog.com/e/2007 
> ]
> Oct  8 20:11:30 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:11:40 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:11:50 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:12:00 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:12:10 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:12:20 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
> Oct  8 20:12:30 raspberrypi weewx[676]: interceptor: MainThread: empty 
> queue
>
> I rebooted, just to be sure something wasn't being stupid, and it made no 
> difference. I did try to unbuffer curl, but that didn't work, either. 
>

And then, all of a suddent, things got weird...

I looked up and all this data was scrolling by on the screen:

~~~
Oct  8 20:21:50 raspberrypi rsyslogd-2007: action 'action 17' suspended, 
next retry is Sat Oct  8 20:23:20 2016 [try http://www.rsyslog.com/e/2007 ]
Oct  8 20:22:00 raspberrypi weewx[676]: interceptor: MainThread: empty queue
Oct  8 20:22:10 raspberrypi weewx[676]: interceptor: MainThread: empty queue
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: MainThread: raw data: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: MainThread: raw 
packet: {'wd.1d0.0004a369e0d6': 135.0, 'id.1d0.0004a369e0d6': '90', 
'wg.1d0.0004a369e0d6': 0.9, 'ch.1d0.0004a369e0d6': '1', 
'pwr.1d0.0004a369e0d6': '0', 'av.1d0.0004a369e0d6': '0', 'dateTime': 
1475983337, 'ws.1d0.0004a369e0d6': 0.0, 'rid.1d0.0004a369e0d6': 'd0', 
'mac.1d0.0004a369e0d6': '0004a369e0d6', 'p.1d0.0004a369e0d6': '1', 
'gw.1d0.0004a369e0d6': '0', 'usUnits': 17}
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: MainThread: mapped 
packet: {'windDir': 135.0, 'windSpeed': 0.0, 'windGust': 0.9, 'usUnits': 
17, 'dateTime': 1475983337}
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=34&ttr=1&ot=20.9&ch=3&p=1
Oct  8 20:22:16 raspberrypi weewx[676]: reportengine: Running reports for 
latest time in the database.
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: MainThread: raw data: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=34&ttr=1&ot=20.9&ch=3&p=1
Oct  8 20:22:16 raspberrypi weewx[676]: reportengine: Running report 
StandardReport
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: MainThread: raw 
packet: {'mac.3e6.0004a369e0d6': '0004a369e0d6', 'oh.3e6.0004a369e0d6': 
34.0, 'htr.3e6.0004a369e0d6': '0', 'rid.3e6.0004a369e0d6': 'e6', 
'ot.3e6.0004a369e0d6': 20.9, 'id.3e6.0004a369e0d6': '84', 'dateTime': 
1475983337, 'pwr.3e6.0004a369e0d6': '0', 'cz.3e6.0004a369e0d6': '2', 
'ch.3e6.0004a369e0d6': '3', 'ttr.3e6.0004a369e0d6': '1', 
'p.3e6.0004a369e0d6': '1', 'usUnits': 17}
Oct  8 20:22:16 raspberrypi weewx[676]: interceptor: MainThread: mapped 
packet: {'outHumidity': 34.0, 'outTemp': 20.9, 'usUnits': 17, 'dateTime': 
1475983337}
Oct  8 20:22:16 raspberrypi weewx[676]: reportengine: Found configuration 
file /etc/weewx/skins/Standard/skin.conf for report StandardReport
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: MainThread: raw data: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: MainThread: raw 
packet: {'wd.1d0.0004a369e0d6': 135.0, 'id.1d0.0004a369e0d6': '90', 
'wg.1d0.0004a369e0d6': 0.9, 'ch.1d0.0004a369e0d6': '1', 
'pwr.1d0.0004a369e0d6': '0', 'av.1d0.0004a369e0d6': '0', 'dateTime': 
1475983337, 'ws.1d0.0004a369e0d6': 0.0, 'rid.1d0.0004a369e0d6': 'd0', 
'mac.1d0.0004a369e0d6': '0004a369e0d6', 'p.1d0.0004a369e0d6': '1', 
'gw.1d0.0004a369e0d6': '0', 'usUnits': 17}
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: MainThread: mapped 
packet: {'windDir': 135.0, 'windSpeed': 0.0, 'windGust': 0.9, 'usUnits': 
17, 'dateTime': 1475983337}
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=8e&rid=63&pwr=0&or=0&uvh=0&uv=365&ch=1&p=1
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: MainThread: raw data: 
mac=0004a369e0d6&id=8e&rid=63&pwr=0&or=0&uvh=0&uv=365&ch=1&p=1
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: MainThread: raw 
packet: {'uvh.163.0004a369e0d6': '0', 'ch.163.0004a369e0d6': '1', 
'pwr.163.0004a369e0d6': '0', 'p.163.0004a369e0d6': '1', 
'uv.163.0004a369e0d6': '365', 'dateTime': 1475983338, 
'mac.163.0004a369e0d6': '0004a369e0d6', 'id.163.0004a369e0d6': '8e', 
'rid.163.0004a369e0d6': '63', 'or.163.0004a369e0d6': '0', 'usUnits': 17}
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: MainThread: mapped 
packet: {'uv': '365', 'usUnits': 17, 'dateTime': 1475983338}
Oct  8 20:22:17 raspberrypi weewx[676]: engine: Main loop exiting. Shutting 
engine down.
Oct  8 20:22:17 raspberrypi weewx[676]: engine: Shutting down StdReport 
thread
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=34&ttr=1&ot=20.8&ch=3&p=1
Oct  8 20:22:17 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=34&ttr=1&ot=20.7&ch=3&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=c2&pv=0&lb=0&ac=0&reg=1009&lost=0000&baro=1004&ptr=0&wfor=3&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=8e&rid=63&pwr=0&or=0&uvh=0&uv=365&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=35&ttr=1&ot=20.3&ch=3&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=8e&rid=63&pwr=0&or=0&uvh=0&uv=365&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=c2&pv=0&lb=0&ac=0&reg=1009&lost=0000&baro=1004&ptr=0&wfor=3&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=35&ttr=1&ot=20.2&ch=3&p=1
Oct  8 20:22:18 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:19 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=0&cz=2&oh=35&ttr=1&ot=20.0&ch=3&p=1
Oct  8 20:22:19 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:19 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=8e&rid=63&pwr=0&or=0&uvh=0&uv=365&ch=1&p=1
Oct  8 20:22:20 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=c2&pv=0&lb=0&ac=0&reg=1009&lost=0000&baro=1004&ptr=0&wfor=3&p=1
Oct  8 20:22:20 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:20 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=84&rid=e6&pwr=0&htr=1&cz=2&oh=36&ttr=1&ot=19.8&ch=3&p=1
Oct  8 20:22:20 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=90&rid=d0&pwr=0&gw=0&av=0&wd=135&wg=0.9&ws=0.0&ch=1&p=1
Oct  8 20:22:20 raspberrypi weewx[676]: interceptor: ServerThread: POST: 
mac=0004a369e0d6&id=8e&rid=63&pwr=0&or=0&uvh=0&uv=365&ch=1&p=1
Oct  8 20:22:24 raspberrypi weewx[676]: cheetahgenerator: Generated 14 
files for report StandardReport in 7.34 seconds
Oct  8 20:22:26 raspberrypi weewx[676]: genimages: Generated 12 images for 
StandardReport in 1.31 seconds
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: copied 9 files to 
/var/www/weewx
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: Running report FTP
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: Found configuration 
file /etc/weewx/skins/Ftp/skin.conf for report FTP
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: FTP upload not 
requested. Skipped.
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: Running report RSYNC
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: Found configuration 
file /etc/weewx/skins/Rsync/skin.conf for report RSYNC
Oct  8 20:22:26 raspberrypi weewx[676]: reportengine: rsync upload not 
requested. Skipped.
Oct  8 20:22:26 raspberrypi weewx[676]: engine: StdReport thread has been 
terminated
Oct  8 20:22:26 raspberrypi weewx[676]: restx: Shut down CWOP thread.
Oct  8 20:22:26 raspberrypi weewx[676]: restx: Shut down Wunderground-PWS 
thread.
Oct  8 20:22:26 raspberrypi weewx[676]: interceptor: MainThread: shutting 
down server thread
Oct  8 20:22:26 raspberrypi weewx[676]: engine: Caught unrecoverable 
exception in engine:
Oct  8 20:22:26 raspberrypi weewx[676]:     ****  unsupported operand 
type(s) for +=: 'float' and 'str'
Oct  8 20:22:26 raspberrypi weewx[676]:     ****  Traceback (most recent 
call last):
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/engine.py", line 859, in main
Oct  8 20:22:26 raspberrypi weewx[676]:     ****      engine.run()
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/engine.py", line 185, in run
Oct  8 20:22:26 raspberrypi weewx[676]:     ****     
 self.dispatchEvent(weewx.Event(weewx.NEW_LOOP_PACKET, packet=packet))
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/engine.py", line 218, in dispatchEvent
Oct  8 20:22:26 raspberrypi weewx[676]:     ****      callback(event)
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/engine.py", line 546, in new_loop_packet
Oct  8 20:22:26 raspberrypi weewx[676]:     ****     
 self.accumulator.addRecord(event.packet, self.loop_hilo)
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/accum.py", line 240, in addRecord
Oct  8 20:22:26 raspberrypi weewx[676]:     ****      func(self, record, 
obs_type, add_hilo)
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/accum.py", line 310, in add_value
Oct  8 20:22:26 raspberrypi weewx[676]:     ****     
 self[obs_type].addSum(val)
Oct  8 20:22:26 raspberrypi weewx[676]:     ****    File 
"/usr/share/weewx/weewx/accum.py", line 87, in addSum
Oct  8 20:22:26 raspberrypi weewx[676]:     ****      self.sum     += val
Oct  8 20:22:26 raspberrypi weewx[676]:     ****  TypeError: unsupported 
operand type(s) for +=: 'float' and 'str'
Oct  8 20:22:26 raspberrypi weewx[676]:     ****  Exiting.
~~~

and here was the ngrep-sed-curl screen:

~~~
 root@raspberrypi:/home/pi# ngrep -l -q -d eth0 '0004a369e0d6' | sed 
'/mac=/!d' | xargs -n 1 curl http://localhost:9999 -s -d
OKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOKOK
~~~

Not sure what happened there...any ideas?

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to