Hyperledger fabric Error: 14 UNAVAILABLE: TCP Write failed












6















When chaincode container remains idle for some time then it stops with error:



ERROR [lib/handler.js] Chat stream with peer - on error: "Error: 14 UNAVAILABLE: EOFn    at createStatusError (/usr/local/src/node_modules/grpc/src/client.js:64:15)n    at ClientDuplexStream._emitStatusIfDone (/usr/local/src/node_modules/grpc/src/client.js:270:19)n at ClientDuplexStream._receiveStatus (/usr/local/src/node_modules/grpc/src/client.js:248:8)n    at /usr/local/src/node_modules/grpc/src/client.js:804:12"


And when the first request comes after idle time it gives an error of



Error: 14 UNAVAILABLE: TCP Write failed


After that for second request error changes to following:



Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18


From third request onwards all works fine.



I was using fabric-shim 1.2.0 but after upgrading it to 1.3.0 the error appears randomly.



I am using fabric 1.3.0.



Edit:
After upgrading fabric shim to 1.3.1, the error is changed to following:



error: [Orderer.js]: sendBroadcast - on error: "Error: 14 UNAVAILABLE: TCP Write failedn    at Object.exports.createStatusError (/app/node_modules/grpc/src/common.js:87:15)n    at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:235:26)n    at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)n    at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)n    at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)n    at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)n    at /app/node_modules/grpc/src/client_interceptors.js:1110:18"
Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18









share|improve this question

























  • For fabric 1.3, try using fabric-shim 1.3.1 or higher version of 1.3 (if available)

    – david_k
    Nov 23 '18 at 11:34













  • Okay. I will try by that but is it okay to use fabric-shim 1.3.1 with fabric 1.3.0?

    – Honey Shah
    Nov 23 '18 at 11:55











  • Yes, its fine to use that version

    – david_k
    Nov 23 '18 at 13:20











  • I tried by using fabric-shim 1.3.1 but the error is still persist

    – Honey Shah
    Nov 24 '18 at 9:12













  • @HoneyShah Did you find a solution to this problem?

    – Manoj P R
    Jan 10 at 12:59
















6















When chaincode container remains idle for some time then it stops with error:



ERROR [lib/handler.js] Chat stream with peer - on error: "Error: 14 UNAVAILABLE: EOFn    at createStatusError (/usr/local/src/node_modules/grpc/src/client.js:64:15)n    at ClientDuplexStream._emitStatusIfDone (/usr/local/src/node_modules/grpc/src/client.js:270:19)n at ClientDuplexStream._receiveStatus (/usr/local/src/node_modules/grpc/src/client.js:248:8)n    at /usr/local/src/node_modules/grpc/src/client.js:804:12"


And when the first request comes after idle time it gives an error of



Error: 14 UNAVAILABLE: TCP Write failed


After that for second request error changes to following:



Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18


From third request onwards all works fine.



I was using fabric-shim 1.2.0 but after upgrading it to 1.3.0 the error appears randomly.



I am using fabric 1.3.0.



Edit:
After upgrading fabric shim to 1.3.1, the error is changed to following:



error: [Orderer.js]: sendBroadcast - on error: "Error: 14 UNAVAILABLE: TCP Write failedn    at Object.exports.createStatusError (/app/node_modules/grpc/src/common.js:87:15)n    at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:235:26)n    at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)n    at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)n    at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)n    at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)n    at /app/node_modules/grpc/src/client_interceptors.js:1110:18"
Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18









share|improve this question

























  • For fabric 1.3, try using fabric-shim 1.3.1 or higher version of 1.3 (if available)

    – david_k
    Nov 23 '18 at 11:34













  • Okay. I will try by that but is it okay to use fabric-shim 1.3.1 with fabric 1.3.0?

    – Honey Shah
    Nov 23 '18 at 11:55











  • Yes, its fine to use that version

    – david_k
    Nov 23 '18 at 13:20











  • I tried by using fabric-shim 1.3.1 but the error is still persist

    – Honey Shah
    Nov 24 '18 at 9:12













  • @HoneyShah Did you find a solution to this problem?

    – Manoj P R
    Jan 10 at 12:59














6












6








6


2






When chaincode container remains idle for some time then it stops with error:



ERROR [lib/handler.js] Chat stream with peer - on error: "Error: 14 UNAVAILABLE: EOFn    at createStatusError (/usr/local/src/node_modules/grpc/src/client.js:64:15)n    at ClientDuplexStream._emitStatusIfDone (/usr/local/src/node_modules/grpc/src/client.js:270:19)n at ClientDuplexStream._receiveStatus (/usr/local/src/node_modules/grpc/src/client.js:248:8)n    at /usr/local/src/node_modules/grpc/src/client.js:804:12"


