Changing IP address of local windows machine using NETSH in JAVA- HELP

Hi ALL,
I have written one java program to change the IP address of local
machine using netsh command tool and runtime.exec method in java.
String[] command1 = { "netsh", "interface", "ip", "set", "address",
"name=", "Local Area Connection" ,"source=static", "addr=",str1,
"mask=", str2};
Process pp = run.exec(command1);
The program is working fine.
Here I need to set interface name namely "Local Area Connection" in command.
Actually I should not hard code this and I should get this from
getting active network interface name. I have written program for
that, but the name I am getting is like "Intel(R) PRO/1000 PL Network
Connection - Net Firewall Miniport Interface". I am not getting name
as "Local Area Connection".
So please help me to resolve this issue.

See
http://forum.java.sun.com/thread.jspa?threadID=5239534&tstart=0
@OP Stop cross-posting just because you don't like the answers you are getting. You've been going on and on about this for a week now (if not longer) opening threads all over the place, and it is starting to get a little old.
Edit: And, if you want to see the aliases that netsh uses (and that were probably assigned using something at least similar to netsh), why don't you use netsh.
netsh show alias
As I said, this question is no longer a Java question, not even close. It is now an OS question.

Similar Messages

  • CSC order search not working on local windows machine.

    Hi All,
    I am facing an issue when I set up CSC9.1 with Search9.1 on local windows XP machine.
    I have setup everything for CSC with our ATG Commerce application.
    The same DB and configurations work on my other linux installations.
    Also, I have checked the JSP is present in the EAR at the correct location.
    Below is the error which is thrown on the console when I hit the search button on CSC order search page.
    If someone can help, it will be great. Thanks in advance.
    16:18:44,990 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception
    javax.servlet.ServletException: File "/DCS-CSR/panels/order/orderDetail.jsp" not found
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
    at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
    at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
    at atg.servlet.WrappingRequestDispatcher.include(WrappingRequestDispatcher.java:94)
    at atg.servlet.ServletUtil.invokeInclude(ServletUtil.java:3316)
    at atg.taglib.dspjsp.IncludeTag.doEndTag(IncludeTag.java:567)
    at org.apache.jsp.include.order.search.columnRenderer_jsp._jspx_meth_dsp_005finclude_005f0(columnRenderer_jsp.java:1695)
    at org.apache.jsp.include.order.search.columnRenderer_jsp._jspx_meth_c_005fwhen_005f2(columnRenderer_jsp.java:1562)
    at org.apache.jsp.include.order.search.columnRenderer_jsp._jspService(columnRenderer_jsp.java:344)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:336)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
    at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
    at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
    at atg.servlet.WrappingRequestDispatcher.include(WrappingRequestDispatcher.java:94)
    at atg.servlet.ServletUtil.invokeInclude(ServletUtil.java:3316)
    at atg.taglib.dspjsp.IncludeTag.doEndTag(IncludeTag.java:567)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_dsp_005finclude_005f1(orderSearchTable_jsp.java:1594)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_c_005fif_005f7(orderSearchTable_jsp.java:1540)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_c_005fif_005f6(orderSearchTable_jsp.java:1507)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_c_005fforEach_005f2(orderSearchTable_jsp.java:1468)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_c_005fforEach_005f1(orderSearchTable_jsp.java:1310)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_dsp_005fpage_005f1(orderSearchTable_jsp.java:726)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspx_meth_c_005fcatch_005f0(orderSearchTable_jsp.java:654)
    at org.apache.jsp.panels.order.orderSearchTable_jsp._jspService(orderSearchTable_jsp.java:129)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:336)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
    at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
    at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
    at atg.servlet.WrappingRequestDispatcher.include(WrappingRequestDispatcher.java:94)
    at atg.servlet.ServletUtil.invokeInclude(ServletUtil.java:3316)

    Hi Nitin,
    Thanks for your response.
    Please see my response to your questions below inline.
    This seems like a JBoss/OS problem. Can you check if you have the right permissions to the ear file - did you install JBoss as one user, and then install the ATG ear as another user, or does the JSP file/enclosing directory itself have some permissions issue? Did you start JBoss as a different user?
    <Abhinav> - I am using multiple instances of JBoss for CSC, Commerce, BCC and other apps. All applications except CSC works fine. I also checked the permissions on the containing folder in CSC EAR and other EARs, and all are same. Also I am the only user for my machine and have done everything via my login.
    Or, can you check JBoss startup logs and see if you have any relevant errors? Do you see any errors just before this exception in your server logs?
    <Abhinav> - No, this is the only error on console.
    Do you have the JDK installed - if you run javac in your command prompt, what do you get? -
    <Abhinav> - YES I have JDK. Heres what I see on CMD prompt -
    D:\Documents and Settings\abhinav.ranjan>javac -version
    javac 1.5.0_16
    javac: no source files
    Usage: javac <options> <source files>
    where possible options include:
    -g Generate all debugging info
    -g:none Generate no debugging info
    -g:{lines,vars,source} Generate only some debugging info
    -nowarn Generate no warnings
    -verbose Output messages about what the compiler is doing
    -deprecation Output source locations where deprecated APIs are used
    -classpath <path> Specify where to find user class files
    -cp <path> Specify where to find user class files
    -sourcepath <path> Specify where to find input source files
    -bootclasspath <path> Override location of bootstrap class files
    -extdirs <dirs> Override location of installed extensions
    -endorseddirs <dirs> Override location of endorsed standards path
    -d <directory> Specify where to place generated class files
    -encoding <encoding> Specify character encoding used by source files
    -source <release> Provide source compatibility with specified release
    -target <release> Generate class files for specific VM version
    -version Version information
    -help Print a synopsis of standard options
    -X Print a synopsis of nonstandard options
    -J<flag> Pass <flag> directly to the runtime system

  • Error in opening the display on local windows machine for DBCA GUI from rem

    Hi Chaps,
    I connected remote machine using SSH putty from my windows local PC
    I set the environmnet on my remote linux5 mahcine as
    $export DISPLAY=10.96.5.153:0.0
    and ran xclock on remote machine to see the GUI on my local machine(10.96.5.153). unfortunately I got an error
    'Error: Can't open display: 10.96.5.153:0.0'
    the whole idea of doing above is to invoke DBCA GUI on my local machine
    can you please enlight your experience? any solution to this will be appreciated.
    Thanks
    QA
    Edited by: QAbdul on May 11, 2010 3:55 AM

    Hi QA;
    I set the environmnet on my remote linux5 mahcine as
    $export DISPLAY=10.96.5.153:0.0
    and ran xclock on remote machine to see the GUI on my local machine(10.96.5.153). unfortunately I got an error
    'Error: Can't open display: 10.96.5.153:0.0'you are using X-forwarding? Or you are using program as VNC or Xming?
    If you are using VNC you have to follow:
    1. Check vnc is running or not
    service vncserver status << if its return Xvnc stopped
    service vncserver start
    2. vncserver (if you run first time it will ask you password, enter valid password)
    3. as a root user
    export DISPLAY=linux_machine_hostname(or IP of linux):1.0
    xhost +
    4. run Vncviwer from ur machine then enter
    linux_machine_hostname(or IP of linux):1.0 and pass
    5. From vnvviwer screen
    su - oracle
    Then you can run DBCA
    Regard
    Helios

  • Unable to change screen quality when accessing Window machine FROM my Mac

    Hi there,
    I've been playing around with a copy of Apple Remote Desktop 3.1 and I'm very happy with the results when connecting to a Mac Server from my MacBook. We have quite a slow line so I use the sceen adjuster on the top-right corner of the screen to make the remote screen black & white to speed up the connection. I have another server here which is Windows server running RealVNC. When I connect to that machine and try changing the screen quality to black & white, it does nothing Can anyone change the screen quality when connect to a Windows machine from a Mac running Remote Desktop? If so, could you tell me your setup please?
    Martin BG
    Life as an Apple Switcher - http://aurora7795.blogspot.com

    Go to System Preferences-->Display. Choose the biggest dimension there. The screen will turn blue and your display will change.

  • Reformat external hard drive for Windows machine using disk utility

    I have a Maxtor 160GB dual-interface external HD. I used it for my Mac OS X. I erased and reformated the hard drive on my Mac to MS-DOS using Disk Utility for use on my fathers Windows XP. I hooked the hard drive up to the Windows machine and the hard drive was visible in both Windows Explorer and on the task bar. I right clicked on the hard drive and selected Format. The formatting takes a while but at the end an error appears indicating the hard drive was not formattable. How can I get a MS-DOS formatted hard drive (from a Mac) to be used on a Windows XP machine with a NTFS format?

    Turns out it is possible:
    Maxtor Support..
    I would use your Disk Management utility within Windows to repartition and reformat the drive. To access Disk Management, right click on My Computer, go to Manage, and then choose Disk Management. Within Disk Management the drive should show in your list of disks (Disk 0,1,2 etc etc). I would delete any partitions that are on the drive. To delete a partition, just right-click on the partition and choose delete. Make sure you’re deleting the correct drive. Once the entire drive says unallocated then the drive should be ready to partition and format. Just right click within the Unallocated Space on the drive and choose the New Partition or New Volume option to set up the drive.
    I followed the instructions and everything worked.

  • How I can get the IP Address of a particular machine using host name

    I want to extract both IP Address as well as Machine name in the same network either I know IP address or machine name.
    Please tell me how I can do it.
    i.e. Either I pass IP Address or Machine name, it should return me Machine Name as well as IP Address in every case.

    hi,
    it is not working properly if i make a system as a application server and if i use the application server from another system using the server ip address it is returning the server ip address it is not returning the the application using system ip address how it can be done please explain

  • Changed Email address how can I still use my old downloads

    I changed email addresses and computers. I had a bunch of songs loaded to an old computer I have copied to my new one. Each time I try to play them I get a message wanting me to grant the new machine permissions, I do this but they still will not play??????
    Thanks.

    - Apps are locked to the account that purchased them.
    - To update apps you have to sign into the account that purchased the apps. If you have apps that need updating purchased from more than one account you have to update them one at a time until the remaining apps were purchased from one account.

  • Unable to connect to Windows machine using RDC

    I am trying to connect to a Windows server using Microsoft RDC on 10.4.11. My settings work fine for my 2013 iMac and 2009 Macbook Pro, with both RDC and Cord. I get the following messages in console (wondering if there is anything I can do to make this work in 10.4):
    ERROR: Failed to extract public key from certificate
    ERROR: recv: Connection reset by peer
    ERROR: Failed to extract public key from certificate
    ERROR: recv: Connection reset by peer
    ERROR: send: Invalid argument
    ERROR: Failed to extract public key from certificate
    ERROR: recv: Connection reset by peer
    2013-08-22 12:43:16.672 SyndicationAgent[22633] WARNING: Feed connection for CNET News RSSFeed failed: NSError "lost network connection" Domain=NSURLErrorDomain Code=-1005 UserInfo={
       NSErrorFailingURLKey = http://news.com.com/2547-1_3-0-5.xml;
       NSErrorFailingURLStringKey = "http://news.com.com/2547-1_3-0-5.xml";
       NSLocalizedDescription = "lost network connection";
    Thanks for the help.

    Hmmm, why news.com.com?
    I doubt it'll help with the Certificate, but might try CoVNC...
    http://sourceforge.net/projects/cotvnc/

  • Can't connect to X11 window server using 'localhost:0.0 help please

    Hi all,
    I am new to oracle, and its my first time to install oralce 9i to our hp ux version 11.23 remotely(ssh), and i got this error messages,
    $ ./runInstaller
    $ Initializing Java Virtual Machine from /data/OraInstall2008-06-17_05-21-49PM/jre/bin/java. Please wait...
    Exception in thread "main" java.lang.InternalError: Can't connect to X11 window server using 'md2:0.0' as the value of the DISPLAY variable.
    at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
    at sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:63)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Unknown Source)
    at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:58)
    at java.awt.Window.<init>(Window.java:188)
    at java.awt.Frame.<init>(Frame.java:315)
    at java.awt.Frame.<init>(Frame.java:262)
    at oracle.sysman.oii.oiic.OiicInstaller.main(OiicInstaller.java:593)
    $ xhost +
    xhost: unable to open display "md2:0.0"
    $ export DISPLAY=127.0.0.1:0.0
    $ xhost +
    xhost: unable to open display "127.0.0.1:0.0"
    $ export DISPLAY=:0
    $ xhost +
    xhost: unable to open display ":0"
    I already followed all the suggestion from the forum, like in
    Can't connect to X11 window server using '127.0.0.1:0.0'
    but still got the same error, someone please help ?? please...

    Can't connect to X11 window server using 'md2:0.0' asWell... Is there a X display server running? (on the hp-ux, if named md2)
    As suggested, you may need to talk to a sys admin / unix guy or girl.

  • Check IN a file from local user machine using Input file tag

    Hi
    We have created a webapplication using Oracle UCM. We have designed certain forms and want to give users an input field to upload images to content server.
    I included a input type file tag in my form and on submit redirected to a JSPX.
    I included on JSPX following tag when the form is submitted as follows
    <wcm:idcService service="CHECKIN_NEW_FORM" var="fileUpload">
    <wcm:idcParameter name="doFileCopy" value="1"/>
    <wcm:idcParameter name="dDocName" value="Test_Aakash"/>
    <wcm:idcParameter name="dDocTitle" value="Test_Aakash"/>
    <wcm:idcParameter name="dDocType" value="Document"/>
    <wcm:idcParameter name="dSecurityGroup" value="Public"/>
    <wcm:idcParameter name="dDocAuthor" value="anonymous"/>
    *<wcm:idcParameter name="primaryFile" value="C:/test.txt"/>*
    </wcm:idcService>
    I was hoping to pass primary path that a client will specify will allow the file to check in to the UCM server.But, to my dismay the tag expects that primary file be the path of file present on the Server and not on client machine accessing the webapplication.
    How can I check in file from client local machine to UCM server. I found default IdcService=CHECKIN_NEW_FORM through web-application allows one to select primary file from his local machine. But, this not the case when i do the same using the tag above. Please help how can i achieve the desired result.
    Thanks,
    Aakash
    Edited by: 856575 on Jul 19, 2011 12:31 AM
    Edited by: 856575 on Jul 19, 2011 12:32 AM

    Hi
    We have created a webapplication using Oracle UCM. We have designed certain forms and want to give users an input field to upload images to content server.
    I included a input type file tag in my form and on submit redirected to a JSPX.
    I included on JSPX following tag when the form is submitted as follows
    <wcm:idcService service="CHECKIN_NEW_FORM" var="fileUpload">
    <wcm:idcParameter name="doFileCopy" value="1"/>
    <wcm:idcParameter name="dDocName" value="Test_Aakash"/>
    <wcm:idcParameter name="dDocTitle" value="Test_Aakash"/>
    <wcm:idcParameter name="dDocType" value="Document"/>
    <wcm:idcParameter name="dSecurityGroup" value="Public"/>
    <wcm:idcParameter name="dDocAuthor" value="anonymous"/>
    *<wcm:idcParameter name="primaryFile" value="C:/test.txt"/>*
    </wcm:idcService>
    I was hoping to pass primary path that a client will specify will allow the file to check in to the UCM server.But, to my dismay the tag expects that primary file be the path of file present on the Server and not on client machine accessing the webapplication.
    How can I check in file from client local machine to UCM server. I found default IdcService=CHECKIN_NEW_FORM through web-application allows one to select primary file from his local machine. But, this not the case when i do the same using the tag above. Please help how can i achieve the desired result.
    Thanks,
    Aakash
    Edited by: 856575 on Jul 19, 2011 12:31 AM
    Edited by: 856575 on Jul 19, 2011 12:32 AM

  • Changing internet providers and need to change my address. Would like to use 3 apple addresses. How do I do this

    I'm unfamiliear with the proper terms, but I need to change internet providers and don't want to use the new provider's address. I understand that I can use an Apple address for 3 addresses. Help!

    Heard it in conversations. I'm tryinng to set up e-mail communications for my husband to his computer and 2 for myself (computer and phone) and also would like to use one  that's set aside for e-mail ordering, etc. so if my address is sold I won't get so much junk on my regular e-mail.

  • How to change IP address and subnet mask without using the sys-unconfig ?

    I have Solaris 10 x86. I've ran into problems using the sys-unconfig command
    to change hostname and IP address.
    How to I manually change the IP address and subnet mask values on Solaris 10 manually?
    Thanks.

    We just switched over a DNS server by using ifconfig, (same subnet), and killing named. seems to be working fine, anything I should look out for ?
    steps:
    Prep -
    - change name in /etc/hostname.e1000g0
    - change name and IP in /etc/hosts and /etc/nodename
    - # uname -S dnsint02
    Activate
    - unplug old dnsint02
    # ifconfig e1000g0 192.168.2.80
    # kill -9 [PID of named]
    Cleanup
    - Remove old key on clients I SSH from.
    - reconfigure backup software for new name/server combo.
    Edited by: HarryC on Jun 25, 2009 9:29 AM

  • Firefox keeps changing the address of some sites I use, adding 'www' when it isn't part of the URL. How do I stop this?

    I'm using Firefox 3.6.13
    I googled and found an answer I was willing to try, that required typing about:config into the location bar and changing some parameters. And guess what? It added www. to the beginning and told me it couldn't find the site.

    Ummm ... see above ... I '''did '''type about:config into the location bar - and it added www. to it. It's adding www. to '''everything '''in the location bar. It does it if I type in an address manually, if I follow a bookmark, and when I use the 'history' link.
    Thus it tried to take me to www.about:config and said it couldn't find it.

  • Applets load very slowly on 64bit Windows 7 using 64 bit Java

    Hi
    We have an applet that was very quick to load under windows XP. Some of our users are now using the 64 bit Windows 7 Operating system with 64 bit Java runtime environment and this applet takes up to 20 seconds to load.
    These machines have both the 32 bit and the 64 bit versions of Java loaded. JAVA_HOME is set to C:\Program Files (x86)\Java\jdk1.6.0_26 and the PATH has %JAVA_HOME%\bin;%JAVA_HOME%\jre\bin; at the start.
    I noticed on Windows XP that there was a Java Quick Starter service which is not present in Windows 7. I assume Windows 7 has it's own optimised java loader (which obviously insn't working) as the Control Panel -> Java -> Advanced -> Miscellaneos -> Java Quick Starter is greyed out.
    I've noticed that jqs.exe does not exist in the bin directory, and there is no C:\Program Files\Java\jre6\lib\deploy\jqs directory.
    So the bottom line is...How do I get my applet to load faster in 64 bit environments?
    Thank you in anticipation
    Richard

    JQS could not explain 20s startup. This must be something related to network - either config issue (e.g. DNS timeouts) or too many nework connections on launch?
    Enable tracing and java console, add
    deployment.trace.level=all
    to deployment.properties and see what is happening and where applet seem to stuck.
    Compare to 32 bit case.

  • Can't connect to windows 7 machine using microsoft remote desktop connection

    I am unable to connect from my home network to the Windows 7 Professional machine at my office, using either Microsoft Remote Desktop Connection (2.1.1) for Mac or the open source CoRD program.
    When connected to the office network (which is running MS Small Business Server 2011 Standard) both CoRD and MS RDC will connect to my desktop machine just fine! (My MacBook Pro runs Mountain Lion.)
    From my home network, MS RDC will complain that it cannot find the Windows computer if I just use the Windows computer name. If I use the Windows machine's iPV4 address, it works on it for a minute and then tosses up this error message:
    Using the IP address of the Windows machine, CoRD just grinds away for a minute or so and then times out.
    I should add that using Internet Exporer under Parallels from home, I can get a little closer to success (after fidding around with ActiveX controls for a bit). I will get to the Windows login screen, but then I am told that my user password is wrong (which makes no sense at all)!
    Okay, geniuses, have at it, and thanks in advance!!

    The genius for Microsoft products an be found onthe Microsoft forums for their Mac software:
    http://answers.microsoft.com/en-us/mac

Maybe you are looking for

  • Podcasts synced do not show up on iPod

    It's very strange, because podcasts downloaded on iTunes can be found on my iPod under Albums and Artistes, but not under the Podcast category. Same for video podcasts. Anyone has any idea why this is so? Please help! Thanks.

  • How do you unscyn an ipod touch from a library

    when the computer that it is synced with is not available... and the ipod has not been backed up...

  • Without Production order confirmation How to settle the cost of prd order

    Dear all, How to settle the cost production order with out production order confirmation.Any setting is there Or program. Regards, Naresh Redddy.

  • System setting donot allow any changes

    Hi All,   My ABAPer is getting the error written above as soon as he tries to make entries in the Ztable on our Production system..we currently having the temporary solution wherin we do settings as -No Automatic recording of changes  in Tx SCC4. but

  • Budget Profile & Availability Check

    Hi All We have a requirement to control Purchase Order amount , so that it should not exceed the allocated Budget , currently the Error message is coming when we are doing FG delivery /PGI & we are converting PR generated from PS into PO Please tell