<story><title>I wish systemd logged information about the source of “transactions”</title><url>https://utcc.utoronto.ca/~cks/space/blog/linux/SystemdTransactionSourceWish</url></story><parent_chain><item><author>TimWolla</author><text>A peer of mine was exiting their SSH sessions with &amp;#x27;exit&amp;#x27;. One time apparently they already typed &amp;#x27;systemctl&amp;#x27;, probably in an attempt to check the status of a service, changed their mind and then later wanted to close the session using &amp;#x27;exit&amp;#x27;, actually executing &amp;#x27;systemctl exit&amp;#x27;. This translated into a shutdown of the machine in question.&lt;p&gt;After being able to piece together what happened with the machine&amp;#x27;s logs and the bash history I recommended to simply exit all programs&amp;#x2F;sessions with Ctrl+D. It works almost everywhere and would have prevented this exact issue.</text></item></parent_chain><comment><author>lathiat</author><text>I can do one better for exit. The Solaris kernel debugger KDB can be used at runtime for inspecting some stats and also to change some global configurable variables.&lt;p&gt;For whatever reason if you type a variable&amp;#x2F;symbol it assigns it the value 0. If you type exit nothing happens immediately but as soon as the next process exits usually a few seconds to 10s of seconds later the entire system kernel panics on a null pointer de-reference.&lt;p&gt;Kernel paniced our production ZFS filer twice before I cottoned on. Newer releases special cased “exit” not to do that.</text></comment>
<story><title>I wish systemd logged information about the source of “transactions”</title><url>https://utcc.utoronto.ca/~cks/space/blog/linux/SystemdTransactionSourceWish</url></story><parent_chain><item><author>TimWolla</author><text>A peer of mine was exiting their SSH sessions with &amp;#x27;exit&amp;#x27;. One time apparently they already typed &amp;#x27;systemctl&amp;#x27;, probably in an attempt to check the status of a service, changed their mind and then later wanted to close the session using &amp;#x27;exit&amp;#x27;, actually executing &amp;#x27;systemctl exit&amp;#x27;. This translated into a shutdown of the machine in question.&lt;p&gt;After being able to piece together what happened with the machine&amp;#x27;s logs and the bash history I recommended to simply exit all programs&amp;#x2F;sessions with Ctrl+D. It works almost everywhere and would have prevented this exact issue.</text></item></parent_chain><comment><author>iforgotpassword</author><text>Almost entirely unrelated, but lately I worked with old photos that had missing, incomplete or wrong exif data. While trying to assess and automate fixing the collection via scripts, I used the command line utility &amp;quot;exif&amp;quot; a lot. You can&amp;#x27;t imagine how many times I typed &amp;quot;exit somefile.jpg&amp;quot; and flinched when the terminal window just closed. Guess I should just have created an alias but that&amp;#x27;s like resigning to your own stupidity. ;-)</text></comment>