Commit Graph

31 Commits

Author SHA1 Message Date
Lennart Poettering d7228cb852 readahead: properly detect btrfs on SSD 2012-11-22 01:51:06 +01:00
Michal Schmidt c4b996bd87 readahead: fix fd validity check
https://bugzilla.redhat.com/show_bug.cgi?id=868603
2012-10-22 22:08:06 +02:00
Lennart Poettering a8b10efaec readahead: use 20K instead of 16K as temporary request nr bump 2012-09-13 00:10:35 +02:00
Lennart Poettering a8348796c0 missing: define name_to_handle_at on our own if it is missing 2012-09-04 15:30:24 -07:00
Lennart Poettering 268ba0ef60 readahead: a bit of reformatting 2012-09-03 18:59:05 -07:00
Lukas Nykryn 403a56bf81 readahead-analyze: don't call fclose on null 2012-08-23 13:53:30 +02:00
Lennart Poettering 64825d3c58 fix a couple of issues found with llvm-analyze 2012-08-08 23:54:21 +02:00
Shawn Landden 0d0f0c50d3 log.h: new log_oom() -> int -ENOMEM, use it
also a number of minor fixups and bug fixes: spelling, oom errors
that didn't print errors, not properly forwarding error codes,
few more consistency issues, et cetera
2012-07-26 11:48:26 +02:00
Shawn Landden 669241a076 use "Out of memory." consistantly (or with "\n")
glibc/glib both use "out of memory" consistantly so maybe we should
consider that instead of this.

Eliminates one string out of a number of binaries. Also fixes extra newline
in udev/scsi_id
2012-07-25 11:23:57 +02:00
Shawn Landden c2f1db8f83 use #pragma once instead of foo*foo #define guards
#pragma once has been "un-deprecated" in gcc since 3.3, and is widely supported
in other compilers.

I've been using and maintaining (rebasing) this patch for a while now, as
it annoyed me to see #ifndef fooblahfoo, etc all over the place,
almost arrogant about the annoyance of having to define all these names to
perform a commen but neccicary functionality, when a completely superior
alternative exists.

I havn't sent it till now, cause its kindof a style change, and it is bad
voodoo to mess with style that has been established by more established
editors. So feel free to lambast me as a crazy bafoon.

v2 - preserve externally used headers
2012-07-19 12:30:59 +02:00
Lennart Poettering 047e111bdd readahead: fix calculation of percentage 2012-07-03 21:22:08 +02:00
Lennart Poettering 8b38f3cc3e journal: fix sd_journal_stream_fd() 2012-06-22 00:19:13 +02:00
Lennart Poettering 3b0810c53c readahead: minor code style fixes 2012-06-22 00:09:23 +02:00
Lennart Poettering ebfb7506fe readahead: make sure to close pack file before exiting, to be valgrind clean 2012-06-22 00:03:25 +02:00
Lennart Poettering 97fa0e708f readahead: use log_error() for logging errors 2012-06-21 23:58:31 +02:00
Lennart Poettering a0bbec1ab0 readahead: make use of util.h's page_size() call 2012-06-21 23:56:03 +02:00
Lennart Poettering 87ce22cc0d readahead: merge three binaries into one
since the binaries share much of the same code and we better load only
one binary instead of two from disk at early boot let's merge the three
readahead binaries into one. This also allows us to drop a lot of
duplicated code.
2012-06-21 23:53:20 +02:00
Auke Kok cae544bcdb readahead: Add tool to analyze the contents of the pack file. v3.
This patch adds code to compile 'systemd-readahead-analyze' and install
it into $bindir.

Use this program to parse the contents of the readahead pack file, or
an arbitrary pack file and display which files are listed in it, and
how much of the files are requested to be readahead.

This code is not new - it's partially taken from sreadahead (formerly
maintained by Arjan van der Ven and me, and was originally written
by me), and adapted with the right bits to parse the systemd
readahead pack files, which are slightly different in format.

v2 adds a common READAHEAD_PACK_FILE_VERSION used in all the code
to provide a quick way to assure all these programs are always
synchronized. v3 fixes the integer math.
2012-06-05 22:45:37 +02:00
Lennart Poettering 08231e5142 readahead: avoid running of readahead services if readahead is already done 2012-05-23 03:51:25 +02:00
Lennart Poettering e905f48fdc readahead: avoid activating the journal by accident, log directly to kmsg 2012-05-23 03:50:53 +02:00
Lennart Poettering 189455ab08 readahead: store inode numbers in pack file
If the inode nr for each file is available in the pack file we can
easily detect replaced files (like they result from package upgrades)
which we can then skip to readahead.
2012-05-04 00:34:12 +02:00
Lennart Poettering 4019a16d5b units: use OOMScoreAdjust= in the unit files to set OOM score adjust 2012-05-04 00:15:21 +02:00
Lennart Poettering 6de338a2d9 readhead: temporarily lower the kernel's read_ahead_kb setting while collecting
While collecting readahead data we want to know exactly what userspace
accesses unblurred by the kernel's read_ahead_kb. Hence lower this
during collection, and raise it afterwards.

This is mostly based on ideas and code by Auke Kok.
2012-05-04 00:13:20 +02:00
Lennart Poettering 3b2d5b02ae readahead: rather than checking for virtualization in the C code, use ConditionVirtualization= in the unit 2012-04-24 13:14:40 +02:00
Lennart Poettering 5430f7f2bc relicense to LGPLv2.1 (with exceptions)
We finally got the OK from all contributors with non-trivial commits to
relicense systemd from GPL2+ to LGPL2.1+.

Some udev bits continue to be GPL2+ for now, but we are looking into
relicensing them too, to allow free copy/paste of all code within
systemd.

The bits that used to be MIT continue to be MIT.

The big benefit of the relicensing is that closed source code may now
link against libsystemd-login.so and friends.
2012-04-12 00:24:39 +02:00
Lennart Poettering 05aa9edde0 readahead: don't monopolize IO when replaying 2012-01-21 02:51:13 +01:00
Lennart Poettering 4cfa2c999d core: switch all log targets to go directly to the journal, instead via syslog 2012-01-12 05:09:06 +01:00
Lennart Poettering 2f9dec073b build-sys: add stub makefiles to subdirs 2012-01-05 16:29:21 +01:00
Lennart Poettering 81527be142 build-sys: move public header files into a dir of their own 2012-01-05 16:01:58 +01:00
Lennart Poettering 4f3656e1ce readahead: bring export definition of sd-readahead in line with sd-daemon 2012-01-03 21:08:57 +01:00
Lennart Poettering e5e83e8362 build-sys: make readahead and vconsole optional 2011-12-31 19:45:41 +01:00