prep: remove old machinectl workarounds

There are a few manual workarounds that we're placing in order
to workaround old versions of machinectl however we don't actually
leverage those and they seem to be causing a dbus restart which
causes extra problems.

This patch removes those workarounds in order to prevent restarting
dbus which causes the system to start timing out on systemd-logind.

Change-Id: I86483225754a5b1c6030ef21e2c0cdf2cd908c3b
Closes-Bug: #1807405
This commit is contained in:
Mohammed Naser 2018-12-07 10:10:31 -05:00
parent df71862a17
commit f2ac427403
3 changed files with 7 additions and 37 deletions

View File

@ -27,16 +27,6 @@
- name: Init reload
command: "initctl reload-configuration"
- name: Restart dbus
systemd:
name: "dbus"
state: "restarted"
- name: Restart machined
systemd:
name: "systemd-machined.service"
state: "restarted"
- name: Enable machines mount
systemd:
daemon_reload: yes

View File

@ -0,0 +1,7 @@
---
fixes:
- With the release of CentOS 7.6, deployments were breaking and becoming very
slow when we restart dbus in order to catch some PolicyKit changes. However,
those changes were never actaully used so they were happening for no reason.
We no longer make any modifications to the systemd-machined configuration
and/or PolicyKit to maintain upstream compatibility.

View File

@ -13,33 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# In later versions of systemd this is not needed. Referenced in
# the following ML post resolves the bug.
# * https://lists.freedesktop.org/archives/systemd-devel/2015-March/029151.html
- name: Move machined service into place
template:
src: systemd-machined.service.j2
dest: /etc/systemd/system/systemd-machined.service
register: machined_unit
notify:
- Reload systemd units
- Restart machined
# In later versions of systemd this is not needed. Referenced in
# the following commit resolves the bug.
# * https://cgit.freedesktop.org/systemd/systemd/commit/src/machine/org.freedesktop.machine1.conf?id=72c3897f77a7352618ea76b880a6764f52d6327b
- name: Move machine1 dbus config into place
copy:
src: org.freedesktop.machine1.conf
dest: /etc/dbus-1/system.d/org.freedesktop.machine1.conf
register: machine1_conf
notify:
- Reload systemd units
- Restart dbus
# Ensure lxc networks are running as they're supposed to
- meta: flush_handlers
# Because of this post and it's related bug(s) this is adding the container
# volumes the old way. The new way would simply be calling `machinectl`.
# * https://www.mail-archive.com/systemd-devel@lists.freedesktop.org/msg28255.html