And when the first request comes after idle time it gives an error of



Error: 14 UNAVAILABLE: TCP Write failed


After that for second request error changes to following:



Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18


From third request onwards all works fine.



I was using fabric-shim 1.2.0 but after upgrading it to 1.3.0 the error appears randomly.



I am using fabric 1.3.0.



Edit:
After upgrading fabric shim to 1.3.1, the error is changed to following:



error: [Orderer.js]: sendBroadcast - on error: "Error: 14 UNAVAILABLE: TCP Write failedn    at Object.exports.createStatusError (/app/node_modules/grpc/src/common.js:87:15)n    at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:235:26)n    at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)n    at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)n    at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)n    at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)n    at /app/node_modules/grpc/src/client_interceptors.js:1110:18"
Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18









share|improve this question
















When chaincode container remains idle for some time then it stops with error:



ERROR [lib/handler.js] Chat stream with peer - on error: "Error: 14 UNAVAILABLE: EOFn    at createStatusError (/usr/local/src/node_modules/grpc/src/client.js:64:15)n    at ClientDuplexStream._emitStatusIfDone (/usr/local/src/node_modules/grpc/src/client.js:270:19)n at ClientDuplexStream._receiveStatus (/usr/local/src/node_modules/grpc/src/client.js:248:8)n    at /usr/local/src/node_modules/grpc/src/client.js:804:12"


And when the first request comes after idle time it gives an error of



Error: 14 UNAVAILABLE: TCP Write failed


After that for second request error changes to following:



Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18


From third request onwards all works fine.



I was using fabric-shim 1.2.0 but after upgrading it to 1.3.0 the error appears randomly.



I am using fabric 1.3.0.



Edit:
After upgrading fabric shim to 1.3.1, the error is changed to following:



error: [Orderer.js]: sendBroadcast - on error: "Error: 14 UNAVAILABLE: TCP Write failedn    at Object.exports.createStatusError (/app/node_modules/grpc/src/common.js:87:15)n    at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:235:26)n    at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)n    at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)n    at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)n    at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)n    at /app/node_modules/grpc/src/client_interceptors.js:1110:18"
Error: SERVICE_UNAVAILABLE
at ClientDuplexStream.broadcast.on (/app/node_modules/fabric-client/lib/Orderer.js:172:22)
at emitOne (events.js:116:13)
at ClientDuplexStream.emit (events.js:211:7)
at ClientDuplexStream._emitStatusIfDone (/app/node_modules/grpc/src/client.js:236:12)
at ClientDuplexStream._receiveStatus (/app/node_modules/grpc/src/client.js:213:8)
at Object.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:1290:15)
at InterceptingListener._callNext (/app/node_modules/grpc/src/client_interceptors.js:564:42)
at InterceptingListener.onReceiveStatus (/app/node_modules/grpc/src/client_interceptors.js:614:8)
at /app/node_modules/grpc/src/client_interceptors.js:1110:18






hyperledger-fabric hyperledger hyperledger-fabric-sdk-js






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jan 17 at 4:10







Honey Shah

















asked Nov 23 '18 at 10:58









Honey ShahHoney Shah

351111




351111













  • For fabric 1.3, try using fabric-shim 1.3.1 or higher version of 1.3 (if available)

    – david_k
    Nov 23 '18 at 11:34













  • Okay. I will try by that but is it okay to use fabric-shim 1.3.1 with fabric 1.3.0?

    – Honey Shah
    Nov 23 '18 at 11:55











  • Yes, its fine to use that version

    – david_k
    Nov 23 '18 at 13:20











  • I tried by using fabric-shim 1.3.1 but the error is still persist

    – Honey Shah
    Nov 24 '18 at 9:12













  • @HoneyShah Did you find a solution to this problem?

    – Manoj P R
    Jan 10 at 12:59



















  • For fabric 1.3, try using fabric-shim 1.3.1 or higher version of 1.3 (if available)

    – david_k
    Nov 23 '18 at 11:34













  • Okay. I will try by that but is it okay to use fabric-shim 1.3.1 with fabric 1.3.0?

    – Honey Shah
    Nov 23 '18 at 11:55











  • Yes, its fine to use that version

    – david_k
    Nov 23 '18 at 13:20











  • I tried by using fabric-shim 1.3.1 but the error is still persist

    – Honey Shah
    Nov 24 '18 at 9:12













  • @HoneyShah Did you find a solution to this problem?

    – Manoj P R
    Jan 10 at 12:59

















For fabric 1.3, try using fabric-shim 1.3.1 or higher version of 1.3 (if available)

– david_k
Nov 23 '18 at 11:34







