Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 10-11-2014, 02:32 AM   #1
Registered: Oct 2005
Location: Germany
Distribution: Ubuntu
Posts: 58

Rep: Reputation: 24
error using O_DIRECT starting with kernel 3.16.0 (?)

I have a program that uses the following open() flags:
read() calls work OK until EOF is reached and then an EINVAL error is returned.

The buffer is aligned with the following call:
posix_memalign((void**) &vbuff,512,BIOCC);
The program runs OK if O_DIRECT is removed.
The program has been running for years on earlier kernel versions.

Is this a bug or an API change? Need guidance.

O_DIRECT is used because the file is being read to verify integrity shortly after it was written, so reading from the cache is not wanted.
This is part of a backup utility.


error, file, read

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Kernel error - Error in starting splunk forwarder in linux machine sumanth89 Linux - Newbie 1 03-19-2013 10:49 AM
Writing files using O_DIRECT in C anchit87 Programming 1 02-28-2010 09:51 PM
how to use O_DIRECT ? Stephan_Craft Linux - Server 1 10-05-2009 06:16 AM
Error in starting XServer in kernel thandermax Linux - Software 1 06-27-2005 12:59 PM
Error in starting XServer in kernel thandermax Linux - Newbie 1 06-27-2005 07:39 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:01 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration