How to access Ubuntu without the administrator password

Access Ubuntu without password

I personally don't remember the time when I used a computer without a login password. Today we store all kinds of personal information on our computers and mobile devices, so it is a good idea to protect this information with a password that no one but us knows. But what if we forgot this password? Well, this can be a problem, unless you carry out the steps that we detail below and that you can find conducting an internet search.

In Unix-based operating systems we need a password to perform almost any task. This is a positive thing, since, in theory, almost no file has execution permission, but it must be recognized that sometimes it can be a nuisance to put both the password or, as far as this goes post, we have to memorize the administrator password if we do not want to have any problems. But if we have forgotten it, Not everything is lost; we can restore it.

How to reset admin password in Ubuntu

The steps to follow are very easy. I don't see what could go wrong and, besides, not being able to access our computer is the worst thing that could happen to us. If you are in that situation, you just have to:

  1. We restart the computer.
  2. When entering GRUB, we press the «e» key (edit).
  3. We go to the kernel line and enter the command rw init = / bin / bash behind the line, which will be as in the following image:

Command to be able to reset Ubuntu password

  1. After entering the above command, we press Enter.
  2. Now we press the «b» key (boot = start).
  3. The next time we start, we will be able to enter the computer without a password, so now we will have to create another one. Once started and entered the system, we open a terminal and write the command passwd Username, where we will have to replace "Username" with our username (mine is usually Pablinux).
  4. We press Enter.
  5. We introduce the new password.
  6. And finally, we restart the computer.

I hope you never find yourself in a situation where this information is useful to you, but if that is the case, at least you will be able to access your computer.


Leave a Comment

Your email address will not be published. Required fields are marked with *

*

*

  1. Responsible for the data: Miguel Ángel Gatón
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.

  1.   Freddy Agustin Carrasco Hernandez said

    How unsafe!

  2.   Miguel Angel Santamaría Rogado said

    If I remember correctly, it was also possible to change the password from recovery mode: https://wiki.ubuntu.com/RecoveryMode

    Greetings.

  3.   David villegas said

    I consider that an Ubuntu BUG

  4.   tony said

    Damn it was something very simple ... What insecurity

  5.   supersx said

    Today, the security of an OS is determined above all by the difficulty of hacking it without physical access.
    To apply this tutorial, you need physical access to the computer. And regardless of the OS, someone who knows a little computer science and has physical access will be able to remove the data you have with ease (who has not used a liveCD to recover data from a broken computer?)
    The only way to have a secure system against physical access is to encrypt the hard drive.
    And if it is encrypted, this tutorial is useless, since you cannot reset the disk encryption password.

    So, although it seems insecure, it has little practical impact.

    1.    Victor Flores said

      The one from supersx is the only sane comment I read in this post

  6.   Ruben said

    Does this method also allow updates to download? I am a neophyte on these issues. Thanks.

  7.   Marina said

    Hi, my computer has Ubuntu Mate and I can't access GRUB (I pressed ESC, SHIFT, F2 at startup and nothing) I can't access my computer because I haven't used it for a long time and I can't remember the password. Could you help me? Thanks

  8.   rudy said

    How is the kernel line going? I can't change anything