Application to check the Internet status?? - Unix

This is a discussion on Application to check the Internet status?? - Unix ; I tried checking internet status of my system by issuing ping to some well known server like google.com. But, the problem is that ping is not working if target address is not within the same network. I actually started writing ...

+ Reply to Thread
Results 1 to 5 of 5

Thread: Application to check the Internet status??

  1. Application to check the Internet status??

    I tried checking internet status of my system by issuing ping to some
    well known server like google.com. But, the problem is that ping is
    not working if target address is not within the same network. I
    actually started writing small application, which can tell the
    internet status of the given system by using some standard network
    Apis. It would be great if some one suggest me how to proceed for
    this.


    Thanx in advance,
    Ravindra. Bhadramraju

  2. Re: Application to check the Internet status??

    Ravindra.B wrote:
    > I tried checking internet status of my system by issuing ping to some
    > well known server like google.com. But, the problem is that ping is
    > not working if target address is not within the same network. I
    > actually started writing small application, which can tell the
    > internet status of the given system by using some standard network
    > Apis. It would be great if some one suggest me how to proceed for
    > this.


    Can you ping the internet using the Unix supplied ping command?

    You might want to paste you code here, so that we can see if anything is
    wrong.

    Mark.

    --
    Mark Hobley,
    393 Quinton Road West,
    Quinton, BIRMINGHAM.
    B32 1QE.

  3. Re: Application to check the Internet status??

    On Aug 5, 6:12*am, "Ravindra.B"
    wrote:

    > I tried checking internet status of my system by issuing ping to some
    > well known server like google.com. But, the problem is that ping is
    > not working if target address is not within the same network.


    This probably means some firewall somewhere is blocking 'ping's.

    > I
    > actually started writing small application, which can tell the
    > internet status of the given system by using some standard network
    > Apis. It would be great if some one suggest me how to proceed for
    > this.


    It depends on your definition of "internet status". If you define
    precisely what you mean by that, it should be fairly obvious how to
    check for it.

    Note that it may be considered rude to hard-code someone else's server
    into your testing application. Use a server that you have explicit
    permission to use the way you are using it and be sure to rate-limit
    your tests in a sensible way.

    DS

  4. Re: Application to check the Internet status??

    Ravindra.B wrote:
    >I tried checking internet status of my system by issuing ping to some
    >well known server like google.com. But, the problem is that ping is
    >not working if target address is not within the same network.


    You've hit the well-known problem of "problem statement too simple for the
    real world". "internet status" is not binary, it's a very large set of
    capabilities to reach various hosts by various protocols. At any given
    time, some may be available and others not.

    >It would be great if some one suggest me how to proceed for this.


    First, define your needs. What do you mean by "internet status"? If you mean
    "can I connect to port 80 at www.google.com", fine, test for that. If you
    mean something else, then define it closely enough that you can test it.

    Note that even simple questions may be more complicated than they appear. You
    may be behind a firewall or proxy that passes traffic based on more than just
    host and port - it could look at contents, or reconfigure itself based on
    usage.
    --
    Mark Rafn dagon@dagon.net

  5. Re: Application to check the Internet status??

    >I tried checking internet status

    What's that? "Infected" vs. "not infected"?

    >of my system by issuing ping to some
    >well known server like google.com.


    google.com isn't the whole internet. Some well-known hosts (e.g.
    www.microsoft.com) don't permit ping of their servers. And, of
    course, the particular host you choose can become unreachable without
    the whole internet becoming unreachable.

    >But, the problem is that ping is
    >not working if target address is not within the same network. I


    That's not the way ping normally works. Is your firewall blocking
    it? Is your ISP's firewall blocking it?

    >actually started writing small application, which can tell the
    >internet status of the given system by using some standard network
    >Apis. It would be great if some one suggest me how to proceed for
    >this.


    I suggest getting permission, in writing, from the owner of the
    host you intend to use, unless perhaps it belongs to your ISP,
    in which case you are paying to use it.


+ Reply to Thread