Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-3619

Unable to use hudson-cli.jar - getting Premature EOF

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • cli
    • None
    • Platform: PC, OS: Windows XP

      I cannot get hudson-cli to work?
      I'm not running any proxys - and hudson itself works fine.
      I have downloaded hudson-cli.jar from the web page at
      http://61a213.prod.mycompany.local:8080/cli

      There is a Windows firewall running on the hudson server, and I am not allowed
      to disable it. Here's the error I get after appr. 60 seconds:

      C:\>java -jar hudson-cli.jar -s http://61a213.prod.mycompany.local:8080/ help
      Exception in thread "main" java.io.IOException: Premature EOF
      at sun.net.www.http.ChunkedInputStream.readAheadBlocking(Unknown Source)
      at sun.net.www.http.ChunkedInputStream.readAhead(Unknown Source)
      at sun.net.www.http.ChunkedInputStream.read(Unknown Source)
      at java.io.FilterInputStream.read(Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read
      (Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read
      (Unknown Source)
      at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read
      (Unknown Source)
      at hudson.remoting.Channel.<init>(Channel.java:310)
      at hudson.remoting.Channel.<init>(Channel.java:251)
      at hudson.remoting.Channel.<init>(Channel.java:239)
      at hudson.cli.CLI.main(CLI.java:70)

      My java version:
      c:\>Java -version
      java version "1.6.0_13"
      Java(TM) SE Runtime Environment (build 1.6.0_13-b03)
      Java HotSpot(TM) Client VM (build 11.3-b02, mixed mode, sharing)

      Hudson version: 1.303

          [JENKINS-3619] Unable to use hudson-cli.jar - getting Premature EOF

          nielsull created issue -

          I get the same error:

          • hudson is running on a linux machine which will only allow connects on port 20080.
          • I forward the port via ssh to localhost:20080 to avoid sending clear text passwords over an unsafe
            connection.
          • I run the cli from my client on MacOSX and get:
            [mirko@borg Software]$ java -jar hudson-cli.jar -s 'http://localhost:20080/' help
            Exception in thread "main" java.io.IOException: Premature EOF
            at sun.net.www.http.ChunkedInputStream.readAheadBlocking(ChunkedInputStream.java:538)
            at sun.net.www.http.ChunkedInputStream.readAhead(ChunkedInputStream.java:582)
            at sun.net.www.http.ChunkedInputStream.read(ChunkedInputStream.java:669)
            at java.io.FilterInputStream.read(FilterInputStream.java:116)
            at
            sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:2504)
            at
            sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:2499)
            at
            sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:2488)
            at hudson.remoting.Channel.<init>(Channel.java:310)
            at hudson.remoting.Channel.<init>(Channel.java:251)
            at hudson.remoting.Channel.<init>(Channel.java:239)
            at hudson.cli.CLI.main(CLI.java:70)

          Mirko Friedenhagen added a comment - I get the same error: hudson is running on a linux machine which will only allow connects on port 20080. I forward the port via ssh to localhost:20080 to avoid sending clear text passwords over an unsafe connection. I run the cli from my client on MacOSX and get: [mirko@borg Software] $ java -jar hudson-cli.jar -s 'http://localhost:20080/' help Exception in thread "main" java.io.IOException: Premature EOF at sun.net.www.http.ChunkedInputStream.readAheadBlocking(ChunkedInputStream.java:538) at sun.net.www.http.ChunkedInputStream.readAhead(ChunkedInputStream.java:582) at sun.net.www.http.ChunkedInputStream.read(ChunkedInputStream.java:669) at java.io.FilterInputStream.read(FilterInputStream.java:116) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:2504) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:2499) at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:2488) at hudson.remoting.Channel.<init>(Channel.java:310) at hudson.remoting.Channel.<init>(Channel.java:251) at hudson.remoting.Channel.<init>(Channel.java:239) at hudson.cli.CLI.main(CLI.java:70)

          Added myself as Cc

          Mirko Friedenhagen added a comment - Added myself as Cc

          I get the same error when on the linux box, in the wrapper log I get:
          INFO | jvm 1 | 2009/05/04 22:30:14 | May 4, 2009 10:30:14 PM hudson.remoting.Channel$ReaderThread run
          INFO | jvm 1 | 2009/05/04 22:30:14 | SEVERE: I/O error in channel HTTP full-duplex channel aac41a55-56f6-4709-9913-af6d9f5091ea
          INFO | jvm 1 | 2009/05/04 22:30:14 | java.io.StreamCorruptedException: invalid type code: 0D
          INFO | jvm 1 | 2009/05/04 22:30:14 | at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1356)
          INFO | jvm 1 | 2009/05/04 22:30:14 | at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
          INFO | jvm 1 | 2009/05/04 22:30:14 | at hudson.remoting.Channel$ReaderThread.run(Channel.java:727)
          INFO | jvm 1 | 2009/05/04 22:30:14 | May 4, 2009 10:30:14 PM hudson.model.FullDuplexHttpChannel$1 onDead
          INFO | jvm 1 | 2009/05/04 22:30:14 | INFO: Duplex-HTTP session aac41a55-56f6-4709-9913-af6d9f5091ea is terminated

          Mirko Friedenhagen added a comment - I get the same error when on the linux box, in the wrapper log I get: INFO | jvm 1 | 2009/05/04 22:30:14 | May 4, 2009 10:30:14 PM hudson.remoting.Channel$ReaderThread run INFO | jvm 1 | 2009/05/04 22:30:14 | SEVERE: I/O error in channel HTTP full-duplex channel aac41a55-56f6-4709-9913-af6d9f5091ea INFO | jvm 1 | 2009/05/04 22:30:14 | java.io.StreamCorruptedException: invalid type code: 0D INFO | jvm 1 | 2009/05/04 22:30:14 | at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1356) INFO | jvm 1 | 2009/05/04 22:30:14 | at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351) INFO | jvm 1 | 2009/05/04 22:30:14 | at hudson.remoting.Channel$ReaderThread.run(Channel.java:727) INFO | jvm 1 | 2009/05/04 22:30:14 | May 4, 2009 10:30:14 PM hudson.model.FullDuplexHttpChannel$1 onDead INFO | jvm 1 | 2009/05/04 22:30:14 | INFO: Duplex-HTTP session aac41a55-56f6-4709-9913-af6d9f5091ea is terminated

          We suspect this error depends on the servlet container, so please report how you
          run the server.

          Kohsuke Kawaguchi added a comment - We suspect this error depends on the servlet container, so please report how you run the server.
          Kohsuke Kawaguchi made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]

          The wrapper just starts the included winstone container.

          Regards
          Mirko

          Mirko Friedenhagen added a comment - The wrapper just starts the included winstone container. Regards Mirko

          166_MMX added a comment -

          assigned the issue to the proper component

          166_MMX added a comment - assigned the issue to the proper component
          166_MMX made changes -
          Component/s New: cli [ 15624 ]
          Component/s Original: other [ 15490 ]

          Yama Tksh added a comment -

          [for your reference] We are in similar but slightly different? trouble. @see JENKINS-7052

          Thanks, Tksh

          Yama Tksh added a comment - [for your reference] We are in similar but slightly different? trouble. @see JENKINS-7052 Thanks, Tksh

            Unassigned Unassigned
            nielsull nielsull
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: