Re: Ping
The *pclose*() function waits for the associated process to terminate and returns the exit status of the command On Feb 5, 2008 1:30 AM, Axton [EMAIL PROTECTED] wrote: popen looks to be available on all platforms (posix compliant and windows). Windows defines the function as _popen though. http://msdn2.microsoft.com/en-us/library/96ayss4b(VS.80).aspxhttp://msdn2.microsoft.com/en-us/library/96ayss4b%28VS.80%29.aspx I wrote a filter plugin that executes ping via popen and returns the output, but it provides no more functionality or simplicity than running ping from a set fields process. What I can't figure out how to get is the exit code from ping when run via popen; only stdout. Axton Grams On Feb 4, 2008 3:25 PM, William H. Will Du Chene [EMAIL PROTECTED] wrote: Either way, there was no getting around it. It's a de facto standard that a child process inherits the same level of permissions - and the profile - of whatever the parent process is. Without that behavior on the platform, we would really have issues. Axton made an excellent catch and I am grateful for it. Knowing that there are alternative functions out there which can be used is a very good thing. I didn't read the page close enough, so I am curious to know if these functions are present on all platforms. Many of the open source applications which I have had to tear apart and rewrite components of - such as HtDig - make use of popen to process the results from the sort utility that it uses. Unfortunately, implementations very here and there and this is something that I ran into when I ported the search engine over to windows. Basically all that says is whatever is run under popen runs as the caller. In this case ARS, which should not have those privileges - and if they are running as root they deserve all they get :-) Calling something that uses popen from ARS is no better or worse than invoking any other command with a run process. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
I would have thought so, but I am not seeing it: code snippet: if ((fp = popen(command, r)) == NULL) { log_severe (file pointer is null); return; } char path[100]; while (fgets(path, 100, fp) != NULL) log_finer (%s, path); log_fine (popen errno: %i: %s, errno, strerror(errno)); ret = pclose(fp); log_fine (pclose errno: %i: %s, errno, strerror(errno)); outValues-valueList[0].u.intVal = ret; log_fine (return value: %i, ret); Log output: +CALL ARFilterApiCall -- filter API ARSWIKI.ARF.PING ARSWIKI.ARF.PING FINE ping command: /usr/sbin/ping cipher ARSWIKI.ARF.PING FINER cipher is alive ARSWIKI.ARF.PING FINE popen errno: 0: Error 0 ARSWIKI.ARF.PING FINE pclose errno: 10: No child processes ARSWIKI.ARF.PING FINE return value: -1 From ping man page: The following exit values are returned: 0 Successful operation; the machine is alive. non-zeroAn error has occurred. Either a malformed argument has been specified, or the machine was not alive. Not sure what I'm missing. Axton Grams On Feb 5, 2008 11:27 AM, Wayne Keenan [EMAIL PROTECTED] wrote: ** The pclose() function waits for the associated process to terminate and returns the exit status of the command On Feb 5, 2008 1:30 AM, Axton [EMAIL PROTECTED] wrote: popen looks to be available on all platforms (posix compliant and windows). Windows defines the function as _popen though. http://msdn2.microsoft.com/en-us/library/96ayss4b(VS.80).aspx I wrote a filter plugin that executes ping via popen and returns the output, but it provides no more functionality or simplicity than running ping from a set fields process. What I can't figure out how to get is the exit code from ping when run via popen; only stdout. Axton Grams On Feb 4, 2008 3:25 PM, William H. Will Du Chene [EMAIL PROTECTED] wrote: Either way, there was no getting around it. It's a de facto standard that a child process inherits the same level of permissions - and the profile - of whatever the parent process is. Without that behavior on the platform, we would really have issues. Axton made an excellent catch and I am grateful for it. Knowing that there are alternative functions out there which can be used is a very good thing. I didn't read the page close enough, so I am curious to know if these functions are present on all platforms. Many of the open source applications which I have had to tear apart and rewrite components of - such as HtDig - make use of popen to process the results from the sort utility that it uses. Unfortunately, implementations very here and there and this is something that I ran into when I ported the search engine over to windows. Basically all that says is whatever is run under popen runs as the caller. In this case ARS, which should not have those privileges - and if they are running as root they deserve all they get :-) Calling something that uses popen from ARS is no better or worse than invoking any other command with a run process. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are __Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are html___ ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
On Sun, 3 Feb 2008 21:55:18 -0500, Axton wrote: Some more digging revealed the following: http://www.opengroup.org/onlinepubs/009695399/functions/popen.html The *popen*() function should not be used by programs that have set user (or group) ID privileges. The *fork*()http://www.opengroup.org/onlinepubs/009695399/functions/fork.htmland *exec http://www.opengroup.org/onlinepubs/009695399/functions/exec.html*family of functions (except *execlp*()http://www.opengroup.org/onlinepubs/009695399/functions/execlp.htmland *execvp*()http://www.opengroup.org/onlinepubs/009695399/functions/execvp.html), should be used instead. This prevents any unforeseen manipulation of the environment of the user that could cause execution of commands not anticipated by the calling program. Basically all that says is whatever is run under popen runs as the caller. In this case ARS, which should not have those privileges - and if they are running as root they deserve all they get :-) Calling something that uses popen from ARS is no better or worse than invoking any other command with a run process. -- Regards Dave Saville ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
Either way, there was no getting around it. It's a de facto standard that a child process inherits the same level of permissions - and the profile - of whatever the parent process is. Without that behavior on the platform, we would really have issues. Axton made an excellent catch and I am grateful for it. Knowing that there are alternative functions out there which can be used is a very good thing. I didn't read the page close enough, so I am curious to know if these functions are present on all platforms. Many of the open source applications which I have had to tear apart and rewrite components of - such as HtDig - make use of popen to process the results from the sort utility that it uses. Unfortunately, implementations very here and there and this is something that I ran into when I ported the search engine over to windows. Basically all that says is whatever is run under popen runs as the caller. In this case ARS, which should not have those privileges - and if they are running as root they deserve all they get :-) Calling something that uses popen from ARS is no better or worse than invoking any other command with a run process. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
popen looks to be available on all platforms (posix compliant and windows). Windows defines the function as _popen though. http://msdn2.microsoft.com/en-us/library/96ayss4b(VS.80).aspx I wrote a filter plugin that executes ping via popen and returns the output, but it provides no more functionality or simplicity than running ping from a set fields process. What I can't figure out how to get is the exit code from ping when run via popen; only stdout. Axton Grams On Feb 4, 2008 3:25 PM, William H. Will Du Chene [EMAIL PROTECTED] wrote: Either way, there was no getting around it. It's a de facto standard that a child process inherits the same level of permissions - and the profile - of whatever the parent process is. Without that behavior on the platform, we would really have issues. Axton made an excellent catch and I am grateful for it. Knowing that there are alternative functions out there which can be used is a very good thing. I didn't read the page close enough, so I am curious to know if these functions are present on all platforms. Many of the open source applications which I have had to tear apart and rewrite components of - such as HtDig - make use of popen to process the results from the sort utility that it uses. Unfortunately, implementations very here and there and this is something that I ran into when I ported the search engine over to windows. Basically all that says is whatever is run under popen runs as the caller. In this case ARS, which should not have those privileges - and if they are running as root they deserve all they get :-) Calling something that uses popen from ARS is no better or worse than invoking any other command with a run process. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
Some more digging revealed the following: http://www.opengroup.org/onlinepubs/009695399/functions/popen.html The *popen*() function should not be used by programs that have set user (or group) ID privileges. The *fork*()http://www.opengroup.org/onlinepubs/009695399/functions/fork.htmland *exec http://www.opengroup.org/onlinepubs/009695399/functions/exec.html*family of functions (except *execlp*()http://www.opengroup.org/onlinepubs/009695399/functions/execlp.htmland *execvp*()http://www.opengroup.org/onlinepubs/009695399/functions/execvp.html), should be used instead. This prevents any unforeseen manipulation of the environment of the user that could cause execution of commands not anticipated by the calling program. Axton Grams On Feb 1, 2008 1:56 AM, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not circumvent the entire issue, and use popen and the existing ping binary? It's in stdio.h. That would eliminate the need for a shell script wrapper, allow for the development of a plugin within C, and make use of the existing ping binary which has already been designed to do the job... Best part - no root-ski required. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
The only trick with this approach is knowing how to parse the output from all the supported platforms/versions to return the up/down indicator. If we simply want to return the output from ping, this is a rather simple way to meet that goal. What does the OP want to see the plugin return? Axton Grams On Feb 1, 2008 1:56 AM, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not circumvent the entire issue, and use popen and the existing ping binary? It's in stdio.h. That would eliminate the need for a shell script wrapper, allow for the development of a plugin within C, and make use of the existing ping binary which has already been designed to do the job... Best part - no root-ski required. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
Interesting topic. This is a question for anyone with C programming experience on unix or linux. When sending icmp packets, you have to create a raw socket. This requires either running the program as root or setting suid bit and the owner of the program to root. With the structure of the plugin server, would a shared object (.so) loaded by arplugin not running as root be able to create a raw socket if the .so was owned by root and the the suid bit set? Thanks, Axton Grams On Jan 30, 2008 6:30 PM, patrick zandi [EMAIL PROTECTED] wrote: ** --Concept-- Unless this application is going to provide some internal historical data.. I see no reason for maintaining it in ARS. Just call a widget. -- Create a VB or Something else, that pop's a window and shows network health. or even use the widget to call a View of HP Openview (your personal View of Servers, Services) or Bim/Sim it, and have the Proformance monitor show you your specialized view (highend customers). -- I used to have a script in unix around that I wrote some 12 years ago.. that was pretty cool, will have to see if I can modify it to run on MS..but first I have to find it. You just plug in the Servers/Whatever.. and every 30 seconds it told you if it was alive or down. You have to be able to write something like this in windows easy enough. I know there are hundreds of Scripters on the list.. that could just pop that out.. no problem. Maybe a config file and an Executable. -- use Remedy usertool to modify the Config as you choose, and run the executable. I found one in PERL http://cpan.org/authors/id/S/SR/SREZIC/pingomatic-1.013 But we need one that pops a MS Window and shows the data.. right.. on the unix side found this.. http://www.sunmanagers.org/pipermail/summaries/2003-January/002996.html ... Coder's Arise... Surely it is possible to have a small window with Tiny font, pop a window and show name -- Alive name ++ Down name -- Alive and it stays on top. Forced.. --/Concept On 1/30/08, Steven Pataray [EMAIL PROTECTED] wrote: ** As for the Up and Down field, maybe have the results create a text file on the server then create a Menu of Menu Type of File to access the text file. Then connect the menu to a character field. Steve On 1/30/08, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or if the server is a database server, it could create a row in a test table database) and collect the delta for the amount of time that the operation took and place that into the host record. From your control panel form, use an active link that updates every X time period. The idea being that any servers that are down, or services that would be unavailable would be visible within the control panel. Of course, the accuracy is limited by the delta in time that is present between the last run time of the script and the refresh on the control panel, but it should work fine for the average stuff. Besides, if it's a major network or service outage, the customers will be on the phone anyway... Just a thought... -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are -- Thanks Steven Pataray Senior Analyst, Help Desk Bank of Hawaii 909 Dillingham Blvd, Honolulu, HI. 96817 808 694-5078 __Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are html___ -- Patrick Zandi Dev Technology Group -- www.devtechnology.com Exceeding your Expectations ! __Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are html___ ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where
Re: Ping
good point Axton -- I thought of that after ward... But I need the salt so I can make a way... I love it when it is mpossible odds.. ;-) On 1/31/08, Axton [EMAIL PROTECTED] wrote: Interesting topic. This is a question for anyone with C programming experience on unix or linux. When sending icmp packets, you have to create a raw socket. This requires either running the program as root or setting suid bit and the owner of the program to root. With the structure of the plugin server, would a shared object (.so) loaded by arplugin not running as root be able to create a raw socket if the .so was owned by root and the the suid bit set? Thanks, Axton Grams On Jan 30, 2008 6:30 PM, patrick zandi [EMAIL PROTECTED] wrote: ** --Concept-- Unless this application is going to provide some internal historical data.. I see no reason for maintaining it in ARS. Just call a widget. -- Create a VB or Something else, that pop's a window and shows network health. or even use the widget to call a View of HP Openview (your personal View of Servers, Services) or Bim/Sim it, and have the Proformance monitor show you your specialized view (highend customers). -- I used to have a script in unix around that I wrote some 12 years ago.. that was pretty cool, will have to see if I can modify it to run on MS..but first I have to find it. You just plug in the Servers/Whatever.. and every 30 seconds it told you if it was alive or down. You have to be able to write something like this in windows easy enough. I know there are hundreds of Scripters on the list.. that could just pop that out.. no problem. Maybe a config file and an Executable. -- use Remedy usertool to modify the Config as you choose, and run the executable. I found one in PERL http://cpan.org/authors/id/S/SR/SREZIC/pingomatic-1.013 But we need one that pops a MS Window and shows the data.. right.. on the unix side found this.. http://www.sunmanagers.org/pipermail/summaries/2003-January/002996.html ... Coder's Arise... Surely it is possible to have a small window with Tiny font, pop a window and show name -- Alive name ++ Down name -- Alive and it stays on top. Forced.. --/Concept On 1/30/08, Steven Pataray [EMAIL PROTECTED] wrote: ** As for the Up and Down field, maybe have the results create a text file on the server then create a Menu of Menu Type of File to access the text file. Then connect the menu to a character field. Steve On 1/30/08, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or if the server is a database server, it could create a row in a test table database) and collect the delta for the amount of time that the operation took and place that into the host record. From your control panel form, use an active link that updates every X time period. The idea being that any servers that are down, or services that would be unavailable would be visible within the control panel. Of course, the accuracy is limited by the delta in time that is present between the last run time of the script and the refresh on the control panel, but it should work fine for the average stuff. Besides, if it's a major network or service outage, the customers will be on the phone anyway... Just a thought... -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are -- Thanks Steven Pataray Senior Analyst, Help Desk Bank of Hawaii 909 Dillingham Blvd, Honolulu, HI. 96817 808 694-5078 __Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are html___ -- Patrick Zandi Dev
Re: Ping
I think the security would be the biggest problem.. I think I could get it to work... but the secuirty sacrifice would make it useless.. no IA team would let it pass.. On 1/31/08, patrick zandi [EMAIL PROTECTED] wrote: good point Axton -- I thought of that after ward... But I need the salt so I can make a way... I love it when it is mpossible odds.. ;-) On 1/31/08, Axton [EMAIL PROTECTED] wrote: Interesting topic. This is a question for anyone with C programming experience on unix or linux. When sending icmp packets, you have to create a raw socket. This requires either running the program as root or setting suid bit and the owner of the program to root. With the structure of the plugin server, would a shared object (.so) loaded by arplugin not running as root be able to create a raw socket if the .so was owned by root and the the suid bit set? Thanks, Axton Grams On Jan 30, 2008 6:30 PM, patrick zandi [EMAIL PROTECTED] wrote: ** --Concept-- Unless this application is going to provide some internal historical data.. I see no reason for maintaining it in ARS. Just call a widget. -- Create a VB or Something else, that pop's a window and shows network health. or even use the widget to call a View of HP Openview (your personal View of Servers, Services) or Bim/Sim it, and have the Proformance monitor show you your specialized view (highend customers). -- I used to have a script in unix around that I wrote some 12 years ago.. that was pretty cool, will have to see if I can modify it to run on MS..but first I have to find it. You just plug in the Servers/Whatever.. and every 30 seconds it told you if it was alive or down. You have to be able to write something like this in windows easy enough. I know there are hundreds of Scripters on the list.. that could just pop that out.. no problem. Maybe a config file and an Executable. -- use Remedy usertool to modify the Config as you choose, and run the executable. I found one in PERL http://cpan.org/authors/id/S/SR/SREZIC/pingomatic-1.013 But we need one that pops a MS Window and shows the data.. right.. on the unix side found this.. http://www.sunmanagers.org/pipermail/summaries/2003-January/002996.html ... Coder's Arise... Surely it is possible to have a small window with Tiny font, pop a window and show name -- Alive name ++ Down name -- Alive and it stays on top. Forced.. --/Concept On 1/30/08, Steven Pataray [EMAIL PROTECTED] wrote: ** As for the Up and Down field, maybe have the results create a text file on the server then create a Menu of Menu Type of File to access the text file. Then connect the menu to a character field. Steve On 1/30/08, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or if the server is a database server, it could create a row in a test table database) and collect the delta for the amount of time that the operation took and place that into the host record. From your control panel form, use an active link that updates every X time period. The idea being that any servers that are down, or services that would be unavailable would be visible within the control panel. Of course, the accuracy is limited by the delta in time that is present between the last run time of the script and the refresh on the control panel, but it should work fine for the average stuff. Besides, if it's a major network or service outage, the customers will be on the phone anyway... Just a thought... -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or
Re: Ping
Yep, I started writing something in c, but seeing these things would make it useless in most environments (gov, edu, mil, financial, etc.). Wrapping the existing suid ping program in a shell script would suffice, but a plugin would be easier to use/port/maintain. Loving the impossible odds too, something other than a raw datagram though; if we bind to a known open port (for systems with firewalls that drop packets to blocked ports) or attempt to bind to a port and watch for the rst/ack packet, we can check for some level of availability (I say some level because it just means the kernel is up and the network cable is plugged in). Isn't really much more complex, just requires more parameters to operate. This should give the desired functionality without the compromise. It wouldn't require root access, eliminating all the fun things the knowing can do with it. Axton Grams On Jan 31, 2008 11:06 PM, patrick zandi [EMAIL PROTECTED] wrote: ** I think the security would be the biggest problem.. I think I could get it to work... but the secuirty sacrifice would make it useless.. no IA team would let it pass.. On 1/31/08, patrick zandi [EMAIL PROTECTED] wrote: good point Axton -- I thought of that after ward... But I need the salt so I can make a way... I love it when it is mpossible odds.. ;-) On 1/31/08, Axton [EMAIL PROTECTED] wrote: Interesting topic. This is a question for anyone with C programming experience on unix or linux. When sending icmp packets, you have to create a raw socket. This requires either running the program as root or setting suid bit and the owner of the program to root. With the structure of the plugin server, would a shared object (.so) loaded by arplugin not running as root be able to create a raw socket if the .so was owned by root and the the suid bit set? Thanks, Axton Grams On Jan 30, 2008 6:30 PM, patrick zandi [EMAIL PROTECTED] wrote: ** --Concept-- Unless this application is going to provide some internal historical data.. I see no reason for maintaining it in ARS. Just call a widget. -- Create a VB or Something else, that pop's a window and shows network health. or even use the widget to call a View of HP Openview (your personal View of Servers, Services) or Bim/Sim it, and have the Proformance monitor show you your specialized view (highend customers). -- I used to have a script in unix around that I wrote some 12 years ago.. that was pretty cool, will have to see if I can modify it to run on MS..but first I have to find it. You just plug in the Servers/Whatever.. and every 30 seconds it told you if it was alive or down. You have to be able to write something like this in windows easy enough. I know there are hundreds of Scripters on the list.. that could just pop that out.. no problem. Maybe a config file and an Executable. -- use Remedy usertool to modify the Config as you choose, and run the executable. I found one in PERL http://cpan.org/authors/id/S/SR/SREZIC/pingomatic-1.013 But we need one that pops a MS Window and shows the data.. right.. on the unix side found this.. http://www.sunmanagers.org/pipermail/summaries/2003-January/002996.html ... Coder's Arise... Surely it is possible to have a small window with Tiny font, pop a window and show name -- Alive name ++ Down name -- Alive and it stays on top. Forced.. --/Concept On 1/30/08, Steven Pataray [EMAIL PROTECTED] wrote: ** As for the Up and Down field, maybe have the results create a text file on the server then create a Menu of Menu Type of File to access the text file. Then connect the menu to a character field. Steve On 1/30/08, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or
Re: Ping
Why not circumvent the entire issue, and use popen and the existing ping binary? It's in stdio.h. That would eliminate the need for a shell script wrapper, allow for the development of a plugin within C, and make use of the existing ping binary which has already been designed to do the job... Best part - no root-ski required. -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
What do you mean by populate a Up/Down field? -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Gornto Robert R YC-02 37 CS/SCBM Sent: Wednesday, January 30, 2008 12:03 PM To: arslist@ARSLIST.ORG Subject: Ping Has anyone seen or developed a way to ping an ip in a form and populate a Up/Down field ? //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
Like a selection filed.. Up if the ping succeeds or Down if it doesn't //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Kaiser Norm E CIV USAF 96 CS/SCCE Sent: Wednesday, January 30, 2008 12:14 PM To: arslist@ARSLIST.ORG Subject: Re: Ping What do you mean by populate a Up/Down field? -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Gornto Robert R YC-02 37 CS/SCBM Sent: Wednesday, January 30, 2008 12:03 PM To: arslist@ARSLIST.ORG Subject: Ping Has anyone seen or developed a way to ping an ip in a form and populate a Up/Down field ? //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
OK...what about this: Create a field and hide it. Put a button on the form that kicks off the ping workflow. The ping workflow does a set fields action against the hidden field. Do a RUN PROCESS in the set fields action. By doing a RUN PROCESS in the set fields, the output of the ping (or any DOS command or batch file, for that matter) is redirected into the hidden field. Next, create an active link that sets your selection field (radio button or whatever) if the contents of the hidden field are LIKE %Reply from%. -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Gornto Robert R YC-02 37 CS/SCBM Sent: Wednesday, January 30, 2008 12:13 PM To: arslist@ARSLIST.ORG Subject: Re: Ping Like a selection filed.. Up if the ping succeeds or Down if it doesn't //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Kaiser Norm E CIV USAF 96 CS/SCCE Sent: Wednesday, January 30, 2008 12:14 PM To: arslist@ARSLIST.ORG Subject: Re: Ping What do you mean by populate a Up/Down field? -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Gornto Robert R YC-02 37 CS/SCBM Sent: Wednesday, January 30, 2008 12:03 PM To: arslist@ARSLIST.ORG Subject: Ping Has anyone seen or developed a way to ping an ip in a form and populate a Up/Down field ? //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
For portability reasons, you may want to count on the ping command returning a 0 for success and 1 for failure. On Windows and every *nix platform I've seen, that is the case with the ping command. Michael Durrant -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Kaiser Norm E CIV USAF 96 CS/SCCE Sent: Wednesday, January 30, 2008 11:31 AM To: arslist@ARSLIST.ORG Subject: Re: Ping OK...what about this: Create a field and hide it. Put a button on the form that kicks off the ping workflow. The ping workflow does a set fields action against the hidden field. Do a RUN PROCESS in the set fields action. By doing a RUN PROCESS in the set fields, the output of the ping (or any DOS command or batch file, for that matter) is redirected into the hidden field. Next, create an active link that sets your selection field (radio button or whatever) if the contents of the hidden field are LIKE %Reply from%. -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Gornto Robert R YC-02 37 CS/SCBM Sent: Wednesday, January 30, 2008 12:13 PM To: arslist@ARSLIST.ORG Subject: Re: Ping Like a selection filed.. Up if the ping succeeds or Down if it doesn't //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Kaiser Norm E CIV USAF 96 CS/SCCE Sent: Wednesday, January 30, 2008 12:14 PM To: arslist@ARSLIST.ORG Subject: Re: Ping What do you mean by populate a Up/Down field? -Original Message- From: Action Request System discussion list(ARSList) [mailto:[EMAIL PROTECTED] On Behalf Of Gornto Robert R YC-02 37 CS/SCBM Sent: Wednesday, January 30, 2008 12:03 PM To: arslist@ARSLIST.ORG Subject: Ping Has anyone seen or developed a way to ping an ip in a form and populate a Up/Down field ? //SIGNED// Robert R. Gornto, GS-12,37 CS/SCBB Chief, Network Administration DSN 945-0483 Comm 210 925-0483 ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are The information contained in this email may be privileged, confidential or otherwise protected from disclosure. All persons are advised that they may face penalties under state and federal law for sharing this information with unauthorized individuals. If you received this email in error, please reply to the sender that you have received this information in error. Also, please delete this email after replying to the sender. ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or if the server is a database server, it could create a row in a test table database) and collect the delta for the amount of time that the operation took and place that into the host record. From your control panel form, use an active link that updates every X time period. The idea being that any servers that are down, or services that would be unavailable would be visible within the control panel. Of course, the accuracy is limited by the delta in time that is present between the last run time of the script and the refresh on the control panel, but it should work fine for the average stuff. Besides, if it's a major network or service outage, the customers will be on the phone anyway... Just a thought... -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
As for the Up and Down field, maybe have the results create a text file on the server then create a Menu of Menu Type of File to access the text file. Then connect the menu to a character field. Steve On 1/30/08, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or if the server is a database server, it could create a row in a test table database) and collect the delta for the amount of time that the operation took and place that into the host record. From your control panel form, use an active link that updates every X time period. The idea being that any servers that are down, or services that would be unavailable would be visible within the control panel. Of course, the accuracy is limited by the delta in time that is present between the last run time of the script and the refresh on the control panel, but it should work fine for the average stuff. Besides, if it's a major network or service outage, the customers will be on the phone anyway... Just a thought... -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are -- Thanks Steven Pataray Senior Analyst, Help Desk Bank of Hawaii 909 Dillingham Blvd, Honolulu, HI. 96817 808 694-5078 ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are
Re: Ping
--Concept-- Unless this application is going to provide some internal historical data.. I see no reason for maintaining it in ARS. Just call a widget. -- Create a VB or Something else, that pop's a window and shows network health. or even use the widget to call a View of HP Openview (your personal View of Servers, Services) or Bim/Sim it, and have the Proformance monitor show you your specialized view (highend customers). -- I used to have a script in unix around that I wrote some 12 years ago.. that was pretty cool, will have to see if I can modify it to run on MS..but first I have to find it. You just plug in the Servers/Whatever.. and every 30 seconds it told you if it was alive or down. You have to be able to write something like this in windows easy enough. I know there are hundreds of Scripters on the list.. that could just pop that out.. no problem. Maybe a config file and an Executable. -- use Remedy usertool to modify the Config as you choose, and run the executable. I found one in PERL http://cpan.org/authors/id/S/SR/SREZIC/pingomatic-1.013 But we need one that pops a MS Window and shows the data.. right.. on the unix side found this.. http://www.sunmanagers.org/pipermail/summaries/2003-January/002996.html ... Coder's Arise... Surely it is possible to have a small window with Tiny font, pop a window and show name -- Alive name ++ Down name -- Alive and it stays on top. Forced.. --/Concept On 1/30/08, Steven Pataray [EMAIL PROTECTED] wrote: ** As for the Up and Down field, maybe have the results create a text file on the server then create a Menu of Menu Type of File to access the text file. Then connect the menu to a character field. Steve On 1/30/08, William H. Will Du Chene [EMAIL PROTECTED] wrote: Why not... 1.) Develop a form that contains the ip address, or host name of the machine that you want to ping. 2.) Develop a view form with a table field that queries the host form. 3.) Develop a simple Perl script and place it on your server to be run via an escalation every X minutes. The Perl script would then use the ARSPerl module to open up the host form within the AR System and retrieve a list of the hosts that it needs to contact. It would then cycle through each of the servers therein, and update the corrosponding server's host record within the AR System. The Perl script could use either one of the Net modules, or simply be a wrapper for the ping utility. Maybe you could even do something a bit more classy, such as open a connection to the any of the services that might be on the server and verify that they are available (for example, if this server is an IMAP server, your script could access an account, or if the server is a database server, it could create a row in a test table database) and collect the delta for the amount of time that the operation took and place that into the host record. From your control panel form, use an active link that updates every X time period. The idea being that any servers that are down, or services that would be unavailable would be visible within the control panel. Of course, the accuracy is limited by the delta in time that is present between the last run time of the script and the refresh on the control panel, but it should work fine for the average stuff. Besides, if it's a major network or service outage, the customers will be on the phone anyway... Just a thought... -- Will Du Chene [EMAIL PROTECTED] http://www.myspace.com/wduchene ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are -- Thanks Steven Pataray Senior Analyst, Help Desk Bank of Hawaii 909 Dillingham Blvd, Honolulu, HI. 96817 808 694-5078 __Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are html___ -- Patrick Zandi Dev Technology Group -- www.devtechnology.com Exceeding your Expectations ! ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Platinum Sponsor: www.rmsportal.com ARSlist: Where the Answers Are