GetLocalhost() always throws UnknownHostException

Hi,
On my computer the method InetAddress.getLocalHost() always throws an UnknownHostException (JRE: jre-1_5_0_05-windows-i586-p.exe).
I found a topic for this trouble (http://forum.java.sun.com/thread.jspa?forumID=11&threadID=495321) but it doesn't help me.
I think there is a problem in my network configuration. Can you help me?
My OS is XP service pack 2.
>>>> Result of the command "ipconfig /all" (sorry it's in french, and I changed some number with "XXXX' for confidentiality)
Configuration IP de Windows
        Nom de l'h�te . . . . . . . . . . : myhost
        Suffixe DNS principal . . . . . . :
        Type de noud . . . . . . . . . . : Inconnu
        Routage IP activ� . . . . . . . . : Non
        Proxy WINS activ� . . . . . . . . : Non
Carte Ethernet Connexion au r�seau local:
        Suffixe DNS propre � la connexion :
        Description . . . . . . . . . . . : 3Com Gigabit LOM (3C940)
        Adresse physique . . . . . . . . .: 00-0C-6E-XX-XX-XX
        DHCP activ�. . . . . . . . . . . : Oui
        Configuration automatique activ�e . . . . : Oui
        Adresse IP. . . . . . . . . . . . : 192.168.0.2
        Masque de sous-r�seau . . . . . . : 255.255.255.0
        Adresse IP. . . . . . . . . . . . : XXXX::XXXX:XXXX:fe85:ebb4%4
        Passerelle par d�faut . . . . . . : 192.168.0.1
        Serveur DHCP. . . . . . . . . . . : 192.168.0.1
        Serveurs DNS . . . . . . . . . .  : 192.168.0.1
                                            fec0:0:0:ffff::1%1
                                            fec0:0:0:ffff::2%1
                                            fec0:0:0:ffff::3%1
        Bail obtenu . . . . . . . . . . . : mardi 18 octobre 2005 18:16:51
        Bail expirant . . . . . . . . . . : vendredi 21 octobre 2005
18:16:51
Carte Tunnel Teredo Tunneling Pseudo-Interface :
        Suffixe DNS propre � la connexion :
        Description . . . . . . . . . . . : Teredo Tunneling
Pseudo-Interface
        Adresse physique . . . . . . . . .: FF-FF-FF-FF-FF-FF-FF-FF
        DHCP activ�. . . . . . . . . . . : Non
        Adresse IP. . . . . . . . . . . . : XXXX::5445:5245:444f%5
        Passerelle par d�faut . . . . . . :
        NetBIOS sur TCPIP. . . . . . . .  : D�sactiv�
Carte Tunnel Automatic Tunneling Pseudo-Interface :
        Suffixe DNS propre � la connexion :
        Description . . . . . . . . . . . : Automatic Tunneling
Pseudo-Interface
        Adresse physique . . . . . . . . .: C0-A8-00-02
        DHCP activ�. . . . . . . . . . . : Non
        Adresse IP. . . . . . . . . . . . : fe80::5efe:192.168.0.2%2
        Passerelle par d�faut . . . . . . :
        Serveurs DNS . . . . . . . . . .  : fec0:0:0:ffff::1%1
                                            fec0:0:0:ffff::2%1
                                            fec0:0:0:ffff::3%1
        NetBIOS sur TCPIP. . . . . . . .  : D�sactiv�
Result of the "ping localhost" command:
ping localhost
Envoi d'une requ�te 'ping' sur myhost [::1] avec 32 octets de donn�es :
R�ponse de ::1 : temps<1ms
R�ponse de ::1 : temps<1ms
R�ponse de ::1 : temps<1ms
R�ponse de ::1 : temps<1ms
>>>> Result of the "route print" command
===========================================================================
Liste d'Interfaces
0x1 ........................... MS TCP Loopback interface
0x2 ...00 0c 6e XX XX XX ...... 3Com Gigabit LOM (3C940) - Miniport
d'ordonnance
ment de paquets ===========================================================================
===========================================================================
Itin�raires actifs :
Destination r�seau    Masque r�seau  Adr. passerelle   Adr. interface
M�trique
          0.0.0.0          0.0.0.0      192.168.0.1     192.168.0.2       20
     64.4.XXX.XXX  255.255.255.255      192.168.0.1     192.168.0.2       20
    65.54.XXX.XXX  255.255.255.255      192.168.0.1     192.168.0.2       20
        127.0.0.0        255.0.0.0        127.0.0.1       127.0.0.1       1
      192.168.0.0    255.255.255.0      192.168.0.2     192.168.0.2       20
      192.168.0.2  255.255.255.255        127.0.0.1       127.0.0.1       20
    192.168.0.255  255.255.255.255      192.168.0.2     192.168.0.2       20
   207.46.XXX.XXX  255.255.255.255      192.168.0.1     192.168.0.2       20
   207.68.XXX.XXX  255.255.255.255      192.168.0.1     192.168.0.2       20
        224.0.0.0        240.0.0.0      192.168.0.2     192.168.0.2       20
  255.255.255.255  255.255.255.255      192.168.0.2     192.168.0.2       1
Passerelle par d�faut :       192.168.0.1
===========================================================================
Itin�raires persistants :
  AucunThank you!

Just a guess, but try setting "Suffixe DNS propre � la connexion"
On my machine, I bring up the window Local Area Connection Status, then click on Properties, that brings up the Local Area Connection Properties window. Then I click on Internet Protocol (TCP/IP) in the list, then click the Properties button. That brings up the Internet Protocol (TCP/IP) Properties window; in there click Advanced button. That brings up the Advanced TCP/IP Settings window. In it click on the DNS tab. Down near the bottom is a box labeled "DNS suffix for this connection" and in it I have the suffix for my domain (berkeley.edu). I've never understood what the two boxes below are for/what they do.
This is just a stab in the dark; I have no idea if it will help.

Similar Messages

  • InetAddress.getLocalHost().getHostName()  throwing unknownHostException

    When i am executing this statement from a simple java program its working fine. But when I call the statement from JSP or servlet, its throwing UnknownhostException.
    I am using tomcat3.3.1 as web server running on Sun Solaris.
    Is there problem with setting of tomcat ???
    Please help me out.

    I tried nslookup at the shell prompt. It was showing unknown host for the ip address. I contacted our network people and came to know that the server is on internet and thats why it was not showing the local ip address host name in nslookup. Then I tried the internet ip address and host name of the server in the stetement and it worked out. Hope i am clear to u. Now the statement is running fine.
    Actually I was trying to send mail using Smtp class and while dong that it was throwing UnknownHostException. Then i found out the Intaddress.getLocalHost() was the stmt throwing this error. Now as I am giving the internet address for constructor of new SmtpClient() method, it is not giving this error and my mail is getting delivered. But it processis taking lot of time. It takes @ 15 minutes to send a mail.
    Can u help me out in this????
    Thanx for help.......

  • GetLocalHost throws UnknownHostException

    We have a situation where #getLocalHost will intermittently throw an UnknownHostException. I've checked etc/hosts and everything is normal, additionally, the machine is not using DNS.
    The exception is a little odd in that the local host name is listed twice:
    Caused by: java.net.UnknownHostException: myhost: myhost
          at java.net.InetAddress.getLocalHost(InetAddress.java:1191)If I look at the source, it seems that the actual exception is being thrown from #getAddressFromNameService on this line:
              byte_array = nameService.lookupAllHostAddr(host);Anyone run into this? What's odd is that it is intermittent, not predictable.
    R.

    Everyone gets annoyed at this one (especially when developing on a laptop). Here's a snippet of code I often use when testing code locally
        * Best attempt to get the local hostname, with or without the existence of a DNS entry.
        * @author [email protected]
        * @return Short version of the local hostname.
        * @throws UnknownHostException There is a problem with the DNS entry for this host and/or this JVM implementation
        * does not return the standard error string.
       public static String getLocalHostName() throws UnknownHostException {
          try {
               return (InetAddress.getLocalHost()).getHostName();
          } catch ( UnknownHostException uhe ) {
              String host = uhe.getMessage(); // host = "hostname: hostname"
              if ( host!=null ) {
                  int colon = host.indexOf(':');
                  if ( colon>0 ) {
                     return host.substring(0, colon); // Dangerous, this is JVM dependant code.
              throw uhe;
       }

  • URLStream.readBytes always throw out of memory exception (errorID=1000)

    When I try to load a file as 180MBytes by using URLStream.readBytes(). 
    In some PCs, it's OK.
    But in some PCs, there are always [out of memory] exception (errorID=1000) even such PC still had enough memory.
    For example:
       Total memory is 2G, current used is 1.43G, but URLStream.readBytes() still throw such exception.
    For file with little size such as 30M, there isn't such problem.
    Could any body give some suggestion?
    Best regards,
    Sourcecode is very simple like:
      var myStream:URLStream;
      var inputBytes: ByteArray = new ByteArray();
      ... do load ...
      // load by progressive event. I only deal progress load once, and ignore all later progressive load events.
      // for example first 500KBytes was read.
      myStream(inputBytes,inputBytes.length);
      // load again when all datas is loaded completely. For example, 180MBytes should be read.
      try {
        myStream(inputBytes,inputBytes.length);
      }  catch(e:*) {
        // warning log

    When I try to load a file as 180MBytes by using URLStream.readBytes(). 
    In some PCs, it's OK.
    But in some PCs, there are always [out of memory] exception (errorID=1000) even such PC still had enough memory.
    For example:
       Total memory is 2G, current used is 1.43G, but URLStream.readBytes() still throw such exception.
    For file with little size such as 30M, there isn't such problem.
    Could any body give some suggestion?
    Best regards,
    Sourcecode is very simple like:
      var myStream:URLStream;
      var inputBytes: ByteArray = new ByteArray();
      ... do load ...
      // load by progressive event. I only deal progress load once, and ignore all later progressive load events.
      // for example first 500KBytes was read.
      myStream(inputBytes,inputBytes.length);
      // load again when all datas is loaded completely. For example, 180MBytes should be read.
      try {
        myStream(inputBytes,inputBytes.length);
      }  catch(e:*) {
        // warning log

  • Site mailbox always throwing error code 0

    Hello,
    In our SharePoint environment I have configured site mailbox as per instruction given at technet site. While running the ps1 script to setup mailbox  I have not received any error. All setup has been ok.
    But while I have added site mailbox app to one of the subsites and clicking on site mailbox I am always getting error like "We are facing troubled while contacting with the SharePoint Server and error code is showing as 0 "
    I have checked the sharepoint log and found below error is throwing
    The scale out database mappings cache has been refreshed for service id 275cb0da-777d-4f5f-aff5-78558afa3be3.
    The new mappings are as follows:
    For database Data Source=SQL12-3\INST3;Initial Catalog=AppMng_Service_DB_290fd9b502d34f07bb428a52788d4a36;
    Integrated Security=True;Enlist=False;Pooling=True;Min Pool Size=0;Max Pool Size=100;Connect Timeout=15:
    range start 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00, range end NULL. b95d899c-c3a4-e04a-1a4b-6d2b28c555e5
    04/21/2014 10:47:21.96  w3wp.exe (0x21B8)                        0x13D4 SharePoint Portal Server       
    Site Mailbox                   ajv81 Exception  System.NullReferenceException: Object reference not set to an instance of an object.    
    at Microsoft.SharePoint.Portal.CollaborationMailboxInternalService.ExchangeHasPermissionsToSiteSubscriptionInternal(SPWeb web, CollaborationMailboxErrorCodes& errorCode)     at Microsoft.SharePoint.Portal.CollaborationMailboxInternalService.<>c__DisplayClassf.<ExchangeHasPermissionsToSiteSubscription>b__e()
    StackTrace:  at Microsoft.Office.Server.Native.dll: (sig=678c0f87-966f-4d99-9c94-b49e788d2672|2|microsoft.office.server.native.pdb, offset=131CE) at Microsoft.Office.Server.Native.dll: (offset=21BE5) b95d899c-c3a4-e04a-1a4b-6d2b28c555e5
    04/21/2014 10:47:21.96  w3wp.exe (0x21B8)    
    I am struggling to resolve this issue from last 7 days.
    Any help to resolve this issue would be appreciated.
    Thanks

    Hi,
     Please refer this one
    http://www.scinaptic.com/support/0109.html
    If its not helping you please let me know
    Sekar - Our life is short, so help others to grow
    Whenever you see a reply and if you think is helpful, click "Vote As Helpful"! And whenever
    you see a reply being an answer to the question of the thread, click "Mark As Answer

  • Is Sender File Adapter always throws error when there is no file?

    Hi,
    I have a simple question but can't find a straight answer to it. I have a Sender File adapter that configured to pick up file XXX* from FTP server every 1 hour. But a file can come every 2, 3, or 7 hours- no certain time.When there is no file I got "File not found " error. As we use alerts, this behaviour is not acceptable.
    Does this error comes always if there is no file? Any possible way to avoid this error ?
    Thanks for help.
    Nataliya

    Hi Ravi,
    I can see the error in Runtime Workbench under CC monitoring. To be precise it says:
    An error occurred while connecting to the FTP server '1X.1XX.XX.XX:21'. The FTP server returned the following error message: 'com.sap.aii.adapter.file.ftp.FTPEx: 552 RMS-E-FNF, file not found, ES4_SAP*'. For details, contact your FTP server vendor.
    My ftp server has the following set up:
    Server: xx.xxx.xx.xx
    Port:21
    Dataconnection:Active
    Timeout:120
    Connection secuirity: None
    User name .... etc set up.
    Connect mode: Per file transfer
    Transfer mode:Text
    QoS:EO
    Pollinterval: 120 (for test purposes)
    Processing Mode: delete
    Can it be that its a ftp server generates error and sends back to XI?
    Thanks,
    Nataliya

  • Running Composite with test client always throws ContentTypeException

    When I run the HelloWorldApp or SOAHelloApp from the test client in SOAConsole it always returns the following:
    oracle.j2ee.ws.saaj.ContentTypeException: Not a valid SOAP Content-Type: text/html
    Cause: oracle.j2ee.ws.saaj.ContentTypeException: Not a valid SOAP Content-Type: text/html
    I can't seem to see what I've done wrong. Any ideas?
    Thanks,
    -Richard Eichenlaub-
    Message was edited by:
    user613822

    Even after changing from "loacalhost" to "127.0.0.1" in the url, I am getting the same error when I do the invoke on the SOAHelloApp or HelloWorldApp:
    oracle.j2ee.ws.saaj.ContentTypeException: Not a valid SOAP Content-Type: text/html
    Cause: oracle.j2ee.ws.saaj.ContentTypeException: Not a valid SOAP Content-Type: text/html
    and sometimes I get the following error instead:
    javax.xml.soap.SOAPException: Bad response: 301 Moved Permanently
    Cause: javax.xml.soap.SOAPException: Bad response: 301 Moved Permanently
    Also, if you don't mind the newbie question, where is this HelloWorldApp coming from and how can I delete it? I followed the Installation Guide exactly to create and deploy the SOAHelloApp and SOAHelloProcess but then I end up with the following exceptions because there is some sort of duplication/overlap with the HelloWorldApp:
    08/01/15 00:59:39 Compiled class(es) "/root/jdevinstance/system11.1.1.0.22.47.96/o.j2ee/embedded-oc4j/deployed-composites/HelloWorldApp/sca_HelloWorld_rev1.0/SCA-INF/bpel/HelloWorld/src/bpel/helloworld/BPEL_BIN.java"
    08/01/15 00:59:39
    08/01/15 00:59:40 -------> CompositeDeployerTimer triggered
    08/01/15 00:59:40 -------> CompositeDeployerTimer trying http connection to http://cgbu-oel:8988
    08/01/15 00:59:41 -------> CompositeDeployerTimer: deploying composites ...
    08/01/15 00:59:41 --------->deploying composite model: HelloWorldApp/HelloWorld!1.0*2007-10-22_14-33-04_195
    Jan 15, 2008 12:59:41 AM oracle.webservices.service
    WARNING: Could not register service! Service with key 'soa-infra/HelloWorldApp/HelloWorld!1.0*2007-10-22_14-33-04_195/client' already exists in Local Service Registry
    Jan 15, 2008 12:59:41 AM oracle.webservices.service
    WARNING: Could not register service! Service with key 'soa-infra/HelloWorldApp/HelloWorld/client' already exists in Local Service Registry
    08/01/15 00:59:41 BPELServiceEngine=> loading component HelloWorldApp/HelloWorld
    08/01/15 00:59:41 BPELServiceEngine=> unloading component HelloWorldApp/HelloWorld
    Jan 15, 2008 12:59:42 AM oracle.integration.platform.PlatformMessages severeUnableDeployComposite
    SEVERE: Deployment of composite "HelloWorld" failed: An active composite for "HelloWorldApp/HelloWorld" has already been registered. Only one active composite is allowed..
    08/01/15 00:59:42 --------->deploying composite model: SOAHelloApp/SOAHelloComposite!1.0*2008-01-14_23-33-55_471
    08/01/15 00:59:42 BPELServiceEngine=> loading component SOAHelloApp/SOAHelloProcess
    08/01/15 00:59:42 BPELServiceEngine=> initing HelloWorldApp/HelloWorld
    08/01/15 00:59:42 BPELServiceEngine=> initing SOAHelloApp/SOAHelloProcess
    08/01/15 00:59:42 -------> CompositeDeployerTimer: done deploying composites. took 1 seconds.
    Jan 15, 2008 12:59:42 AM oracle.fabric.FabricMessages warningMBeanAlreadyExists
    WARNING: An MBean of name "soa-infra:J2EEApplication=HelloWorldApp,J2EEServer=standalone,name="HelloWorld",revision=1.0,type=SCAComposite" already exists. Unable to create MBean for this composite.
    Jan 15, 2008 12:59:43 AM oracle.webservices.service
    WARNING: Could not register service! Service with key 'soa-infra/SOAHelloApp/SOAHelloComposite!1.0*2008-01-14_23-33-55_471/client' already exists in Local Service Registry
    Jan 15, 2008 12:59:43 AM oracle.webservices.service
    WARNING: Could not register service! Service with key 'soa-infra/SOAHelloApp/SOAHelloComposite/client' already exists in Local Service Registry
    08/01/15 00:59:43 BPELServiceEngine=> loading component SOAHelloApp/SOAHelloProcess
    08/01/15 00:59:43 BPELServiceEngine=> unloading component SOAHelloApp/SOAHelloProcess
    Jan 15, 2008 12:59:43 AM oracle.as.config.notification.filesystem.WatchingDocumentChangeNotifier checkUsingListeners
    WARNING: Exception during change of a document.
    oracle.fabric.common.FabricDeploymentException {rootCauses=[oracle.fabric.common.FabricException: An active composite for "SOAHelloApp/SOAHelloComposite" has already been registered. Only one active composite is allowed.]}
         at oracle.integration.platform.blocks.deploy.DeployedCompositesManagerImpl.makeDeploymentChanges(DeployedCompositesManagerImpl.java:412)
         at oracle.integration.platform.blocks.deploy.DeployedCompositesManagerImpl.processDeployedCompositesModel(DeployedCompositesManagerImpl.java:218)
         at oracle.integration.platform.blocks.deploy.DeployedCompositesManagerImpl.processDeployedCompositesModel(DeployedCompositesManagerImpl.java:224)
         at oracle.integration.platform.blocks.deploy.OC4JApplicationListener.documentChanged(OC4JApplicationListener.java:135)
         at oracle.as.config.notification.oc4j.OC4JWatchingDocumentChangeNotifier$OC4JChangeListener.documentChanged(OC4JWatchingDocumentChangeNotifier.java:172)
         at oracle.as.config.notification.filesystem.WatchingDocumentChangeNotifier.checkUsingListeners(WatchingDocumentChangeNotifier.java:182)
         at oracle.as.config.notification.filesystem.WatchingDocumentChangeNotifier.checkFiles(WatchingDocumentChangeNotifier.java:125)
         at oracle.as.config.notification.filesystem.WatchingDocumentChangeNotifier.run(WatchingDocumentChangeNotifier.java:114)
         at java.lang.Thread.run(Thread.java:595)
    I assume this should not be ignored. Is that correct?
    Robin

  • BPMAuthorizationService Object always throws up null

    Hi All,
    I'm trying to retrieve BPMUser using oracle worklist api. Here's a piece of my code:
    try {
    IWorkflowServiceClient wfSvcClient = WorkflowServiceClientFactory.getWorkflowServiceClient(WorkflowServiceClientFactory.SOAP_CLIENT);
    IWorkflowContext wfCtx = wfSvcClient.getTaskQueryService().authenticate("bpeladmin", "welcome1", "jazn.com",null);
    BPMAuthorizationService bpmAuthSvc = wfSvcClient.getAuthorizationService(wfCtx.getIdentityContext());
    BPMUser bpmUser = bpmAuthSvc.lookupUser("bpeladmin");
    } catch (Exception e) {
    e.printStackTrace();
    The jars/directories i have included in my project are:
    bpm-infra.jar
    bpm-services.jar
    j2ee_1.3.01.jar
    jazncore.jar
    oc4jclient.jar
    orabpel.jar
    orabpel-common.jar
    orabpel-thirdparty.jar
    orasaaj.jar
    soap.jar
    wsclient_extended.jar
    xml.jar
    xmlparserv2.jar
    config
    schema
    My problem is BPMAuthorizationService object is always null. On the other hand i have no problems retrieving tasks, updating payload or approving tasks.
    Any help would be greatly appreciated.
    Thanks.

    No offense taken. It does look a little rough.. but for what I'm doing and how I'm doing it I don't think it is going to get much cleaner.
    Thanks for the reply, but I had two problems... one I wasn't thinking hashmap and was just looking at each entry.. never checked the next value for each entry...
    The other problem that was causing my jsp further down the line to crash when it tried to load the so I thought nonexistent form PTEN was a naming problem.
    I was putting the correct object into session and then naming it PTEN... later on I was pulling it from session looking for the name PTENForm. So when I corrected the "Form" it works correctly.

  • JSObject.getWindow(applet) always throws JSException with no message.

    I am looking for any possible reasons for this failure. We have an applet that runs fine in Microsoft VM on IE. As soon as we upgrade to use Java Plugin 1.4 and up, it stopped working because of the JSException being thrown when call is made to JSObject.getWindow(Applet).
    MAYSCRIPT parameter is set, applet is signed. Everything compiles fine.
    I also tried converting our HTML using HTMLConverter. But that didn't help.
    I spent last two days trying everything suggested on this forum regarding this problem, with no success.
    Does it matter where the call to getWindow is made? In our case, we pass our Applet as a constructor parameter of another Java class.
    eg. in method actionPerformed() of my Applet class I have:
    MyJavaScript myJs = new MyJavaScript(this);
    myJs.callScript();
    And MyJavaScript looks like this:
    public MyJavaScript(Applet applet)
    this.applet = applet;
    public void callScript()
    JSObject win = JSObject.getWindow(applet); // this line allways throws JSException when using Java Plugin, but works fine with MS VM.
    // rest of the code....
    Thanks in advance!

    OK, I think I know what our problem was. We overwrite our Applet's getAppletContext() method. And JSObject.getWindow(applet) calls this method internally.
    If I return super.getAppletContext(), everything works fine.
    Still, don't understand why it works in IE's Microsoft VM.
    Thanks.

  • WPF IDataErrorInfo - Validation not always throwing error

    Hi,
    In my project I have implemented IDataErrorInfo and ViewModelBase (from MvvmLight).
    I have added validation for two properties, 'TaskNumber' and 'Address'.  
    The validation for TaskNumber checks if the given TaskNumber exists and if not, should throw an error.
    However, the only way I can get any of the 2 properties to be validated is by first typing a
    valid TaskNumber in the textbox, and it is from then that the validation works and outlines the textbox in red when invalid TaskNumbers are typed.
    You can see my code here: http://1drv.ms/1Ch4n9r
    Refer to JobViewModel.cs and NewJobView.xaml
    Thanks

    The validation will fail whenever the indexer of the IDataError interface returns something else than NULL or an empty string for the given property. In your case this means that the GetValidationError method should return a non-empty string whenever you
    want to display the red border (or however your error template looks like) around the TextBox in the view:
    string IDataErrorInfo.this[string propertyName]
    get
    return GetValidationError(propertyName);
    If it the indexer returns a string when the view is initially loaded, you should see the red border.
    Obviously you need to upload a complete reproducable and runnable sample of your issue if you want anyone to be able to point out any error in your specific code. Just posting some uncompilable code is not enough for anyone to be able to reproduce your issue.
    Please remember to close your threads by marking helpful posts as answer and then start a new thread if you have a new question.

  • Why getString always throw exception

    Hello,
    I got not too much experience particularly on JDBC. Is there someone could help?
    I don't know why this piece code always catch exception?
    if (!(rs.getString("survey_report").equals("0000-00-00")))
    just so simple, I comment it, the whole jsp runs fine.
    the 'survey_report' is a column retrieved from a previous SQL statement, not null. DB is MySQL, datatype is Date.
    My platform is Tomcat 5.0.28 with MySQL 5.
    More confusing to me is the same code run on JRun 2, no problem.
    Will you have any idea on how I should fix it?
    Regards, dove

    bcss02 wrote:
    thanks for all of you the kindly help in advance.
    it's embarrassed that I can catch the full error message, not sure if i've missed something.
    here's my code.
    catch(Exception b)
    out.println("content error");
    b.printStackTrace();
    1) I can identify the part of code catch exception just the part I attached previously.
    2) whilst the exception is caught, i can only print out "content error" but the printStackTrace().
    Any further instruction on working the message out is welcome.
    rgds, doveprintStackTrace() prints to STDOUT by default. You seemed to have defined your own "out" PrintStream, rather than using System, so the place where you're seeing your "content error" is not the same place that printStackTrace produces it's output, but it will produce it. Try
    catch(Exception b)
        out.println("content error");
        b.printStackTrace(out);
    }Also, if you don't even know what Exception was thrown, how do you know it was that statement you originally posted that threw the exception?
    I absolutely refuse to believe that you have every rs.whatever statement wrapped in a try/catch block. And even if you do, using such general "error" messages as "content error", probably means that you have that same message in about 100 different places, which brings us back to the question about how you "know" that it was that statement that threw the exception?

  • FaceTime always throws this error "Could not sign in, Please check network connection and try again" whenever i try to log in

    Processor:      Intel Core i7 2.9 Ghz
    Memory:         8GB 1600Mhz DDR3
    HDD:              1TB (5400rpm)        
    Graphics:       Intel HD Graphics 4000

    Not sure if you have tried adding 8.8.8.8 to the DNS servers yet or if your messages app is a problem as well. for me the only fix was as follows:
    Back up all data.
    Triple-click anywhere in the line below on this page to select it:
    ~/Library/IdentityServices
    Right-click or control-click the line and select
              Services ▹ Reveal in Finder (or just Reveal)
    from the contextual menu.* A folder should open with an item selected. Move the selected item to the Trash. Log out or restart the computer, empty the Trash, and test.
    *If you don't see the contextual menu item, copy the selected text to the Clipboard by pressing the key combination  command-C. In the Finder, select
              Go ▹ Go to Folder...
    from the menu bar and paste into the box that opens by pressing command-V. You won't see what you pasted because a line break is included. Press return.
    Basically drag the items in the identityservices folder to trash log out, log back in, empty trash, start messages or facetime!!
    GOOD LUCK!

  • QAjmsSession.createReceiver(queue) Always Throws NullPointerException

    I am trying to get the aqjmsdemo01 sample code to work, but I consistently get a null pointer error when it tries to get a receiver from the session.
    The queue setup was as follows:
    begin
    DBMS_AQADM.CREATE_NP_QUEUE CACHE_INVALIDATION_QUEUE',false,'My Cache Invalidation Queue');
    DBMS_AQADM.START_QUEUE('CACHE_INVALIDATION_QUEUE', TRUE, TRUE);
    end;
    The code (where it fails is like this:
    System.out.println("Get the Queue") ;
    /* Get the Queue */
    /* Queue JMSMAPQ is created in aqjmsdemo02 */
    queue = ((AQjmsSession)qsess).getQueue("FLT", "CACHE_INVALIDATION_QUEUE") ;
    System.out.println("Create Receiver...") ;
    /* Create a queue receiever */
    qrecv = qsess.createReceiver(queue, "JMSCorrelationID='BLUE'") ; // <---- Fails Here
    Any ideas ?

    I am seeing a similar behavior only with createSubscriber.
    What is interesting to me is that it thinks that it is durable when the topic was created with the following:
         dbms_aqadm.create_np_queue (
              queue_name => 'px_jmx_lf_con_evt',
              multiple_consumers => true);
    Here is the stack trace.
    java.lang.NullPointerException
         at oracle.jms.AQjmsSession.getAQJmsSelector(AQjmsSession.java:2567)
         at oracle.jms.AQjmsSession.createDurableSubscriber(AQjmsSession.java:2537)
         at oracle.jms.AQjmsSession.createDurableSubscriber(AQjmsSession.java:2478)
         at oracle.jms.AQjmsSession.createDurableSubscriber(AQjmsSession.java:2290)
         at oracle.jms.AQjmsSession.createSubscriber(AQjmsSession.java:2237)
         at com.paychex.common.jms.Listener.setTopicListener(Listener.java:60)
         at com.paychex.common.jms.Listener.setMessageListener(Listener.java:45)
         at com.paychex.common.jms.ConnectionTests.testTopicListener(ConnectionTests.java:123)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at junit.framework.TestCase.runTest(TestCase.java:154)
         at junit.framework.TestCase.runBare(TestCase.java:127)
         at junit.framework.TestResult$1.protect(TestResult.java:106)
         at junit.framework.TestResult.runProtected(TestResult.java:124)
         at junit.framework.TestResult.run(TestResult.java:109)
         at junit.framework.TestCase.run(TestCase.java:118)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:397)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:281)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:173)
    Here is my stack trace:
    java.lang.NullPointerException
         at oracle.jms.AQjmsSession.getAQJmsSelector(AQjmsSession.java:2567)
         at oracle.jms.AQjmsSession.createDurableSubscriber(AQjmsSession.java:2537)
         at oracle.jms.AQjmsSession.createDurableSubscriber(AQjmsSession.java:2478)
         at oracle.jms.AQjmsSession.createDurableSubscriber(AQjmsSession.java:2290)
         at oracle.jms.AQjmsSession.createSubscriber(AQjmsSession.java:2237)
         at com.paychex.common.jms.Listener.setTopicListener(Listener.java:60)
         at com.paychex.common.jms.Listener.setMessageListener(Listener.java:45)
         at com.paychex.common.jms.ConnectionTests.testTopicListener(ConnectionTests.java:123)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at junit.framework.TestCase.runTest(TestCase.java:154)
         at junit.framework.TestCase.runBare(TestCase.java:127)
         at junit.framework.TestResult$1.protect(TestResult.java:106)
         at junit.framework.TestResult.runProtected(TestResult.java:124)
         at junit.framework.TestResult.run(TestResult.java:109)
         at junit.framework.TestCase.run(TestCase.java:118)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:397)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:281)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:173)

  • InetAddress UnknownHostException

    Hello,
    InetAddress.getLocalHost() is throwing a UnknownHostException when i'm running an app from within another app using Runtime.exec() and the command string "cmd /k appname". However it returns the hostname fine when the app is run from the command prompt!
    I'm guessing it's a environment veraiable or another configuration problem but have not been able to figure of what to missing so far.
    Any help would be appreicated

    Fixed the problem,
    requires SystemRoot to be set

  • Report Generation MS-Word always give error

    Hi
    I am using LV 2012 and MS Office 2010.
    I am using report generation toolkit to have a customised output report.
    When I specify output format as excel, I am able to get the desired result but when I specify output format as word, it always throws an error. I checked running the NI examples meant to give output in word but they all fail while the excel reports are perfect.
    Please find attached an error code for one of the example Sample Report(word).vi
    Please suggest the solution.
    Regards,
    Manbir
    Attachments:
    error_doc.JPG ‏20 KB

    We need to see the code in order to say "Here is the error" or "Try doing it this way".  It also gives us something to try, ourselves.  Do you know how to make "snippets", which are .PNG "pictures" of your code that you can simply put into the message using Insert Image?  We can then drag this image into a LabVIEW Block Diagram, and voilà, working code!
    BS

Maybe you are looking for