Kitz ADSL Broadband Information
adsl spacer  
Support this site
Home Broadband ISPs Tech Routers Wiki Forum
 
     
   Compare ISP   Rate your ISP
   Glossary   Glossary
 
Please login or register.

Login with username, password and session length
Advanced search  

News:

Pages: 1 2 [3]

Author Topic: Experiments With A BT HH5 (Type B)  (Read 16449 times)

Dray

  • Kitizen
  • ****
  • Posts: 2361
Re: Experiments With A BT HH5 (Type B)
« Reply #30 on: January 31, 2016, 09:43:41 PM »

It's a bit odd that BT included a "Telnet" entry in the Port Forwarding section of the Hub interface.

No it isn't odd. It lets you forward the port to a device running a Telnet server.
Logged

William Grimsley

  • Kitizen
  • ****
  • Posts: 1489
    • Newton Poppleford Weather
Re: Experiments With A BT HH5 (Type B)
« Reply #31 on: February 01, 2016, 08:28:24 AM »

No it isn't odd. It lets you forward the port to a device running a Telnet server.

OK!
Logged

plexy

  • Reg Member
  • ***
  • Posts: 115
Re: Experiments With A BT HH5 (Type B)
« Reply #32 on: February 19, 2016, 07:25:12 AM »

There is a way to poll the HH5b for;

profile
snr up
snr down
line attn up + down
sig attn up + down (inoperative / 0 value in current firmware)
output power up + down
current sync rate up + down
attainable sync rate up + down

