Charmed Quark Systems, Ltd. - Support Forums and Community

Full Version: how to monitor tcp port or ping with CQC?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I have few servers at home:
lime storage
asterisk (askozia voip)
linux server based HP T5720

how i can monitor that ports possible to connect or http request with CQC?
You would need to write a driver that attempts to open up selected ports on those machines periodically and sets a field to whether it worked or not.
The asterisk server possibly has SNMP
Windows has a snmp service that you could use as well.
I dont know about the other two, but snmp would be a good place to start. You may not get the status of the port, but you may get something that can imply that the port is open (or are you trying to imply something from the fact that the port is open).

Dean, for checking that your internet is working, you'd have to ping some outside website occassionally. Are there internet "good conduct" specs for how often and how you'd do that? And along those lines....what about pinging some part of

I wouldn't mind some kind of means to determine if my internet is down, because 90% of the time it is, I just go reboot my DSL modem and it's back up. It'd be kind of nice to do that automatically...
I definitely wouldn't want everyone pinging our server. There are plenty of far higher capacity servers out there to ping, like google or microsoft.
Dean Roddey Wrote:I definitely wouldn't want everyone pinging our server. There are plenty of far higher capacity servers out there to ping, like google or microsoft.

my asterisk has no snmp protocol...
looks like i need to install nagius on some linux host.
In places where multiple locations can be tested, I tend to use the DNS servers upstream from me. The problem with using a single ip would be when one is offline. That doesn't mean the link is down, just that one box. You might also consider getting an ntp driver to a decent sized server (I like the Naval Observatory servers) or a driver to any other small footprint protocol that checks status (pop3/imap logins to a google server) would be just as good.

This is a kind of old thread, and I know others have mentioned this more recently, but I found this one... Just FYI, I just added the code to support doing pings to the latest .905 beta, so that will be there in the next drop. See the beta discussion thread for some info. I'll document the CML wrapper class tomorrow when I get it done.
And i'll try and get it added to the Network Monitor driver...
Here is a simple example pinger in CML. It's quite simple to use. You wouldn't do it exactly this way in a driver. I'm just doing it like a standard command line pinger would do, with the send of the request and a single 10 second wait all together. Whereas a driver would start the request, and come back later to do a quick test of whether the response is available.

Also the response time being returned in my case is accurate. In a driver scenario it wouldn't really be since it would include the time until you got back to look for it having come in.

    ClassPath MEng.TestPing;
    ParentClass MEng.Object;


    SockPinger          m_Pinger;
    ConsoleOutStream    m_OutCon;
    Time                m_Time;



    Method Start([In] String TarAddr) Returns Int4
            IPEndPoint  TarEP;
            Card4       LoopIndex(0);
            Card4       RepMSs;

            m_Pinger.StartPing(TarAddr, IPAddrTypes.Unspec, TarEP);
            m_OutCon.FmtStr("Pinging address ");

            While(LoopIndex < 3)

                If (m_Pinger.WaitReply(10000, RepMSs))
                    m_OutCon.FmtStr("   Got a reply. Millis=");
                    m_OutCon.FmtStr("   Did not get a reply");



            m_OutCon.FmtStr("\nEXCEPTION: ");


        Return 0;
Pages: 1 2