summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* selinux: make use of cleanup gcc magicLennart Poettering2014-10-23
|
* TODOTom Gundersen2014-10-23
|
* man: pam_systemd: some typos fixed, some info addedDaniel Mack2014-10-23
| | | | Just some minor nits that I stumbled over when reading the man page.
* unit: adjust for the possibility of set_move() failingMichal Schmidt2014-10-23
|
* hashmap: allow hashmap_move() to failMichal Schmidt2014-10-23
| | | | | | It cannot fail in the current hashmap implementation, but it may fail in alternative implementations (unless a sufficiently large reservation has been placed beforehand).
* unit: place reservations before merging other's dependenciesMichal Schmidt2014-10-23
| | | | | | | | With the hashmap implementation that uses chaining the reservations merely ensure that the merging won't result in long bucket chains. With a future alternative implementation it will additionally reserve memory to make sure the merging won't fail.
* install, cgtop: adjust hashmap_move_one() callers for -ENOMEM possibilityMichal Schmidt2014-10-23
| | | | | | | | | | | | That hashmap_move_one() currently cannot fail with -ENOMEM is an implementation detail, which is not possible to guarantee in general. Hashmap implementations based on anything else than chaining of individual entries may have to allocate. hashmap_move_one will not fail with -ENOMEM if a proper reservation has been made beforehand. Use reservations in install.c. In cgtop.c simply propagate the error instead of asserting.
* test: add test for hashmap_reserve()Michal Schmidt2014-10-23
|
* hashmap: introduce hashmap_reserve()Michal Schmidt2014-10-23
| | | | | | | | | | | | | | | With the current hashmap implementation that uses chaining, placing a reservation can serve two purposes: - To optimize putting of entries if the number of entries to put is known. The reservation allocates buckets, so later resizing can be avoided. - To avoid having very long bucket chains after using hashmap_move(_one). In an alternative hashmap implementation it will serve an additional purpose: - To guarantee a subsequent hashmap_move(_one) will not fail with -ENOMEM (this never happens in the current implementation).
* hashmap: return more information from resize_buckets()Michal Schmidt2014-10-23
| | | | | Return 0 if no resize was needed, 1 if successfully resized and negative on error.
* shared: split mempool implementation from hashmapsMichal Schmidt2014-10-23
|
* resolve: make DnsScope::conflict_queue an OrderedHashmapMichal Schmidt2014-10-23
| | | | | on_conflict_dispatch() uses hashmap_steal_first() and then does something non-trivial with it. It may care about the order.
* sd-bus: make sd_bus::reply_callbacks a OrderedHashmapMichal Schmidt2014-10-23
| | | | | The way process_closing() picks the first entry from reply_callbacks and works with it makes it likely that it cares about the order.
* journal: make sd_journal::files a OrderedHashmapMichal Schmidt2014-10-23
| | | | | Anything that uses hashmap_next() almost certainly cares about the order and needs to be an OrderedHashmap.
* journal: make Server::user_journals an OrderedHashmapMichal Schmidt2014-10-23
| | | | | Order matters here. It replaces oldest entries first when USER_JOURNALS_MAX is reached.
* journal: make JournalFile::chain_cache an OrderedHashmapMichal Schmidt2014-10-23
| | | | | | | The order of entries may matter here. Oldest entries are evicted first when the cache is full. (Though I don't see anything to rejuvenate entries on cache hits.)
* install: make InstallContext::{will_install,have_installed} OrderedHashmapsMichal Schmidt2014-10-23
| | | | It appears order may matter here. Use OrderedHashmaps to be safe.
* hashmap: drop assert(h) from hashmap_next()Michal Schmidt2014-10-23
| | | | It's handled just fine by returning NULL.
* hashmap: hashmap_move_one() should return -ENOENT when 'other' is NULLMichal Schmidt2014-10-23
| | | | | | -ENOENT is the same return value as if 'other' were an allocated hashmap that does not contain the key. A NULL hashmap is a possible way of expressing a hashmap that contains no key.
* test: add and improve hashmap testsMichal Schmidt2014-10-23
| | | | | | | | | | | | | | | | Test more corner cases and error states in several tests. Add new tests for: hashmap_move hashmap_remove hashmap_remove2 hashmap_remove_value hashmap_remove_and_replace hashmap_get2 hashmap_first In test_hashmap_many additionally test with an intentionally bad hash function.
* test: generate tests for OrderedHashmap from Hashmap testsMichal Schmidt2014-10-23
| | | | | | | | | test-hashmap-ordered.c is generated from test-hashmap-plain.c simply by substituting "ordered_hashmap" for "hashmap" etc. In the cases where tests rely on the order of entries, a distinction between plain and ordered hashmaps is made using the ORDERED macro, which is defined only for test-hashmap-ordered.c.
* hashmap: add OrderedHashmap as a distinct typeMichal Schmidt2014-10-23
| | | | | | | | | | Few Hashmaps/Sets need to remember the insertion order. Most don't care about the order when iterating. It would be possible to use more compact hashmap storage in the latter cases. Add OrderedHashmap as a distinct type from Hashmap, with functions prefixed with "ordered_". For now, the functions are nothing more than inline wrappers for plain Hashmap functions.
* mac: also rename use_{smack,selinux,apparmor}() calls so that they share the ↵Lennart Poettering2014-10-23
| | | | new mac_{smack,selinux,apparmor}_xyz() convention
* mac: rename apis with mac_{selinux/smack}_ prefixWaLyong Cho2014-10-23
|
* label: rearrange mandatory access control(MAC) apisWaLyong Cho2014-10-23
| | | | move label apis to selinux-util.ch or smack-util.ch appropriately.
* man: add example how to generate certificates with opensslZbigniew Jędrzejewski-Szmek2014-10-23
|
* journal-upload: return proper exit codeZbigniew Jędrzejewski-Szmek2014-10-23
| | | | | Even when termninated normally, systemd-journal-upload would return something positive which would be interpreted as failure.
* shared/log: add log_trace as compile-time optional debuggingZbigniew Jędrzejewski-Szmek2014-10-23
| | | | | | | | | Repetetive messages can be annoying when running with SYSTEMD_LOG_LEVEL=debug, but they are sometimes very useful when debugging problems. Add log_trace which is like log_debug but becomes a noop unless LOG_TRACE is defined during compilation. This makes it easy to enable very verbose logging for a subset of programs when compiling from source.
* journal-upload: fix --trust=all optionZbigniew Jędrzejewski-Szmek2014-10-23
|
* journal-upload: avoid calling printf with maximum precisionZbigniew Jędrzejewski-Szmek2014-10-23
| | | | | | Precision of INT_MAX does not work as I expected it to. https://bugzilla.redhat.com/show_bug.cgi?id=1154334
* journal-upload: verify state file can be saved before uploadingZbigniew Jędrzejewski-Szmek2014-10-23
| | | | | Do our best verify that we can actually write the state file before upload commences to avoid duplicate messages on the server.
* socket-util: use IP address when hostname is not foundZbigniew Jędrzejewski-Szmek2014-10-23
| | | | | socknameinfo_pretty() would fail for addresses without reverse DNS, but we do not want that to happen.
* journal-remote: add --split-mode to helpZbigniew Jędrzejewski-Szmek2014-10-23
|
* journal-remote: better error message on failureZbigniew Jędrzejewski-Szmek2014-10-23
| | | | Return a proper code instead of simply NULL for failure.
* journal-upload: do not require port to be setZbigniew Jędrzejewski-Szmek2014-10-23
|
* systemd-upload: print paths in help()Zbigniew Jędrzejewski-Szmek2014-10-23
|
* journal-remote: give names to event sourcesZbigniew Jędrzejewski-Szmek2014-10-23
| | | | This possibility was recently added, and it makes debugging much nicer.
* journal-upload: fix socket activationZbigniew Jędrzejewski-Szmek2014-10-23
|
* sd-daemon,man: ignore missing $WATCHDOG_PIDZbigniew Jędrzejewski-Szmek2014-10-23
| | | | | | | | | | | | | | | | Systemd 209 started setting $WATCHDOG_PID, and sd-daemon watch was modified to check for this variable. This means that sd_watchdog_enabled() stopped working with previous versions of systemd. But sd-event is a public library and API and we must keep it working even when a program compiled with a newer version of the libary is used on a system running an older version of the manager. getenv() and unsetenv() are fairly expensive calls, so optimize sd_watchdog_enabled() by not calling them when unnecessary. man: centralize the description of $WATCHDOG_PID and $WATCHDOG_USEC in the sd_watchdog_enabled manpage. It is better not to repeat the same stuff in two places.
* man: make udev.event-timeout more visibleZbigniew Jędrzejewski-Szmek2014-10-23
| | | | Evidently some people had trouble finding it in the documentation.
* units: run firstboot before sysusers, so that firstboot can initialize the ↵Lennart Poettering2014-10-23
| | | | root password
* update TODOLennart Poettering2014-10-23
|
* update TODOLennart Poettering2014-10-23
|
* journalctl: add new --flush command and make use of it in ↵Lennart Poettering2014-10-23
| | | | | | | | | | systemd-journal-flush.service This new command will ask the journal daemon to flush all log data stored in /run to /var, and wait for it to complete. This is useful, so that in case of Storage=persistent we can order systemd-tmpfiles-setup afterwards, to ensure any possibly newly created directory in /var/log gets proper access mode and owners.
* cryptsetup: fix an OOM checkLennart Poettering2014-10-23
|
* machine: validate machine names using machine_name_is_valid() instead of ↵Lennart Poettering2014-10-22
| | | | | | | string_is_safe() After all, we know have this as generic validator, so let's be correct and use it wherver applicable.
* sd-bus: fix transition left-overs in sd_bus_get_owner_creds()Daniel Mack2014-10-22
| | | | | sd_bus_get_owner_creds() was only halfly ported over to _cleanup_bus_creds_unref_.
* journal: do server_vacuum for sigusr1WaLyong Cho2014-10-22
| | | | | | | | | runtime journal is migrated to system journal when only "/run/systemd/journal/flushed" exist. It's ok but according to this the system journal directory size(max use) can be over the config. If journal is not rotated during some time the journal directory can be remained as over the config(or default) size. To avoid, do server_vacuum just after the system journal migration from runtime.
* firstboot: don't prohibit re-generating the machine id on the current root fsLennart Poettering2014-10-22
| | | | | | | | If it really is missing it should be safe to create it. Also see: http://lists.freedesktop.org/archives/systemd-devel/2014-August/022726.html
* update TODOLennart Poettering2014-10-22
|