Announcement

Collapse
No announcement yet.

Xsession- warning- unable to write to /tmp

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Xsession- warning- unable to write to /tmp

    I'm getting this (Title) message after entering the password on my main computer, and can go no further with it. I'm writing this on another machine.
    Yesterday I was composing an email in Thunderbird and received a message that the partly-completed message could not be saved as a Draft because /tmp could not be written to. Obviously I should have taken that as a warning and looked into it further then.
    I wanted to open a Konsole to check (and revise if necessary) the /tmp permissions but can't even manage to open it. I tried Recovery modes without success.
    What did I do, and (more importantly, though surely related) how do I get my main machine's 16.04 functioning again?
    -- Werdigo49
    Registered Linux User #291592
    Kubuntu Xenial Xerus (16.04)

    #2
    It's possible that the partition that contains /tmp is full, or somehow permissions on the /tmp directory were changed. You may need to use a live distro DVD or USB to get into the computer and examine your filesystems and make corrections.
    The next brick house on the left
    Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



    Comment


      #3
      Thanks! I tried that with a USB stick that I'd used to install 16.04, and was just starting to try it again when I saw your reply. Running Kubuntu from the stick lets me see what's there, but I can't change it, apparently. I've tried chowning /tmp to my username but am told there is no such user... I guess there isn't, on the Kubuntu running from the USB drive,

      Almost ready to do a total reinstall of 16.04, but maybe not quite yet.

      I wonder... recently I've taken to using Suspend at night, instead of my usual Shutdown. Would the latter flush /tmp while the former doesn't? I never had this problem before.
      -- Werdigo49
      Registered Linux User #291592
      Kubuntu Xenial Xerus (16.04)

      Comment


        #4
        That's possible. You may need to use chroot to effect some changes on the target system, such as adding a user to a group and similar actions. But before doing that did you use sudo to get into the /tmp directory?

        it's been a long time since I've used chroot, so you may need to check man for good instructions - or a chroot expert will wander into view!

        It's a point of pride with a lot of folks to record long up times, but an occasional reboot - not necessarily daily - does no harm.
        The next brick house on the left
        Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



        Comment


          #5
          Well, I was unable to write to, move, or copy any files on the hard disk using the 16.04 that was running from the USB stick.

          I finally threw in the towel and reinstalled the OS. I'd kept a lot of stuff in /home and preserved that, so I got back up to speed within about an hour.

          I still need to figure out what happened... so that it doesn't happen again.
          -- Werdigo49
          Registered Linux User #291592
          Kubuntu Xenial Xerus (16.04)

          Comment


            #6
            Couple of things come to mind here; this is usually a full drive/partition issue but could also be a "running a GUI program as root" issue.

            Assuming you haven't borked your system running a GUI program as root, I would have reviewed the contents of /tmp and the other folders in the partition to see what filled the drive. By reinstalling you wiped the evidence of the offending problem and may be facing it again in the future since nothing was researched.

            As far as trying your "username" from a USB stick, you correcly surmised that your user name doesn't exist on the USB live install (obviously) however, assuming you're the default user of your system your USER ID would be 1000 an it would also be that on the Live USB. The name isn't really your user id, the number is.

            Finally, if it was in fact /tmp that filled your drive (which we can't know since it's gone), you can also mount tmpfs in RAM instead of the the drive. Then any reboot or shutdown clears it's contents.

            Please Read Me

            Comment


              #7
              I think the solution lies in emptying out the /tmp file periodically. Whether you write a cron job, or reboot frrm time to time. i just checked my own /tmp file and it only contains temporary files from the last reboot. So if you'd rather not reboot, then monitor and clear it out from time to time.
              The next brick house on the left
              Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



              Comment


                #8
                Originally posted by oshunluvr View Post
                Couple of things come to mind here; this is usually a full drive/partition issue but could also be a "running a GUI program as root" issue.

                Assuming you haven't borked your system running a GUI program as root, I would have reviewed the contents of /tmp and the other folders in the partition to see what filled the drive. By reinstalling you wiped the evidence of the offending problem and may be facing it again in the future since nothing was researched.

                As far as trying your "username" from a USB stick, you correcly surmised that your user name doesn't exist on the USB live install (obviously) however, assuming you're the default user of your system your USER ID would be 1000 an it would also be that on the Live USB. The name isn't really your user id, the number is.

                Finally, if it was in fact /tmp that filled your drive (which we can't know since it's gone), you can also mount tmpfs in RAM instead of the the drive. Then any reboot or shutdown clears it's contents.
                Thanks. In retrospect this issue may have arisen from a power jolt during a thunderstorm. The electricity went off briefly, and when it came back on my system was frozen; all I could do was turn the main power switch off. When I turned it back on and booted up, a partition on a secondary hard disk ("One_Data"), normally containing about a dozen folders, had only one, which I'd never seen before: "One_Data1". Opening it, there were the dozen! (My photographs and music are on this disk, so I had to reconfigure Digikam and Amarok to look at "One_Data/One_Data1." With the fresh reinstall, I was delighted to find that mystery folder gone and my ~dozen back in One_Data where they belong.

                Well, this is going on and on, sorry! I did look at the /tmp directories (there were two of them) but their files' sizes were shown as either zero or "unknown." I never knowingly ran GUIs as root. I'm considering this problem as probably arising from electrical issues in the thunderstorm, and (with the reinstall) whether or not it's really "solved" (and should be retitled as such), it's good enough for me.

                Thanks again for the kind attention and help!
                -- Werdigo49
                Registered Linux User #291592
                Kubuntu Xenial Xerus (16.04)

                Comment

                Working...
                X