For fabric 1.3, try using fabric-shim 1.3.1 or higher version of 1.3 (if available)

– david_k
Nov 23 '18 at 11:34















Okay. I will try by that but is it okay to use fabric-shim 1.3.1 with fabric 1.3.0?

– Honey Shah
Nov 23 '18 at 11:55





Okay. I will try by that but is it okay to use fabric-shim 1.3.1 with fabric 1.3.0?

– Honey Shah
Nov 23 '18 at 11:55













Yes, its fine to use that version

– david_k
Nov 23 '18 at 13:20





Yes, its fine to use that version

– david_k
Nov 23 '18 at 13:20













I tried by using fabric-shim 1.3.1 but the error is still persist

– Honey Shah
Nov 24 '18 at 9:12







I tried by using fabric-shim 1.3.1 but the error is still persist

– Honey Shah
Nov 24 '18 at 9:12















@HoneyShah Did you find a solution to this problem?

– Manoj P R
Jan 10 at 12:59





@HoneyShah Did you find a solution to this problem?

– Manoj P R
Jan 10 at 12:59












1 Answer
1






active

oldest

votes


















0














This issue seems related to grpc version change , can you try with stable grpc version






share|improve this answer
























  • Please keep suggestions in comments and use answers for definitive answers.

    – Keval Dave
    Mar 12 at 12:42











  • Can you please suggest how to change grpc version?

    – Honey Shah
    Mar 14 at 4:09











  • npm install grpc <grpc version >

    – kamlesh nagware
    Mar 19 at 9:32











  • @kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

    – Honey Shah
    Mar 20 at 3:46












Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53445400%2fhyperledger-fabric-error-14-unavailable-tcp-write-failed%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














This issue seems related to grpc version change , can you try with stable grpc version






share|improve this answer
























  • Please keep suggestions in comments and use answers for definitive answers.

    – Keval Dave
    Mar 12 at 12:42











  • Can you please suggest how to change grpc version?

    – Honey Shah
    Mar 14 at 4:09











  • npm install grpc <grpc version >

    – kamlesh nagware
    Mar 19 at 9:32











  • @kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

    – Honey Shah
    Mar 20 at 3:46
















0














This issue seems related to grpc version change , can you try with stable grpc version






share|improve this answer
























  • Please keep suggestions in comments and use answers for definitive answers.

    – Keval Dave
    Mar 12 at 12:42











  • Can you please suggest how to change grpc version?

    – Honey Shah
    Mar 14 at 4:09











  • npm install grpc <grpc version >

    – kamlesh nagware
    Mar 19 at 9:32











  • @kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

    – Honey Shah
    Mar 20 at 3:46














0












0








0







This issue seems related to grpc version change , can you try with stable grpc version






share|improve this answer













This issue seems related to grpc version change , can you try with stable grpc version







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 12 at 12:23









kamlesh nagwarekamlesh nagware

323




323













  • Please keep suggestions in comments and use answers for definitive answers.

    – Keval Dave
    Mar 12 at 12:42











  • Can you please suggest how to change grpc version?

    – Honey Shah
    Mar 14 at 4:09











  • npm install grpc <grpc version >

    – kamlesh nagware
    Mar 19 at 9:32











  • @kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

    – Honey Shah
    Mar 20 at 3:46



















  • Please keep suggestions in comments and use answers for definitive answers.

    – Keval Dave
    Mar 12 at 12:42











  • Can you please suggest how to change grpc version?

    – Honey Shah
    Mar 14 at 4:09











  • npm install grpc <grpc version >

    – kamlesh nagware
    Mar 19 at 9:32











  • @kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

    – Honey Shah
    Mar 20 at 3:46

















Please keep suggestions in comments and use answers for definitive answers.

– Keval Dave
Mar 12 at 12:42





Please keep suggestions in comments and use answers for definitive answers.

– Keval Dave
Mar 12 at 12:42













Can you please suggest how to change grpc version?

– Honey Shah
Mar 14 at 4:09





Can you please suggest how to change grpc version?

– Honey Shah
Mar 14 at 4:09













npm install grpc <grpc version >

– kamlesh nagware
Mar 19 at 9:32





npm install grpc <grpc version >

– kamlesh nagware
Mar 19 at 9:32













@kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

– Honey Shah
Mar 20 at 3:46





@kamleshnagware I haven't manually installed grpc. I mean it is inbuilt to fabric sdk.

– Honey Shah
Mar 20 at 3:46




















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53445400%2fhyperledger-fabric-error-14-unavailable-tcp-write-failed%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







這個網誌中的熱門文章

Xamarin.form Move up view when keyboard appear

Post-Redirect-Get with Spring WebFlux and Thymeleaf

Anylogic : not able to use stopDelay()