read() and write() with 2GB buffers are truncated on RHEL
Issue
- The implementation of write() and read() in the Linux kernel prevents one from writing/reading >2GB at a time.
- read()/write() system calls limit buffers to (2^31 - pagesize) (2147479552 bytes on x86).
Environment
- Red Hat Enterprise Linux 5, 6
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
