- - -

UPDATE [AM 17 Sept. 2025]: Issue has been solved!

(I might at some point post the entire process with screenshots and stuff… But anyway,)

In short;

After @Auth suggested to just copy the contents of the inaccessible user’s homedir to a new user, I logged in with tempuser and fast recalled that said homedir was similarly inaccessible as such, as I had selected the option to encrypt home directory during installation, and thus the files within were to other users unreachable without first decrypting them.

I followed @just_another_person’s [advice/instructions] until they stopped replying, then managed to successfully mount the home directory after running through the other steps of the guide they referenced ([see:34365607/19080549,34365607/19187230]). I then realised that maybe I could just reverse all the steps I had taken since the user was last accessible, ([see:34365607/19187230]) and regain full access to the user, so I formulated a list of commands to reverse the steps, ([see:34365607/19233599]) checked for flaws, couldn’t really find any, and just tried running the commands.

Anyway, it worked, and I can now log in to the user again and access all the files!

Much thanks to everyone who commented, and thanks again to @Auth, @just_another_person, @Wolf_Munroe, @Fizz and again (again) to @just_another_person for continuing to reply for so long!

- - -


Hi fediverse,

I’m hoping someone can give me some advice on an issue that means I can’t access the main user account on my Linux Mint (Cinnamon) operating system.

Context:

I’m using a dual boot setup of windows and mint on my laptop. I use mint (or used to, when I could access my user) for pretty much anything that doesn’t require things* only my windows instance has. (*things such as support for video games that support windows but not linux, for example)

When creating my main user account, I made a mistake in the username. It was irritating enough for me to want to change it, and as doing so seemed like it should have been fine, I settled upon three guides and ended up (mostly?) just following this one:

https://www.linuxuprising.com/2019/04/how-to-change-username-on-ubuntu-debian.html

I cant remember all of what happened anymore, but I have the following screenshots, along with the stuff I do remember.

(note: red blocks represent the new username, blue blocks represent the old username)

At the used-by-process error, I first tried following the guide precisely, then hoped that “PID” was Process ID, and that the guide expected me to put the ID that usermod stated after “PID”, and tried doing that.

Idk if that fvcked something up…

Then I guess I fixed that somehow, idk if I did so by restarting and logging in only as tempuser, or if I had already done that and fixed it some other way.

Anyway I meant to run each line of the command separately to avoid stuff going wrong, but accidentally did both at once. I hoped it’d be fine anyway.

Then stuff happened I guess.

Anyway,

I cant remember much more but I know that I tried to log back in as my main user account and I found out that:

  1. The username had been successfully changed.
  2. I could not log into my main user account.

Inputting the correct username and password was successful, and acted like it was logging me in as usual. Then after the usual black screen, it just throws me back to the login window.

This still happens.

I ran some web searches, followed some advice. All that I could find of relevance was mostly just people saying to check how much disk space you have left - and to not keep timeshift snapshots on the same drive as your OS.

(this is one such post, which I’m pretty sure is the only one I found that I definitely recognise from the previous searching: https://www.reddit.com/r/linuxmint/comments/15revgg/cant_stay_logged_in_keeps_going_back_to_login/)

I did ctrl-alt-f1 and ran df -h, and deleted most of the timeshift snapshots I had (I think I had maybe 6 and deleted 4 or 5).

Here’s the output of df -h that I think is from after I deleted the timeshifts:

Idk what to do, hope someone can advise.

(TL;DR: tried to change username on mint, now whenever I try to log in to the user it throws me back to the login window after the usual black screen. Hope this suffices for a summary…)


[(Edit [AM 06 Sept. 2025]: fixed typos, phrasing…)]

[(Edit [AM 17 Sept. 2025]: UPDATE [SOLVED])]

    • DuckyLoco404@lemmy.worldOP
      link
      fedilink
      arrow-up
      0
      ·
      4 months ago

      I tried logging in with tempuser and remembered that I have no idea how to access the files on my main user. In the file manager the home folder for said user isn’t accessible, and I assume that’s because I set it to be encrypted when setting it up. Thus I can’t access the files to copy them over to a new user or anything. Also, I assume I wouldn’t be able to rename the homedir as such, and don’t know where to start checking or changing user settings and permissions and such.

      • just_another_person@lemmy.world
        link
        fedilink
        arrow-up
        2
        arrow-down
        1
        ·
        4 months ago

        Do it like this:

        1. Create new user
        2. sudo chown -R newusersnamehere /home/olduserhomedir

        Then you’ll have access to all the old files while logged in as your newly created user.

        • DuckyLoco404@lemmy.worldOP
          link
          fedilink
          arrow-up
          1
          ·
          4 months ago

          (while logged in to tempuser) I created a new user, and ran the command. Then I logged out of tempuser and into the new user, and checked the home folder to see if i could access anything. Only the following seems to have changed in reaction to the command; while logged in to the new user, the folder for the old user’s /home doesn’t have a grey square icon with a white “X” anymore, and I can access said folder without inputting a password. The stuff inside the folder remains the same, except now when I try to open the “Access-Your-Private-Data.desktop” file, nothing at all happens, whereas before it would return an access-denied-type error message.

          I think I remembered putting in a password to get said error message before, so I added a password to the new user just in case that helped, then tried opening the file again, but it didn’t change anything.

          (Also, weirdly the password for this new user was required to be a minimum of 8 characters long, whereas the old user’s password was required to be six, and the one for tempuser is only four characters. Which is an odd inconsistency)

          I also tried accessing tempuser’s /home, and that worked, letting me access it via password. I was able to access all of tempuser’s files, instead of there just being “Access-Your-Private-Data.desktop” and “README.text”. I assume this means that only the original user’s home folder is encrypted.

          • just_another_person@lemmy.world
            link
            fedilink
            arrow-up
            2
            arrow-down
            1
            ·
            4 months ago

            This is some weird Cinnamon desktop BS, and I don’t have all your aettings, so I’m flying blind on that.

            Forget the desktop then if you’re not sure what you’re doing. Create. A new directory under the new users homedir: mkdir ~/oldhome-backup

            Then as whichever user has sudo access run: mv /home/whateveroldusersdir /home/newusersdir/oldhome-backup

            • DuckyLoco404@lemmy.worldOP
              link
              fedilink
              arrow-up
              0
              arrow-down
              1
              ·
              4 months ago

              I uh… I kind of would have assumed that this was what it’d do, but

              Yeah its just moved it all as it was to the new directory.

              What do I do now?

              (the magenta blocks represent the new username btw)

              • just_another_person@lemmy.world
                link
                fedilink
                arrow-up
                1
                arrow-down
                1
                ·
                4 months ago

                Now you CHANGE THE OWNERSHIP of that folder as a showered you before:

                sudo chown -R magenta user ./oldhome-backup

                Then run this just in case you messed up something with file permissions on that directory previously while running whatever commands:

                sudo chmod -R +r ./oldhome-backup

                Confirm after running that command that the ownership of the files has changed to the new user. If they haven’t, then you something else going on.