Skip to content

Instantly share code, notes, and snippets.

@danidiaz
Last active August 2, 2021 06:28
Show Gist options
  • Select an option

  • Save danidiaz/dd19131c835d4a006612cc85cbd31c43 to your computer and use it in GitHub Desktop.

Select an option

Save danidiaz/dd19131c835d4a006612cc85cbd31c43 to your computer and use it in GitHub Desktop.

JVNS networking zine.

Task-centered iproute2 user guide

iproute2 is the Linux networking toolkit that replaced net-tools (ifconfig, vconfig, route, arp etc.). The ip command comes from the iproute2 package, as well as tc and a few others.

Note that iproute2 is not new, it has been a standard Linux tool since the early 2000's. It's been included in every distro by default, or at least available from the repos for a very long time.

If you are not sure if something is a correct host address, use ipcalc or similar program to check.

traffic shaping with tc. more. more. more. more.

TC bundled with iproute2 package in Debian.

How To Use IPRoute2 Tools to Manage Network Configuration on a Linux VPS

Anatomy of a Linux DNS Lookup – Part I. Part II. Part III. Part IV. Part V.

that’s exactly the reason why I always use getent hosts example.org when shell scripting. it uses the c call, queries the system’s host database and honors nsswitch.

DNS lookups in Kubernetes

A journey to searching Have I Been Pwned database in 49μs

Must, Should, Don't Care: TCP Conformance in the Wild

cows

observability stuff

Migrating Dropbox from Nginx to Envoy

Logging tracing and metrics. bg talk.

The Illustrated TLS Connection hn

How to take back control of /etc/resolv.conf on Linux

NAT Slipstreaming

Wifi collisions

How to get better wireless signal

visual guide to SSH tunnels

One thing to add is that you can even open tunnels during an interactive session without disconnection.

To do this, type the escape command sequence ~C (will not show) and it will drop you to the control prompt. You can then add tunnels.

 ssh>
 ssh> -L 8000:localhost:9000 
 Forwarding port.

change your mac address

A brief history of router architecture

Routing the technical interview

Protocol detection and opaque ports in Linkerd

Liberating Kubernetes From Kube-proxy and Iptables. iptables

Slack's Migrating Millions of Websockets from HAProxy to Envoy.

The Sisyphean Task of DNS Client Config on Linux

the case of the 50ms request

Netcat – All you need to know

Things I hate about Rust

Common Rust Lifetime Misconceptions. lobsters

c++

i start most of my big objects by deleting the copy constructor and adding a clone member func

Things like "It is the programmer's responsibility to ensure that std::string_view does not outlive the pointed-to character array."

Rust's runtime

haskell vs. rust for compiler implementations

How to build a WebSocket server with Rust

strings

Rust vs. C++

baby steps in rust

Statically Sized Higher-kinded Polymorphism

Concurrency Patterns in Embedded Rust

Allow specifying dependencies for individual artifacts

Rust package with both a library and a binary?

Rust package with both a library and a binary?. path clarity (2018)

// main.rs
use hello_pack::foo;
fn main() {
    println!("Hello, world!");
    foo::weex();
}    
// lib.rs
mod lolailo;

pub mod foo {
    pub fn foo_func() -> u32 {
        return 2
    }

    pub fn weex() {
        crate::lolailo::wee();
        println!("This is a func");
    }
}    
// lib.rs alternate
mod lolailo;

pub mod foo {
    use crate::lolailo::wee; // can't be outside
    pub fn foo_func() -> u32 {
        return 2
    }

    pub fn weex() {
        wee();
        println!("This is a func");
    }
}    
// lolailo.rs
pub fn wee() {
    println!("wee!");
}    

crate level visibility for modules in Rust? (2015)

Zero To Production: a WIP book on writing a practical backend project in Rust

Enum or trait object

Why can’t I have more than one mutable reference to a value?

What are Rust's exact auto-dereferencing rules?

Why doesn't dereferencing transfer ownership?

Why do we need dereferencing? Could not every use of a reference be understood as using the underlying data

The Rust module system for Python users Clear explanation of Rust’s module system Rust module system explained.

structuring and handling errors in 2020

setting the record straight on async

microsoft Rust course

inline in Rust

a tcp proxy

Rust n Lisp

Anatomy of a Program in Memory. hn. more hn.

Awesome LD_PRELOAD

Branch Prediction - Fundamentals Every Programmer Need Not Know

Watching for software inefficiencies with Valgrind

Lecture 12 How Linux Works II : I/O, Memory Management, Booting, Loadable Kernel Modules

In Linux, network devices aren't represented as device files; network interfaces exist in their own namespace and export a different set of operations.

FOSDEM20 events Go debuggind with GDB The GDB Text User Interface Postmodern strace. Debugging apps running in Kubernetes

tcmalloc

RAM and bus timing

Firecracker paper from AWS - isolation. paper. Firecracker – Lightweight Virtualization for Serverless Computing. main page

virtualization concepts

Loading NumPy arrays from disk: mmap() vs. Zarr/HDF5

Cost of a thread in C++ under Linux

When Bloom filters don't bloom hn

Two new ways to read a file quickly

Bus errors, core dumps, and binaries on NFS (2018)

Want fast C++? Know your hardware!

cache associativity. Here's my attempt to explain: The cache stores data in cache sets, which can each hold a number of cache lines (typically 64 byte chunks). It's best to think of cache sets like buckets in a hash table

Memory efficient search trees help with cache amplification

Linux kernel teaching

Writing a memory allocator for fast serialization (2017)

Linux Kernel Development and Writing a Simple Kernel Module (2018)

Optimizing Interrupt Handling Performance for Memory Failures in Large Scale Data Centers

Compiled tips 'n tricks guide for PIC microcontrollers (2009) [pdf]

A Comparison of Software and Hardware Techniques for x86 Virtualization obsolete with newer hardware, but of historical interest

Understanding the bin, sbin, usr/bin, usr/sbin split (2010)

Why the EAX register of x86 is called like that

A “living” Linux process with no memory

Understanding CPU Microarchitecture to Increase Performance

how are uniz pipes implemented

jvm inside out

learn ePBF tracing. more on epvf. hn.

Optimising for Concurrency: Comparing the BEAM and JVM virtual machines

Hoare’s Rebuttal and Bubble Sort’s Comeback

Linux kernel map

virtualization papers

The Subtle Semantics of epoll_wait

cache-oblivious algorithms cache-line associativity

I tried cache-oblivious algorithms for some numerical code, but found them underwhelming. The cache-oblivious model does not consider the effects of prefetching and cache line associativity. Both can make a huge difference.

dynamic linking

bg

malloc geirger counter

initcalls

mmap vs system calls

How debuggers work

What's in a Linux Executable?

File Descriptor Transfer over Unix Domain Sockets

C is not a low-level language

Why mmap is faster than system calls – by Alexandra (Sasha) Fedorova

Tracking a segfault

But how, exactly, do databases use mmap?

Recreating An Old "Dirty Gamedev Trick"

what's the last problem you solved using strace?. post

A Primer on Memory Consistency and Cache Coherence, Second Edition

Dropping cache didn’t drop cache hn

Hardware memory models

How to add eBPF observability to your product

Computing Performance on the Horizon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment