Xilinx-CNS / solarcapture

SolarCapture network packet capture suite
Other
13 stars 8 forks source link

fallocate fails beyond 4GiB #3

Closed rgarner-vivcourt closed 5 months ago

rgarner-vivcourt commented 6 months ago

Cast ALLOC_STRIDE to uint64_t before aligning. Without this cast, extending the output file wraps after the first 4GiB. The result of the ALIGN_FWD is treated as a 32-bit unsigned, and so the second argument to fallocate_fn is negative.

rgarner-vivcourt commented 5 months ago

Tested on RHEL 9.2, various machines, with SFC X2541 cards in 4x10/25 mode. Running in production since 1 Feb 24, capturing ~2.5T/day on 2 interfaces.