Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sleep to fix reth socket permissions #63

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

bakhtin
Copy link
Contributor

@bakhtin bakhtin commented Feb 25, 2025

After some testing I revealed a race condition in the Reth service init script.

We start Reth in the background with start-stop-daemon, wait for IPC socket to appear, and fix its permissions to allow shared access to Rbuilder. But it seems there is a race condition as Reth reverts the IPC socket permissions after we fixed it with chmod. It happens a couple of seconds after Reth starts and creates a IPC socket.

This PR introduces additional 5 seconds sleep to enable Reth to set IPC socket permissions before we chmod it later.

Signed-off-by: bakhtin <a@bakhtin.net>
Comment on lines +64 to +66

echo "Sleeping to fix socket permissions after reth has started..."
sleep 5
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or we can can move the permission setup to where it is needed. For example, if these permission are for the rbuilder to work with no errors, then we can move it to rbuilder init instead since it runs after the reth init, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants