bgp-as

NAME

bgp-as - Query the Internode Looking Glass


USAGE

bgp-as --net=192.0.2.0/24


REQUIRED ARGUMENTS

--net=network

Give the network to be looked up in the BGP tables, for example, 192.0.2.0/24. The prefix is optional.


OPTIONS

--table=table

Choose either the 'Domestic' or 'International' table to query.

--man

Print the manual page and exit.

--help

Print a brief help message and exit.


DESCRIPTION

This program uses http://looking-glass.internode.on.net/ to display the BGP table for the given network.


DIAGNOSTICS

If this script isn't working, try using the website directly.


EXIT STATUS

If this program exits with a zero exit status and the correct output is on standard output. Nothing else is ever printed to standard output.

This program will exit with a non-zero exit status if there was a fatal error. Both fatal and non-fatal errors will cause output on standard error.


CONFIGURATION

If you need to access the Internet via a proxy, please ensure you have set the http_proxy environment variable.


DEPENDENCIES

Do not use this script in an automated way - here's the warning from the http://looking-glass.internode.on.net/ webpage:

    Looking Glass is not to be used with ANY automated
    scripts. Ignoring this policy will result in being
    banned. All transactions are logged.

Please respect their clearly stated wishes and just use this manually from the command line - don't force Internode to withdraw this valuable service to the Internet community


INCOMPATIBILITIES

As per the dependencies, this script is not compatible with any automated usage.


EXAMPLES

    $ ~/bin/bgp-as --net 150.101.98.0/24 --table International
    % Network not in table
    $ ~/bin/bgp-as --net 150.101.98.0 --table International
    BGP routing table entry for 150.101.0.0/16, version 902222264
    Paths: (2 available, best #1)
    Flag: 0x820
    Not advertised to any peer
    7473 2914 4739 4739 4739
        203.208.191.157 from 203.202.143.19 (203.202.143.19)
        Origin IGP, metric 0, localpref 50, valid, internal, best
        Community: 7473:21045 7473:31415 7474:1403
        Originator: 203.202.143.1, Cluster list: 0.0.0.1
    7473 2914 4739 4739 4739
        203.208.191.157 from 203.202.143.20 (203.202.143.20)
        Origin IGP, metric 0, localpref 50, valid, internal
        Community: 7473:21045 7473:31415 7474:1403
        Originator: 203.202.143.1, Cluster list: 0.0.0.1


BUGS AND LIMITATIONS

No known bugs - please email me with any problems.


AUTHOR

Mark Suter <suter@humbug.org.au>


LICENSE AND COPYRIGHT

Copyright (C) 2008 Mark Suter <suter@humbug.org.au>

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

-->