Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8604971
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T02:42:32+00:00 2026-06-12T02:42:32+00:00

I have a cordova 2.0 app for android. I use the FileTransfer Plugin, to

  • 0

I have a cordova 2.0 app for android. I use the FileTransfer Plugin, to load some Data to my server. The first time, the upload is performed, everything works fine. But then I get a EPIPE (Broken Pipe) error. If I simply push the upload-button again, it works.

How can I prevent the error?

09-28 17:31:12.304: W/FileTransfer(29497): Error getting HTTP status code from connection.
09-28 17:31:12.304: W/FileTransfer(29497): java.net.SocketException: sendto failed: EPIPE (Broken pipe)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.io.IoBridge.maybeThrowAfterSendto(IoBridge.java:506)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.io.IoBridge.sendto(IoBridge.java:475)
09-28 17:31:12.304: W/FileTransfer(29497):  at java.net.PlainSocketImpl.write(PlainSocketImpl.java:507)
09-28 17:31:12.304: W/FileTransfer(29497):  at java.net.PlainSocketImpl.access$100(PlainSocketImpl.java:46)
09-28 17:31:12.304: W/FileTransfer(29497):  at java.net.PlainSocketImpl$PlainSocketOutputStream.write(PlainSocketImpl.java:269)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.net.http.ChunkedOutputStream.writeHex(ChunkedOutputStream.java:102)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.net.http.ChunkedOutputStream.writeBufferedChunkToSocket(ChunkedOutputStream.java:128)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.net.http.ChunkedOutputStream.close(ChunkedOutputStream.java:118)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.net.http.HttpEngine.readResponse(HttpEngine.java:804)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.net.http.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:274)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.net.http.HttpURLConnectionImpl.getResponseCode(HttpURLConnectionImpl.java:486)
09-28 17:31:12.304: W/FileTransfer(29497):  at org.apache.cordova.FileTransfer.createFileTransferError(FileTransfer.java:384)
09-28 17:31:12.304: W/FileTransfer(29497):  at org.apache.cordova.FileTransfer.upload(FileTransfer.java:316)
09-28 17:31:12.304: W/FileTransfer(29497):  at org.apache.cordova.FileTransfer.execute(FileTransfer.java:85)
09-28 17:31:12.304: W/FileTransfer(29497):  at org.apache.cordova.api.PluginManager$1.run(PluginManager.java:192)
09-28 17:31:12.304: W/FileTransfer(29497):  at java.lang.Thread.run(Thread.java:856)
09-28 17:31:12.304: W/FileTransfer(29497): Caused by: libcore.io.ErrnoException: sendto failed: EPIPE (Broken pipe)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.io.Posix.sendtoBytes(Native Method)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.io.Posix.sendto(Posix.java:146)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.io.BlockGuardOs.sendto(BlockGuardOs.java:177)
09-28 17:31:12.304: W/FileTransfer(29497):  at libcore.io.IoBridge.sendto(IoBridge.java:473)
09-28 17:31:12.304: W/FileTransfer(29497):  ... 14 more
09-28 17:31:12.319: E/FileTransfer(29497): {"target":"http:\/\/10.100.150.173:8081\/mobile110\/upload","source":"content:\/\/media\/external\/images\/media\/30","code":3}
09-28 17:31:12.319: E/FileTransfer(29497): java.net.SocketException: sendto failed: EPIPE (Broken pipe)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.io.IoBridge.maybeThrowAfterSendto(IoBridge.java:506)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.io.IoBridge.sendto(IoBridge.java:475)
09-28 17:31:12.319: E/FileTransfer(29497):  at java.net.PlainSocketImpl.write(PlainSocketImpl.java:507)
09-28 17:31:12.319: E/FileTransfer(29497):  at java.net.PlainSocketImpl.access$100(PlainSocketImpl.java:46)
09-28 17:31:12.319: E/FileTransfer(29497):  at java.net.PlainSocketImpl$PlainSocketOutputStream.write(PlainSocketImpl.java:269)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.net.http.ChunkedOutputStream.writeHex(ChunkedOutputStream.java:102)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.net.http.ChunkedOutputStream.writeBufferedChunkToSocket(ChunkedOutputStream.java:128)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.net.http.ChunkedOutputStream.write(ChunkedOutputStream.java:77)
09-28 17:31:12.319: E/FileTransfer(29497):  at java.io.DataOutputStream.write(DataOutputStream.java:98)
09-28 17:31:12.319: E/FileTransfer(29497):  at org.apache.cordova.FileTransfer.upload(FileTransfer.java:261)
09-28 17:31:12.319: E/FileTransfer(29497):  at org.apache.cordova.FileTransfer.execute(FileTransfer.java:85)
09-28 17:31:12.319: E/FileTransfer(29497):  at org.apache.cordova.api.PluginManager$1.run(PluginManager.java:192)
09-28 17:31:12.319: E/FileTransfer(29497):  at java.lang.Thread.run(Thread.java:856)
09-28 17:31:12.319: E/FileTransfer(29497): Caused by: libcore.io.ErrnoException: sendto failed: EPIPE (Broken pipe)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.io.Posix.sendtoBytes(Native Method)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.io.Posix.sendto(Posix.java:146)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.io.BlockGuardOs.sendto(BlockGuardOs.java:177)
09-28 17:31:12.319: E/FileTransfer(29497):  at libcore.io.IoBridge.sendto(IoBridge.java:473)
09-28 17:31:12.319: E/FileTransfer(29497):  ... 11 more
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T02:42:34+00:00Added an answer on June 12, 2026 at 2:42 am

    I’ve also been grappling with random intermittent HTTP status errors and have employed a workaround using a var to store retry status. I then increment this var if the transfer fail callback is called and retry the upload function up to 3 times (though it has not required more than 1 retry):

    var imageRetry = 0; // if upload errors, retry 3 times
    ...
    // file transfer fail callback
    function fail(error) {
        if(imageRetry < 3){
             imageRetry++;
             uploadPhoto(); // call upload function again
        }else{
            // normal failure handling
        }
    }
    

    Notes: Server is white listed and I’ve tried disabling chunkedMode as well with no success. I’m also not using normal or self-signed SSL. In my case, user can filter a photo before uploading. If no filter is applied, upload always succeeds. If user tries applying any filter, upload randomly fails with error code 3.

    (And yes, I know this solution is not totally ideal, but it’s better than an unrecovered failure.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an app built on Cordova and on some of my pages I
I have a Cordova/PhoneGap 2.0 based Android application, and I'm attemping to use intent-filters
I have a problem with my app. I'm working with Cordova 1.8.1 on Android
I develop an app for Android with Sencha Touch and Phonegap (cordova-2.0.0). I have
I have a Cordova app that runs the jQuery mobile framework and loads pages
I am building a PhoneGap/Cordova app and have a simple code that uses http://ricostacruz.com/jquery.transit/
I have an App made with phonegap (Cordova 1.5). The audio is in wav
I have built a an app in PhoneGap/Cordova and used the JQuery library for
I have a little HTML5 web app for mobile devices (running inside PhoneGap/Cordova). I
I have a PhoneGap/Cordova project that means I must use a combination of JQuery

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.