Ping test in Java

Hello everyone!
Is there a way that I can call a "ping" test from a java program and catch the results? I basically want to right a program that runs through an entire list of IP addresses and verify whether I can talk to those devices or not. I know how to create the variables and display them, I'm just not sure how to actually perform the actual "ping".
Thanks!

I had the same problem a few months ago when I had had to write a network performance monitor.
I ended up with the following code:
     try {
     Runtime r = Runtime.getRuntime();
     Process p = r.exec("ping 172.20.1.2 -n 1");
     BufferedReader in = new BufferedReader(new InputStreamReader(p.getInputStream()));
     // Insert some code here to read and parse the returned string...
     catch (IOException e) {
     e.printStackTrace();
If you like I could mail you the entire code.
Andy.

Similar Messages

  • My computer is slow on the internet and even stops at times, i have 98mbps to the modem but only 20 mbps and sometimes less on a ping test- what is wrong? i am using a wireless connection do i need to upgrade my wireless modem in the mac?

    my computer is very slow I have 98mbps to the modem but when i run a ping test on the machine i get 20 mbps and sometimes it is .10 mbps- do i need to upgrade my wireless modem on the machine? what can i do?

    used speed test and got 20 mbps, tested the modem and got the 98mbps...something weird as my system just stops and will not load to sites like google and yahoo but will always respond to sites like CNN...does this mean anything?

  • Occasionally got 'Request timed out' when trying to do Ping test on the server. What likely will be the cause?

    I want to troubleshoot what causing the connection unstable between workstation and server. When i try do the ping test, the reply sometime 'Request timed out' Any idea what likely the cause of this issue?
    I tried change network adapter, change network cable, change network port, reassign different ip address to the server. Still the result remain. I got another server on the same rack and same ip segment(base), but the other server is ok.
    Any idea on this guys?
    Thanks.

    Hi S.Akmal,
    The request timed out also can caused by the remote computer no replayed, you can try to check the remote server whether it have some network issue, you also can connect this
    server to another server directly(just connect them with cable) then try the ping then can determine whether issue occur on this server.
    More information:
    Internet Control Message Protocol (ICMP) Basics
    https://support.microsoft.com/en-us/kb/170292
    I’m glad to be of help to you!
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact [email protected]

  • I want to test a java program[UDDI  JAVAse1.4/2004] that uses:

    I want to test a java program[UDDI  JAVAse1.4/2004] that uses:
    1.http://test.uddi.microsoft.com/inquire
    2.https://test.uddi.microsoft.com/publish
    wel las of today(now) these urls changed or remain and are functional the same? if non, tell me new ones?

    According to Wikipedia
    IBM, Microsoft, and SAP announced they were closing their public UDDI nodes in January 2006.UDDI didn't take off as much as was hoped and public UDDI nodes never were much use. These days UDDI is used very rarely and mostly in-house.

  • How do you test your Java Pricing UserExits in eclipse?

    How do you test your Java Pricing UserExits in eclipse?

    do you have to deploy the java class on vmc server to debug it
    Yes
    - So, the classes have to be compiled error free and uploaded to VMC.
    - VMC has to be restarted to test your classes.
    - You have to set the log levels appropriately for your classes using SM53 / SM52.
    -  You can also perform VMC debug through Eclipse.
    all of the details are available in the pricing exit manual*

  • Self ping test

    Hi
    In component monitoring under self ping test we see a tab that says Has an Integration server destination been defined ? What is the destination for the IS mentioned here ? Is it same as HTTP destination ? Or is the pipeline url being mentioned here ?
    Midhun

    Hi Midhun
    In component monitoring you can see your server domain. Under that
    Integration server
    integration engines
    Non - central adapter engines
    J2SE adapter
    Tools
    Self ping test works for selected components
    Now Is a Destination Defined for the Integration Server?
    This test is only performed for ABAP proxy systems, not for the Integration Engine of the Integration Server. This test checks whether a destination is defined for the Integration Server. You configure this destination manually for the local Integration Engine using transaction SXMB_ADM
    Thanks
    Gaurav

  • Does ATS load testing support Java RMI and  T3 protocol?

    Hi Experts,
    Does ATS load testing support Java RMI and T3 protocol or EJB(J2EE)?
    Thanks!

    Joseph,
    Oracle Application Testing Suite is mainly used for testing of applications from a end user perspective and offers an intuitive capture/replay for web, Siebel, EBS, JDE, Fusion apps or SOA based application through WebServices WSDL imports.
    The scripting environment (Oracle OpenScript) does not support script creation by recording JAVA RBI or T3 protocol as we lack a recorder for it, but the scrips are created as pure JAVA code so you could use the JAVA language to write a small RMI cor T3 client for your testing.
    We have customers that have used Application Testing Suite to test non-UI based testing, like: JMS, FTP, Tuxedo and others, but it require a bit of coding.
    Please let me know if you would like to know more or discuss your options
    regards
    Mikael Fries
    Principal Product Manager / Oracle

  • Ping test failure

    Hi, I'm a first time poster. forgive my naiveté on networking issues. I am having trouble connecting the apps 1Password, logitech TouchMouse, and AirVideoFree over WiFi to my Macbook. My iPhone is recognized by my computer over wifi, but the connection is not being made. I have the Firewall OFF, and I have all the proper 3rd party software running. I am at home, and I am sure that the Macbook and iPhone are on the same network.
    I tried to do a Ping test with the following results.
    Ping has started…
    PING xxx.xxx.x.x (xxx.xxx.x.x): 56 data bytes
    Request timeout for icmp_seq 0
    Request timeout for icmp_seq 1
    Request timeout for icmp_seq 2
    Request timeout for icmp_seq 3
    --- xxx.xxx.x.x ping statistics ---
    5 packets transmitted, 0 packets received, 100.0% packet loss
    does anyone know how to fix this? I tried resetting my iPhone network settings and still get nowhere...
    Please advise me.

    Don't worry about connection tests that fail! It is more important to try SAP iViews that makes use of the connection... If they work, who cares that the test fails?
    Cheers

  • Testing of Java J2ME on BREW simulator

    Dear friends,
    I have developed a Java J2ME application and wishes to test it on a BREW simulator. I understand that the simulator runs BREW applications written in C/C++. I sincerely like to seek your kind assistance on where I can find the necessary JVM and J2Bridge to test my Java application on the BREW emulator. This will aid in my porting of my Java application onto the BREW platform.
    Any suggestion on BREW emulators supporting JAVA and further infomation is greatly appreciated!
    Many thanks!
    Regards,
    Chai Ming Jie

    Rumour has it BREW 2.0 and upwards supports running MIDlets. I haven't used it, don't know if it works (in fact, rumour also has it that it doesn't work on any of the phones available today), but that's the word.
    I'm sure you'll get better answers to a question like this on a BREW forum, though.
    shmoove

  • Ping test keep dropping any advice

    Hi, 
    I had this problem 3 weeks agos, now every night from 8pm - 12pm very unstable other time the connection is fine no problem. 
    i run ping test (from a cable connection) and it keep dropping, i sent 100 ping test to www.google.com -n 100 i get 3% loss which make my game play very unstable and unplayable.
    i've try all sort of things unplug tv box disconnect all laptop disable wireless and test and still dropping.
    also called Bt many time and done.
    many times, speed test, line test, noise test replaced my Home hub twice and i still having same problem.
    it was fine anytime other than from 8pm - 12pm
    this very frastrate me because if is work fine on other time that mean there are no problem with my equipment and my
    setup i dont have anything install or turn on practically on that time of night.
    i suspect someone is running a or business on our block make big amount of traffic causes my unstable connection.
    any advices ?
    thanks, 

    in order for the forum members to help please can you post the adsl stats from your router unless HH4 may need to 'show detail' to get all stats (if hub enter 192.168.1.254 in your browser and navigate to adsl or use a-z, if netgear enter 192.168.0.1) and run btspeedtester (MAC users may have problems). when first test completes then run diagnostic test and post the results .
    are you connected directly via a filter to the NTE5 master or test socket or to somewhere else? Is the master the only phone socket in your home?
    Have you tried the quiet line test? - dial 17070 option 2 - should hear nothing - best done with a corded phone. if cordless phone you may hear a 'dull hum' which is normal
    Someone may then be able to offer help/assistance/suggestions to your problem
    If you like a post, or want to say thanks for a helpful answer, please click on the Ratings star on the left-hand side of the post.
    If someone answers your question correctly please let other members know by clicking on ’Mark as Accepted Solution’.

  • Ping Test

    Can your wireless router do a ping test to 66.161.11.90 (www.linksys.com) or any other www.com for that matter?
    Mine can't, either with my wireless PB G4 running OS X 10.4 or wired Dell running Windows XP. I tried it with a wrt54g v5 & wrt54g v6 both tests got a 'request timed out' with 100% packet loss. v5 had the latest firmware, v6 is still at 1.00.9

    hi you can do your ping test here whoisxy.com here they provide you good results .i test my ping here
    my results are
    Pinging cooltamil.com [64.64.4.118] with 32 bytes of data:
    Reply from 64.64.4.118: bytes=32 time=51ms TTL=52
    Reply from 64.64.4.118: bytes=32 time=51ms TTL=52
    Reply from 64.64.4.118: bytes=32 time=53ms TTL=52
    Reply from 64.64.4.118: bytes=32 time=51ms TTL=52
    Ping statistics for 64.64.4.118:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
    Approximate round trip times in milli-seconds:
    Minimum = 51ms, Maximum = 53ms, Average = 51ms

  • Ping test returns "test failed" on some computers on Ethernet network

    When I test for connectivity ( 192.168.1.1 / My Network / device information / ping  test / test connectivity ) "test failed" is returned from some, but not all, computers on my wired Ethernet network. Having worked with computers for many years I have tried all fixes that I know of  without any success. Please help!!!!

    #1 What software firewall is on your comptuer(s)?
    Since you may have more than one computer, please tell me all of the software firewalls that are installed on your different computers.
    #2 What is the brand and model of your router?
    If you are the original poster (OP) and your issue is solved, please remember to click the "Solution?" button so that others can more easily find it. If anyone has been helpful to you, please show your appreciation by clicking the "Kudos" button.

  • What are popular automated tests for Java GUI applications

    Hi, I want to find a good automated test for java swing for my project. I have a list of UISpec4j, JFCUnit and Abbot.

    There is also jemmy. I haven't used any of them, though...
    -Puce

  • BT Performance Ping Test speed way out.

    Anyone know why the BT Performance ping test is way out compared to other test tools?
    When I run the performance test, BT's ping test returns 'speeds' of over 100ms (yes, that'sone hundred ms). Yet if I perform similar tests under the same conditions ie literally seconds later, using different tools such as Speedtest.net, Im getting pings of 20 - 32ms. Go back to BT Performance test and ping is still in the range of 100ms.
    Ive even done ping tests using servers nearly 150 miles from home and even they return pings of less than 30ms!
    Why the massive difference? Why is BT's ping taking on average 100ms. Do they use a London server or something?

    Hi curiousfellow,
    Thanks for posting. Can you post the results you're getting from the different servers and we'll take a look at them for you.
    Cheers
    David
    BTCare Community Mod
    If we have asked you to email us with your details, please make sure you are logged in to the forum, otherwise you will not be able to see our ‘Contact Us’ link within our profiles.
    We are sorry but we are unable to deal with service/account queries via the private message(PM) function so please don't PM your account info, we need to deal with this via our email account :-)

  • How to enable ping service on java-stack only system

    I have installed SAP NetWeaver 7.0 - Java Trial on local host.
    How can you activate the ping service there?
    It should work under "http://localhost:50000/sap/bc/ping"
    (I know how to activate it with transaction SICF in an abap system, but I have java-stack only here, so I can't call transactions. I can only use the Visual Admin, right?, but there I could not detect a ping service so far)
    More detailed:
    I created system "SAP_WebDynpro_XSS". (this is necessary for connecting to ECC abap backend for ESS Packages) and set following parameter:
    template:"SAP system using connection string"
         category: Web Application Server
              Web AS host name: chrisSAP:50000
              Web AS path: /webdynpro/dispatcher/
              Web AS protocol: http
    But when I test the "SAP Web AS Connection" for this system, I got following error:
    7. The Web AS ping service http://chrisSAP:50000/sap/bc/ping was not pinged successfully. If the ping service is not activated on the Web AS, you can try to call the ping service manually.
    8. An HTTP/S connection to http://chrisSAP:50000/webdynpro/dispatcher/ was not
    obtained successfully; this might be due to a closed port on the Firewall.
    I guess step 8 did not pass because step 7 failed, and not because of a closed port or firewall (I made sure everything is open.)
    The strange thing is that the connection test fails, but the connection seems to work fine!
    I mean I can see the front ESS page in the portal when logging in with an ESS-user, and there are no errors in the log. If I change the SAP_WebDynpro_XSS parameters to some other made-up values, then the front ESS page does not come up and some errors appear with "SAP_WebDynpro_XSS" inside.
    That proofs that the connection is working despite the failed connection test, right?. But what can I do that the connection test passes? It seems that somehow SAP has hardcoded the path "/sap/bc/ping" which usually exists on an abap system. But I have java-stack only, so how can I tell that the function that runs the test?
    A system connection test fails, but the connection is working fine!
    If someone could explain that to me...

    Dear Srini Nookala,
    thank you for your answer. Unfortunately I don't understand the relation of my question to your answer.
    >> check with OSS note 1019335 SAP NetWeaver AS Java 6.40 SP21
    I have Version 7.0 SP14. I read the OSS note, but there are around 100 changes listed. I read them all, but couldn't figure out one that has to do with ping and system test. So which sentence inside the note are you referring to?
    >> The problem is due to JCo parameters configuration not properly, Ask Basis team, they will do it.
    I am basis team. I configured the JCo properly as described in manual and tested them afterwards. They run successful. Also all the links that you gave refer to JCO connections about how to set them up and test them. But what have JCO connections to do with System-connection tests? As far as I know JCO-connections are not used for system connectivity tests. You can set them up independent. I understand that JCO-connections are used for getting data from backend servers. But the system "SAP_WebDynpro_XSS" is defined for determing the webdynpros on localhost (frontend, not backend).
    So please can you explain me what JCO-connections which refer to remote hosts have to do with a ping service on local host that cannot be reached? And which part would be not configured "properly"? Timeouts? user?
    To define my question more properly:
    Is it possible to make the connection test work on a java-stack only host for a system that refers to itself (localhost)? Or is it a known bug?
    Some sub-questions
    Am I using the right system template (I am using "SAP system using dedicated application server")
    I have no abap on local host (chrisSAP). Only java stack. Usually path ..sap/bc/ping refers to an abap system, right? So in my opinion I have 3 possibilities:
    - install abap-stack on local host (portal) and activate ping service.
    - somehow install a ping service that runs under the given URL in Visual Admin (how?)
    - somehow tell the connection test to skip pinging and continue test. (How?)
    Any additional advice would be highly appreciated.

Maybe you are looking for

  • Help me format my external drive

    Ok here is my problem, the drive got corrupted (my fault, the drive was getting scanned and it lost power) now i hade hopes of restoring it, but that fell through (nothing important was on it) so now i try to format the drive and i get an input and o

  • WD iView not fond

    hi All, after maintaining my JcoDestination (Modeldata,Metadata) I import all Webdynpro iVies in my targetsystem. After assigning the correct WD_SYSTEM the following error occured. Any idea?? b.r. Wolfgang #1.5#00132169DA9700090000000900000EEC00041F0

  • Rotate a circle based on UITouch

    Ok. I'm racking my brain on this one. Onscreen I have an object (UIImageView) that I want to be able to rotate with my finger. Basically touch it and move my finger around and have it rotate on it's center to follow my finger. Rotating the image is n

  • HT4623 is there a video app.for iphone  3

    IS THERE A VIDEO APP FOR iPHONE 3 

  • Content problems

    I have an eLearning course that my company purchased for use on our LMS system. I decompiled the EXE, tweaked a couple of small things in the code (got rid of a log-in, added a page) and re-compiled. From the Test Movie function, the course works 100