Search code examples
javagrpcgrpc-javaprotoc

Issue while generating grpc Java stub using protoc v3


I am using Protoc version 3.0 on Ubuntu 14.4 and issuing command

 protoc -I ./ --java_out=. --grpc_out=. --plugin=protoc-gen-grpc=/opt/jvision/grpc/oc/protoc-gen-grpc-java-1.0.0-linux-x86_32.exe ./agent.proto

Same issue for python described here

I am getting this error:

/opt/jvision/grpc/oc/protoc-gen-grpc-java-1.0.0-linux-x86_32.exe: program not found or is not executable
--grpc_out: protoc-gen-grpc: Plugin failed with status code 1.

However if i skip stub part and just issue command

protoc  -I=./ --java_out=. ./agent.proto

It works perfectly fine. Wondering what i am missing.


Solution

  • I haven't enough reputation for comments, so this is questions to author:

    1. Have you checked "/opt/jvision/grpc/oc/protoc-gen-grpc-java-1.0.0-linux-x86_32.exe" path? Is it correct?
    2. Does it have executable flag?
    3. Is it compiled for linux?