0

I am currently working on a client-server application using gRPC and Google Protocol Buffers. The client is meant to run on a Windows 10 PC and the server on an Linux ARM32 machine.

After implementing a service with 10 RPCs on the server-side, I encountered an issue regarding the RPCs limit per service. It seems like the maximum amount which I can add inside the service is 8. If I add more than 8, the server from the target machine will crash with a Segmentation Fault (core dumped).

I tried to reproduce the exact same issue on the hello world example from gRPC by adding multiple RPCs on top of what it was already implemented so I can exclude the possibility of crashing because of other API I'm working with on the application. But the segmentation fault occurs in this case too.

Does anyone know if there's a limitation about the number of RPCs per service?

Environment

  • gRPC version: 1.31.1 (on Ubuntu 16.04)
  • protoc version: 3.12.2 (on Ubuntu 16.04)
  • Client side: Python 3.7.4, grpcio 1.31.0, grpcio-tools 1.31.0
  • Server side: C++, compiled with gcc 6.1 on Ubuntu 16.04 for Linux ARM32

Thanks!

UPDATE: I continued the investigations and I tried to run the example on a VM with Ubuntu 20.04 and gRPC 1.30.1. There was no segmentation fault, it worked, so it confirmed that there's no limit for RPCs/service. It is probably an issue with the cross-compiled gRPC or with the version itself, I will continue to investigate and update this post.

Andreea
  • 11
  • 2
  • 1
    A segfault is always the result of a bug in the code, every time. There is a bug somewhere in your code that you will need to find and fix. – Sam Varshavchik Oct 16 '20 at 12:24
  • Have you tried to fix it so that it *doesn't* crash with a segmentation fault? – user253751 Oct 16 '20 at 12:26
  • If there was supposed to be a limit, they would tell you about it. – user253751 Oct 16 '20 at 12:26
  • @user253751 yes, if I have 8 (or less) RPCs in a service, the application works fine. Also, in the first place, I tried to detect which was the RPC that could crash the application so I could investigate the protos definition in case I did a mistake there, but those protos only contained a bool and a string variable, nothing fancy. – Andreea Oct 16 '20 at 13:34
  • I suggest you start from basics: why does the application crash? What thing is it trying to do that causes it to crash (for example, dereferencing an invalid pointer)? Why is it doing that thing? What is it supposed to do instead? Is this a bug in the library? – user253751 Oct 16 '20 at 13:41

0 Answers0