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

[buffermgrd] Use unix socket for redis connection #3190

Merged
merged 2 commits into from
Jun 21, 2024

Conversation

Junchao-Mellanox
Copy link
Collaborator

Why I did this?

Most of the DB connection in buffermgrd is using unix socket. There is only one DB connection which is using TCP socket. It brings a few drawback:

  1. TCP socket is less efficiency
  2. TCP socket may fail if loopback interface is down. It could cause following error:
Apr 29 16:53:25.586513 sonic ERR swss#buffermgrd: :- main: Runtime error: Unable to connect to redis: Cannot assign requested address

How I did this

Change TCP socket to unix socket

How I verify this

Manual test

@prsunny prsunny requested a review from dgsudharsan June 10, 2024 18:06
@Junchao-Mellanox
Copy link
Collaborator Author

Hi @prsunny , could you please kindly review this?

@Junchao-Mellanox
Copy link
Collaborator Author

Hi @prsunny , could you please review and sign-off?

@prsunny prsunny merged commit 78af15d into sonic-net:master Jun 21, 2024
17 checks passed
stephenxs pushed a commit to stephenxs/sonic-swss that referenced this pull request Jun 24, 2024
Why I did this?

Most of the DB connection in buffermgrd is using unix socket. There is only one DB connection which is using TCP socket. It brings a few drawback:

TCP socket is less efficiency
TCP socket may fail if loopback interface is down. It could cause following error:
@Junchao-Mellanox Junchao-Mellanox deleted the master-unix-socket branch June 24, 2024 03:24
mssonicbld pushed a commit to mssonicbld/sonic-swss that referenced this pull request Jun 24, 2024
Why I did this?

Most of the DB connection in buffermgrd is using unix socket. There is only one DB connection which is using TCP socket. It brings a few drawback:

TCP socket is less efficiency
TCP socket may fail if loopback interface is down. It could cause following error:
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202311: #3202

mssonicbld pushed a commit that referenced this pull request Jun 24, 2024
Why I did this?

Most of the DB connection in buffermgrd is using unix socket. There is only one DB connection which is using TCP socket. It brings a few drawback:

TCP socket is less efficiency
TCP socket may fail if loopback interface is down. It could cause following error:
mssonicbld pushed a commit to mssonicbld/sonic-swss that referenced this pull request Aug 2, 2024
Why I did this?

Most of the DB connection in buffermgrd is using unix socket. There is only one DB connection which is using TCP socket. It brings a few drawback:

TCP socket is less efficiency
TCP socket may fail if loopback interface is down. It could cause following error:
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202405: #3249

mssonicbld pushed a commit that referenced this pull request Aug 2, 2024
Why I did this?

Most of the DB connection in buffermgrd is using unix socket. There is only one DB connection which is using TCP socket. It brings a few drawback:

TCP socket is less efficiency
TCP socket may fail if loopback interface is down. It could cause following error:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants