STRUCT GNET_STATS_BASIC(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct gnet_stats_basic(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual β€” yes, that's the vibe, we're doing kernel structs today and honestly? iconic. ✨

This one is struct gnet_stats_basic, and it's literally just the glow-up of your throughput receipts β€” byte and packet counts, living their best life. πŸŽ€


✨ NAME ✨

struct gnet_stats_basic β€” byte/packet throughput statistics. that's it, that's the whole assignment, and it ate. πŸ’…


🌸 SYNOPSIS 🌸

lowkey the whole struct is right here, no cap:

struct gnet_stats_basic {
    __u64 bytes;
    __u32 packets;
 };

like… she's small, she's tidy, she's giving main character energy in a header file. πŸ¦‹


πŸ‘‘ Members πŸ‘‘

  • bytes β€” number of seen bytes. the __u64 one, so she can count big. 🧚
  • packets β€” number of seen packets. the __u32 one, doing her little job, we love her. πŸ’œ

πŸ”₯ SEE ALSO πŸ”₯

  • Kernel file ./include/uapi/linux/gen_stats.h β€” go read the source bestie, it's all there, iykyk πŸ“–
  • struct gnet_stats_rate_est(9)
  • struct gnet_stats_rate_est64(9)
  • struct gnet_stats_queue(9)
  • struct gnet_estimator(9)

the whole friend group fr fr, go say hi to all of them 🫢


ngl bestie, this is a straight-up data struct β€” no flags, no errors, no exit statuses, no β€œdanger will robinson” warnings hiding in here. just two numbers being gorgeous. πŸ’€

that's the page!! 🌈 mwah πŸ’‹ β€” brought to you by the fine people at ./include/uapi/linux, dated October 2026, and struct gnet_stats_basic(9) says slay and goodnight β­πŸŽ€πŸ’–

πŸ“¦ where this page comes from