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

fix: use atomicwrites to back up /etc/resolv.conf more robustly #3828

Merged
merged 7 commits into from
Mar 4, 2024

Conversation

ReactorScram
Copy link
Collaborator

Part of a small yak shave for #3817

The atomicwrites lib uses the atomic rename trick and does correct fsyncs for us, so if we lose power while rewriting or reverting /etc/resolv.conf, it should always be in a recoverable state. (Unless the hard drive lies about fsync, but then it's beyond our control.)

@ReactorScram ReactorScram added area/connlib Firezone's core connectivity library area/linux_client Linux client labels Mar 1, 2024
@ReactorScram ReactorScram self-assigned this Mar 1, 2024
Copy link

vercel bot commented Mar 1, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
firezone ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 1, 2024 8:16pm

Copy link

github-actions bot commented Mar 1, 2024

Terraform Cloud Plan Output

Plan: 8 to add, 7 to change, 8 to destroy.

Terraform Cloud Plan

Copy link

github-actions bot commented Mar 1, 2024

Performance Test Results

TCP

Test Name Received/s Sent/s Retransmits
direct-tcp-client2server 65.2 MiB (-0%) 65.8 MiB (-0%) 64 (+36%)
direct-tcp-server2client 55.3 MiB (+1%) 55.7 MiB (+1%) 34 (-6%)
relayed-tcp-client2server 29.2 MiB (-3%) 32.0 MiB (+2%) 0 (-100%)
relayed-tcp-server2client 29.1 MiB (+2%) 30.9 MiB (+1%) 207 (+29%)

UDP

Test Name Total/s Jitter Lost
direct-udp-client2server 50.0 MiB (+0%) 0.18ms (-41%) 0.00% (+Infinity%)
direct-udp-server2client 50.0 MiB (-0%) 0.21ms (+21%) 0.00% (NaN%)
relayed-udp-client2server 50.0 MiB (+0%) 0.55ms (+248%) 20.90% (+20%)
relayed-udp-server2client 50.0 MiB (-0%) 0.26ms (-20%) 19.02% (-5%)

Base automatically changed from refactor/etc-resolv-conf to main March 1, 2024 19:20
@ReactorScram ReactorScram marked this pull request as ready for review March 1, 2024 20:06
Copy link
Member

@jamilbk jamilbk left a comment

Choose a reason for hiding this comment

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

Not sure if this was ready, but lgtm

@ReactorScram ReactorScram added this pull request to the merge queue Mar 4, 2024
Merged via the queue into main with commit c6c4624 Mar 4, 2024
66 checks passed
@ReactorScram ReactorScram deleted the fix/atomic-resolv-conf branch March 4, 2024 16:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/connlib Firezone's core connectivity library area/linux_client Linux client
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants