GNU bug report logs - #15578
Parameter -d or --direct to open files with flag O_DIRECT?

Previous Next

Package: coreutils;

Reported by: Kyle Sallee <kyle.sallee <at> gmail.com>

Date: Wed, 9 Oct 2013 23:21:01 UTC

Severity: normal

Tags: notabug

Done: Eric Blake <eblake <at> redhat.com>

Bug is archived. No further changes may be made.

Full log


Message #15 received at 15578-done <at> debbugs.gnu.org (full text, mbox):

From: Eric Blake <eblake <at> redhat.com>
To: Kyle Sallee <kyle.sallee <at> gmail.com>
Cc: 15578-done <at> debbugs.gnu.org
Subject: Re: bug#15578: Parameter -d or --direct to open files with flag
 O_DIRECT?
Date: Wed, 09 Oct 2013 21:11:48 -0600
[Message part 1 (text/plain, inline)]
tag 15578 notabug
thanks

On 10/09/2013 05:18 PM, Kyle Sallee wrote:
> Please consider the attached gzipped patch file.

Thanks for the patch.

Unless the patch is huger than 100k, it's best to post it inline rather
than forcing readers to go through extra hoops to unpack it.

> It provides additional parameters for cat.
> The additional parameter allows cat to open files and read content
> without storing the content in the kernel's block cache.

However, adding an option to 'cat' is probably not the best option.  We
already have 'dd' that can request O_DIRECT on operating systems where
that is defined, so you are probably better off converting your scripts
to use dd than to try and retrofit cat and wait for the patches to
percolate into your distro.  Look for 'dd iflag=direct'.

I'm closing this bug as we probably aren't going to change cat, but do
feel free to add additional comments on this thread as appropriate.  Who
knows - maybe it's worth reopening and repurposing this bug report into
a documentation patch.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

[signature.asc (application/pgp-signature, attachment)]

This bug report was last modified 11 years and 220 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.