What may be interesting is that this can be retrieved without needing to authenticate (http://192.168.1.254/cgi/cgi_troubleshooting.js ). It does however require a HTTP request to get back, and I do note the presence of curl in the dslstats source code. While a little one liner javascript variable doesnt give anywhere near as much info as the broadcom cli, it still gives me a way to log some info rather than none. Personally im pulling the data every 5 mins and graphing it into my munin monitoring, but it would be a lot better if i could pull error stats but as yet ive not found a way.


Quote
var current_linestatus=[{state:'UP',mode:'VDSL2',mod_type:'Profile%2017a',snr_margin_down:'64',snr_margin_up:'71',latn_down:'115',latn_up:'113',satn_down:'0',satn_up:'0',output_power_down:'%2D19',output_power_up:'126',rate_down:'74401',rate_up:'19999',attainable_rate_down:'74987000',attainable_rate_up:'22455000',chantype:'fast'},
null];
« Last Edit: February 19, 2016, 07:27:57 AM by plexy »
Logged
--
SSE 80/20
Sky 40/10
Zen 80/20
Bonded: 200/50 (in progress)

Hardware:Hg612/HH5/Tg589vac/Linux SBC router

Dray

  • Kitizen
  • ****
  • Posts: 2361
Re: Experiments With A BT HH5 (Type B)
« Reply #33 on: February 19, 2016, 07:37:24 AM »

Ooo that's interesting  :fingers:
Logged

kitz

  • Administrator
  • Senior Kitizen
  • *
  • Posts: 33884
  • Trinity: Most guys do.
    • http://www.kitz.co.uk
Re: Experiments With A BT HH5 (Type B)
« Reply #34 on: February 19, 2016, 08:32:07 PM »

This is good news for some and at least it makes some more stats available.

Well done plexy and thank you for sharing.
Logged
Please do not PM me with queries for broadband help as I may not be able to respond.
-----
How to get your router line stats :: ADSL Exchange Checker

plexy

  • Reg Member
  • ***
  • Posts: 115
Re: Experiments With A BT HH5 (Type B)
« Reply #35 on: February 23, 2016, 12:57:41 AM »

this may be of help to any linux or mac users out there

Code: [Select]
#!/bin/bash
#
# HH5 stats to CSV
# By Plexy, for Kitz forum www.kitz.co.uk
#
# Released under the "do what you want with this software, but you agree
# absolve and indemnify me against any liability arising from your use of
# this software" license.
#

CURLLINE=`curl --silent http://192.168.1.254/cgi/cgi_troubleshooting.js | grep current_linestatus | sed 's/var\ current_linestatus=\[{//g' | sed 's/},//g' | sed "s/'//g" `
urldecode() {
    local url_encoded="${1//+/ }"
    printf '%b' "${url_encoded//%/\\x}"
}
array=(${CURLLINE//,/ })
for i in "${!array[@]}"
do
    CSV=`echo "${array[i]}" | sed 's/\:/,/g'`
    urldecode $CSV
    echo
done

copy/paste to a file, such as stats.sh and run like so

Code: [Select]
chmod 755 stats.sh
./stats.sh

This returns each key/value pair, urldecoded, in CSV separated by newline
« Last Edit: February 23, 2016, 02:30:26 AM by plexy »
Logged
--
SSE 80/20
Sky 40/10
Zen 80/20
Bonded: 200/50 (in progress)

Hardware:Hg612/HH5/Tg589vac/Linux SBC router

William Grimsley

  • Kitizen
  • ****
  • Posts: 1489
    • Newton Poppleford Weather
Re: Experiments With A BT HH5 (Type B)
« Reply #36 on: February 23, 2016, 08:39:28 AM »

There is a way to poll the HH5b for;

profile
snr up
snr down
line attn up + down
sig attn up + down (inoperative / 0 value in current firmware)
output power up + down
current sync rate up + down
attainable sync rate up + down

What may be interesting is that this can be retrieved without needing to authenticate (http://192.168.1.254/cgi/cgi_troubleshooting.js ). It does however require a HTTP request to get back, and I do note the presence of curl in the dslstats source code. While a little one liner javascript variable doesnt give anywhere near as much info as the broadcom cli, it still gives me a way to log some info rather than none. Personally im pulling the data every 5 mins and graphing it into my munin monitoring, but it would be a lot better if i could pull error stats but as yet ive not found a way.


Quote
var current_linestatus=[{state:'UP',mode:'VDSL2',mod_type:'Profile%2017a',snr_margin_down:'64',snr_margin_up:'71',latn_down:'115',latn_up:'113',satn_down:'0',satn_up:'0',output_power_down:'%2D19',output_power_up:'126',rate_down:'74401',rate_up:'19999',attainable_rate_down:'74987000',attainable_rate_up:'22455000',chantype:'fast'},
null];

This is interesting! Hopefully, this will add some benefit for BT Home Hub 5 (Type B) users who want to monitor their line stats in the future. Well done and thanks for sharing.
Logged

kitz

  • Administrator
  • Senior Kitizen
  • *
  • Posts: 33884
  • Trinity: Most guys do.
    • http://www.kitz.co.uk
Re: Experiments With A BT HH5 (Type B)
« Reply #37 on: February 23, 2016, 11:14:43 AM »

Thank you plexy for sharing your findings with us. 
Good work :)
Logged
Please do not PM me with queries for broadband help as I may not be able to respond.
-----
How to get your router line stats :: ADSL Exchange Checker

Frisby

  • Just arrived
  • *
  • Posts: 6
Re: Experiments With A BT HH5 (Type B)
« Reply #38 on: June 17, 2016, 02:10:33 PM »

Hi
Has anyone made any progress with HH5B Stats Monitoring in the last 4 months?
Logged

highpriest

  • Reg Member
  • ***
  • Posts: 285
Re: Experiments With A BT HH5 (Type B)
« Reply #39 on: June 22, 2016, 02:20:56 AM »

For Windows users, here's a PowerShell one-liner that will display current_linestatus in a nicer format.

Code: [Select]
(((iwr http://192.168.1.254/cgi/cgi_troubleshooting.js).ToString() -split "[`r`n]" | sls current_linestatus) -split ",|=" -replace "[=[{}]|var" -replace "%20|'|_"," ").Trim()
Works on PowerShell v5 (Windows 10). Should work on older versions as well (I think).

Output from my HH5B:

Code: [Select]
current linestatus
state: UP
mode: VDSL2
mod type: Profile 17a
snr margin down: 109
snr margin up: 149
latn down: 144
latn up: 141
satn down: 0
satn up: 0
output power down: 26
output power up: 140
rate down: 74000
rate up: 19999
attainable rate down: 92683000
attainable rate up: 23410000
chantype: fast

Cheers  :)
Logged
Zen | Zyxel VMG8324-B10A (with RFC4638 patch) | EdgeRouter PoE | UniFi AP AC Pro + Lite

Frisby

  • Just arrived
  • *
  • Posts: 6
Re: Experiments With A BT HH5 (Type B)
« Reply #40 on: June 22, 2016, 08:06:22 AM »

Thanks Highpriest

To the uninitiated how do we use this script please?

I found powershell.exe and entered the script ver batim but unsurprisingly it didn't work.

There are lots of different "Powershells" returned - which one should we use?

Cheers
Logged

highpriest

  • Reg Member
  • ***
  • Posts: 285
Re: Experiments With A BT HH5 (Type B)
« Reply #42 on: June 22, 2016, 01:53:47 PM »

To the uninitiated how do we use this script please?

I found powershell.exe and entered the script ver batim but unsurprisingly it didn't work.

What OS are you running? On modern OSes (Windows 7 and above), PowerShell is already installed. However, the installed version of PowerShell is different across different OSes.

The cmdlet I used, Invoke-WebRequest (the "iwr" bit at the beginning of the script is an alias for Invoke-WebRequest), is only available from PowerShell v3 onwards (Windows 8 and above). So if you are running Windows 7, chances are, you have PowerShell v2, and the cmdlet is not available.

You can find out the installed version of PowerShell by running "$PSVersionTable.PSVersion" (without the quotes) and by looking at the value of the "Major" column.

Code: [Select]
PS F:\> $PSVersionTable.PSVersion

Major  Minor  Build  Revision
-----  -----  -----  --------
5      0      10586  122

If it is 3 or above, that script will work. The "script" itself is just a one-liner command. Just paste the entire line at a PowerShell prompt and hit enter. As long as your computer is connected to the HH5B's wireless (or wired) network, it should work.

If you don't have version 3 installed, you can still manually install versions 3, 4 or 5 on Windows 7.

Link to version 5: https://www.microsoft.com/en-us/download/details.aspx?id=50395

Quote
There are lots of different "Powershells" returned - which one should we use?

Just hit the start button and type "PowerShell" in the search bar. Should bring up the shortcut to fire it up. It will be called "Windows PowerShell" (not the one called "Windows PowerShell ISE", which is a script editor).

Hope this helps!
Logged
Zen | Zyxel VMG8324-B10A (with RFC4638 patch) | EdgeRouter PoE | UniFi AP AC Pro + Lite

Frisby

  • Just arrived
  • *
  • Posts: 6
Re: Experiments With A BT HH5 (Type B)
« Reply #43 on: June 22, 2016, 02:24:07 PM »

Win 8.1 shortly to be 10 when they bring the anniverary upgrade out.

My PS says V6.3

OK the script does work 'as is' if I copy paste all the brackets  :-[

Code: [Select]
Windows PowerShell
current linestatus
state: UP
mode: VDSL2
mod type: Profile 17a
snr margin down: 221
snr margin up: 223
latn down: 101
latn up: 91
satn down: 0
satn up: 0
output power down: %2D55
output power up: 136
rate down: 39994
rate up: 9999
attainable rate down: 106003000
attainable rate up: 29888000
chantype: fast

I'd still like to monitor the HH5B properly though - can John Owen be pursuaded to port RouterStatsHub 5A to 5B with a bit of encouragement?

Thanks again

Logged
Pages: 1 2 [3]
 

anything