tjdam

tjdam

"Unsupported syscall" on Cloud Run

Hi!

I’ve been using GCP’s Cloud Run on my first Elixir project, and except for this (up to this point) little inconvenience, it’s been a smooth sail.

For most of requests hitting the server, the following message is logged 8 times right after (each with a different set of hex numbers):
Container Sandbox: Unsupported syscall getsockopt(0x1d,0x1,0xc,0x3ebce75fc6a8,0x3ebce75fc6ac,0x3ebce8980170). It is very likely that you can safely ignore this message and that this is not the cause of any error you might be troubleshooting. Please, refer to https://gvisor.dev/c/linux/amd64/getsockopt for more information.

I tried to Google this warning and all I could find was other people with similar issues but no actual solution. Some of them reported seeing this when using RabbitMQ which I believe is written in Erlang, so I was wondering if it’s related to OTP in any way.

I tried to read more about it, but I don’t even know where to start.
One thing I did try was to change the Linux distro I was using from Alpine to Debian, but nothing really changed.

Anyone here using Cloud Run had this issue at all?

Thanks!

Marked As Solved

batbabydev

batbabydev

Hope this helps someone …

For GCP and Cloud Run the solution is to consider the execution environments when deploying. There are trade offs between gen1 and gen2 environments. I have found gen2 to work well (and the logs disappear! :slight_smile: ) …

Documentation about this can be found Cloud Run Execution Environments

ps - thanks for the ranch info!! .. was really useful!! ..

Also Liked

kip

kip

ex_cldr Core Team

Perhaps the ranch socket acceptor (which is underneath cowboy which is underneath Phoenix) is setting this option? And perhaps 8 messages because you have one socket acceptor per scheduler (default maybe being one scheduler per core)?

Looks like the maybe relevant function in ranch sets socket options but I think these can also be overridden in configuration.

The option type does reference the option :priority.

Not a solution to your issue but perhaps a few pointers …

derek-zhou

derek-zhou

The third argument to getsockopt(2) is 0xc which is SO_PRIORITY See [socket(7) - Linux manual page] for details. So gvisor does not support this socket option.

Last Post!

tjdam

tjdam

Oh my god, thank you so much!!!

I can’t believe I can finally read my logs clearly hahah :sob:

Where Next?

Popular in Questions Top

vertexbuffer
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
Qqwy
Original source of discussion: This topic on the Pragmatic Programmers’ Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
gshaw
What is the idiomatic way of matching for not nil in Elixir? E.g., First way: defp halt_if_not_signed_in(conn, signed_in_account) when...
New
komlanvi
Hi everyone, I was playing with phoenix liveView but I run into an issue. I have a form and want to validate each input text when the te...
New
SoCreat
i’m a new one to elixir which editor can i use vs code? or atom? Thanks! :smiley:
New
WestKeys
Currently suffering from paralysis by [HTTP client] analysis. This is rather unusual in Elixirland as there tends to be consensus on the ...
New
JorisKok
I have a server on AWS, and was running a load test using artillery. When looking at the Phoenix dashboard I see the Ports going to 100% ...
New

Other popular topics Top

nobody
Hi! In PHP: $_SERVER[‘SERVER_ADDR’] - in Elixir? Searched the docs for ip address and the web, no good results. Thanks!
New
hariharasudhan94
Lets say I have map like this fetching from my database %{"_id" => #BSON.ObjectId<58eb1a7a9ad169198c3dXXXX>, "email" => ...
New
stefanchrobot
What’s the safe way to decode a JSON string into a struct? I want to avoid calling String.to_atom. Jason.decode can give me a map with st...
New
aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
jason.o
In the code below, if the create action is not set to accept “extra_key” as an input, it errors out with a message shown above. Is there ...
New

We're in Beta

About us Mission Statement