f3af6ba pid1: propagate the original command line when reexecuting

Authored and Committed by zbyszek 2 years ago
    pid1: propagate the original command line when reexecuting
    
    When we reexec the manager in a container, we lose configuration settings on
    the kernel command line:
    
      $ systemd-nspawn -M rawhide -b systemd.status-unit-format=name systemd.show-status=yes
      ...
      # tr '\0' ' ' 
      /usr/lib/systemd/systemd systemd.status_unit_format=combined systemd.show-status=yes
      # sudo systemctl daemon-reexec
      # tr '\0' ' ' 
      /usr/lib/systemd/systemd --system --deserialize 20
    
      This means that after daemon-reexec, the settings that we gain from the
      commandline are reset to defaults.
    
    So let's reeexecute with the original arguments copied over, modulo some
    filtering.
    
    (cherry picked from commit 846f1da465beda990c1c01346311393f485df467)
    
        
file modified
+53 -10