Results 1 to 3 of 3

Thread: /tmp cluttered by kdesudo?

  1. #1
    Join Date
    Jan 2012

    /tmp cluttered by kdesudo?

    I've been using kdesudo a lot today, and I've noticed its cluttering /tmp quite a lot. Is kdesudo suppose to be leaving all these files behind, and would it be safe to remove them ("sudo rm /tmp/kdesudo*xauth")?

  2. #2
    Join Date
    Jul 2011
    Ubuntu 12.04 Precise Pangolin

    Re: /tmp cluttered by kdesudo?

    The /tmp folder should be cleaned automatically by the system upon a reboot. Isn't that the case on your system? Unless you are running kdesudo at the moment of removal, it should be safe to delete those files.

  3. #3
    Join Date
    Jan 2012

    Re: /tmp cluttered by kdesudo?

    It is cleaned up at reboot. I have /tmp mounted as tmpfs so even if it weren't the case it'd still clear when the power is cut. It's just that I don't often reboot because I'm running KTorrent and Folding@home 24/7. The problem is that I often use /tmp myself, either for compiling software (tmpfs allows for ridiculous fast compile times) or for doing anything that requires a lot of copying large files. It gets frustrating when so many files start accumulating.

    Would it be safe to use a startup script like this? Or maybe set up a cron job instead?
    if [ $(id -u) -ne 0 ]; then
        echo "Error, this script must be run as root."
        exit 1
    while [ $(pgrep -c kdesudo) -eq 0 ]; do
        rm /tmp/kdesudo-*-xauth
        sleep 60
    Also, just out of curiosity what is contained within these files? I found the string "MIT-MAGIC-COOKIE" in it but I have no idea what that is. The .Xauthority file also contains the line "MIT-MAGIC-COOKIE", so I'm guessing the two are somehow related.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts