1eatmydata(1) General Commands Manual eatmydata(1)
2
3
4
6 eatmydata - transparently disable fsync() and other data-to-disk syn‐
7 chronization calls
8
10 eatmydata [--] command [ command arguments ... ]
11
13 eatmydata runs a command in the environment where data-to-disk synchro‐
14 nization calls (like fsync(), fdatasync(), sync(), msync() and open()
15 O_SYNC / O_DSYNC flags) have no effect. LD_PRELOAD library libeatmydata
16 overrides respective C library calls with custom functions that don't
17 trigger synchronization but return success nevertheless.
18
19 You may use eatmydata in two ways. In normal mode, just execute eatmy‐
20 data directly and pass a command-to-be-run and its arguments via com‐
21 mand line. In order to use symlink mode, create a symlink to
22 /usr/bin/eatmydata with the filename (a.k.a basename) of another pro‐
23 gram in the PATH and execute eatmydata via that symlink. Then eatmydata
24 will find that program in the PATH and run it in the libeatmydata envi‐
25 ronment repassing all command line options.
26
28 Please note that eatmydata does not process any command line options in
29 symlink mode. All command line options will be repassed to the underly‐
30 ing executable as-is.
31
32 command
33 The command to execute. It may be either a full path or the name
34 of the command in PATH. In case command cannot be found in PATH,
35 eatmydata will fail.
36
37 command arguments
38 Arbitrary number of arguments to pass to the command being exe‐
39 cuted.
40
41 -- Optional command separator for compatibility with similar utili‐
42 ties. Ignored at the moment.
43
45 Given PATH is /usr/bin and both /usr/bin/aptitude and /usr/bin/eatmy‐
46 data are installed, the following:
47
48 $ ln -s /usr/bin/eatmydata ./aptitude
49 $ ./aptitude moo
50
51 is equivalent to:
52
53 $ eatmydata -- aptitude moo
54
55 Therefore, you may use symlink mode to automatically run specific pro‐
56 grams in the libeatmydata environment whenever you run them from PATH.
57 For example, given standard PATH settings, just do:
58
59 # ln -s /usr/bin/eatmydata /usr/local/bin/aptitude
60
61 and enjoy sync-free aptitude system-wide.
62
64 When using eatmydata with setarch (including alias such as linux32), or
65 anyway with chroots with a different architectures than the host's,
66 make sure to install the matching architecture of libeatmydata1 both in
67 the setarch environment and host's.
68
69 Trying to load libeatmydata manually (without using the wrapper script)
70 and using it through a chroot, especially if the eatmydata version dif‐
71 fer between outside and inside, is probably going to fail do the dif‐
72 ferent position of the library on the file system.
73 The safest way to manually load libeatmydata is by setting the follow‐
74 ing two environment variables (shell syntax):
75
76 LD_LIBRARY_PATH=${LD_LIBRARY_PATH:+"$LD_LIBRARY_PATH:"}/usr/lib/libeatmydata
77 LD_PRELOAD=${LD_PRELOAD:+"$LD_PRELOAD "}libeatmydata.so
78
79 These two variables accounts the case of a Debian Jessie host with a
80 Debian Wheezy chroot, where the position of the library changed.
81
82
83
84 November 2014 eatmydata(1)