roadrunner-server/roadrunner

[๐Ÿ› BUG]: GRPC server cannot be connected and sdnotify: not notified

theaungmyatmoe opened this issue ยท 3 comments

No duplicates ๐Ÿฅฒ.

  • I have searched for a similar issue in our bug tracker and didn't find any solutions.

What happened?

Running RR

โžœ  laravel-grpc rr serve
2024-05-27T02:31:13+0000        DEBUG   rpc             plugin was started      {"address": "tcp://127.0.0.1:6001", "list of the plugins with RPC methods:": ["lock", "informer", "app", "resetter"]}
[INFO] RoadRunner server started; version: 2024.1.2, buildtime: 2024-05-16T19:38:52Z
[INFO] sdnotify: not notified

Server cannot be connected via grpcui

โžœ  laravel-grpc 
โžœ  laravel-grpc grpcui -insecure -import-path ./proto/ -proto service.proto localhost:9001

Failed to dial target host "localhost:9001": dial tcp [::1]:9001: connect: connection refused
โžœ  laravel-grpc rr reset

Version (rr --version)

โžœ laravel-grpc rr --version
rr version 2024.1.2 (build time: 2024-05-16T19:38:52Z, go1.22.3), OS: darwin, arch: arm64

How to reproduce the issue?

version: '3'

rpc:
  listen: tcp://127.0.0.1:6001

grpc:
  listen: tcp://0.0.0.0:9001
  proto:
    - proto/service.proto
  tls:
    key: worker.key
    cert: worker.crt
  pool:
    command: 'php worker.php'
    num_workers: 2

Run RR

rr serve

Relevant log output

โžœ  laravel-grpc rr serve
2024-05-27T02:31:13+0000        DEBUG   rpc             plugin was started      {"address": "tcp://127.0.0.1:6001", "list of the plugins with RPC methods:": ["lock", "informer", "app", "resetter"]}
[INFO] RoadRunner server started; version: 2024.1.2, buildtime: 2024-05-16T19:38:52Z
[INFO] sdnotify: not notified

https://github.com/aungmyatmoethegreat/rr-grpc-reproduce

Tasks

Hey @aungmyatmoethegreat ๐Ÿ‘‹

  1. You're using key and cert in the configuration, but at the same time using grpcui -insecure insecure key. You should provide the key and cert to the grpcui and retry.
  2. sdnotify: not notified is not an error, it's an [INFO] message. sdnotify will automatically connect to the systemd socket if RR started via system unit file (aka daemon).
  3. Use debug log level to better understand what's happening inside RR (e.g.: grpc request arrived to the worker).

Closing since both cases are not RR bug. You are welcome to continue discussion here (issue not locked).

Hi, thank you for the quick reply @rustatian, I forgot to close this issue. It's working well btw without keys.

Good to know @aungmyatmoethegreat ๐Ÿ‘
Feel free to join our Discord server if you have more questions and enjoy RR ๐Ÿ˜ƒ