Can't log in because I forgot my user name
Clash Royale CLAN TAG#URR8PPP
up vote
16
down vote
favorite
My friend had put Linux Mint 17.3 Cinnamon 64 bit on my computer. Well, I forgot the user name, so I did a search on the Net for "forgot username linux" and came here.
I got the suggestion to hit 'e' at the 1st item in GRUB which I did. The next part of the suggestion said to look for a line that started with KERNAL. Now here is where it gets interesting. I didn't find a line with KERNAL in it. However, I did find a line that started with LINUX.
The full unedited line reads:
linux /vmlinuz-3.19.0-32-generic root=UUID=0c031f3a-81ae-4c33-06cc--c82a855736d1 ro quiet splash $vt_handoff
The suggestion then said to look and edit splash quiet
to single
. Now if you notice above it says quiet splash
instead of splash quiet
. So I figured I would edit the quiet splash
to single
.
Now it's asking for a root password. Can anyone help? I suppose I'll need a Live CD.
users password system-recovery
add a comment |Â
up vote
16
down vote
favorite
My friend had put Linux Mint 17.3 Cinnamon 64 bit on my computer. Well, I forgot the user name, so I did a search on the Net for "forgot username linux" and came here.
I got the suggestion to hit 'e' at the 1st item in GRUB which I did. The next part of the suggestion said to look for a line that started with KERNAL. Now here is where it gets interesting. I didn't find a line with KERNAL in it. However, I did find a line that started with LINUX.
The full unedited line reads:
linux /vmlinuz-3.19.0-32-generic root=UUID=0c031f3a-81ae-4c33-06cc--c82a855736d1 ro quiet splash $vt_handoff
The suggestion then said to look and edit splash quiet
to single
. Now if you notice above it says quiet splash
instead of splash quiet
. So I figured I would edit the quiet splash
to single
.
Now it's asking for a root password. Can anyone help? I suppose I'll need a Live CD.
users password system-recovery
30
You need to pay attention to what you read. It wouldn't ever read âÂÂKERNALâ because that's not how the word is spelled. (If you really found a tutorial that says âÂÂKERNALâÂÂ, ditch it.) Mind you, it wouldn't say âÂÂKERNELâ either, so if you found a tutorial that says that, you should probably ditch it as well.
â Gilles
Nov 19 '17 at 20:52
9
Boot on a live cd, mount the harddisk and locate /etc/password. You will be able to see your username there.
â Thorbjørn Ravn Andersen
Nov 19 '17 at 23:56
14
@ThorbjørnRavnAndersen Isn't that/etc/passwd
?
â Angew
Nov 20 '17 at 9:11
5
@Angew Typically, yes. (This is one reason why answers in comments is almost universally considered poor form. There is no easy way to fix that.)
â Michael Kjörling
Nov 20 '17 at 10:41
3
Errrm, have you asked your friend, who installed it for you ?
â Mawg
Nov 20 '17 at 13:12
add a comment |Â
up vote
16
down vote
favorite
up vote
16
down vote
favorite
My friend had put Linux Mint 17.3 Cinnamon 64 bit on my computer. Well, I forgot the user name, so I did a search on the Net for "forgot username linux" and came here.
I got the suggestion to hit 'e' at the 1st item in GRUB which I did. The next part of the suggestion said to look for a line that started with KERNAL. Now here is where it gets interesting. I didn't find a line with KERNAL in it. However, I did find a line that started with LINUX.
The full unedited line reads:
linux /vmlinuz-3.19.0-32-generic root=UUID=0c031f3a-81ae-4c33-06cc--c82a855736d1 ro quiet splash $vt_handoff
The suggestion then said to look and edit splash quiet
to single
. Now if you notice above it says quiet splash
instead of splash quiet
. So I figured I would edit the quiet splash
to single
.
Now it's asking for a root password. Can anyone help? I suppose I'll need a Live CD.
users password system-recovery
My friend had put Linux Mint 17.3 Cinnamon 64 bit on my computer. Well, I forgot the user name, so I did a search on the Net for "forgot username linux" and came here.
I got the suggestion to hit 'e' at the 1st item in GRUB which I did. The next part of the suggestion said to look for a line that started with KERNAL. Now here is where it gets interesting. I didn't find a line with KERNAL in it. However, I did find a line that started with LINUX.
The full unedited line reads:
linux /vmlinuz-3.19.0-32-generic root=UUID=0c031f3a-81ae-4c33-06cc--c82a855736d1 ro quiet splash $vt_handoff
The suggestion then said to look and edit splash quiet
to single
. Now if you notice above it says quiet splash
instead of splash quiet
. So I figured I would edit the quiet splash
to single
.
Now it's asking for a root password. Can anyone help? I suppose I'll need a Live CD.
users password system-recovery
edited Nov 20 '17 at 14:09
Federico Poloni
27428
27428
asked Nov 19 '17 at 20:15
Rob Ricci
8413
8413
30
You need to pay attention to what you read. It wouldn't ever read âÂÂKERNALâ because that's not how the word is spelled. (If you really found a tutorial that says âÂÂKERNALâÂÂ, ditch it.) Mind you, it wouldn't say âÂÂKERNELâ either, so if you found a tutorial that says that, you should probably ditch it as well.
â Gilles
Nov 19 '17 at 20:52
9
Boot on a live cd, mount the harddisk and locate /etc/password. You will be able to see your username there.
â Thorbjørn Ravn Andersen
Nov 19 '17 at 23:56
14
@ThorbjørnRavnAndersen Isn't that/etc/passwd
?
â Angew
Nov 20 '17 at 9:11
5
@Angew Typically, yes. (This is one reason why answers in comments is almost universally considered poor form. There is no easy way to fix that.)
â Michael Kjörling
Nov 20 '17 at 10:41
3
Errrm, have you asked your friend, who installed it for you ?
â Mawg
Nov 20 '17 at 13:12
add a comment |Â
30
You need to pay attention to what you read. It wouldn't ever read âÂÂKERNALâ because that's not how the word is spelled. (If you really found a tutorial that says âÂÂKERNALâÂÂ, ditch it.) Mind you, it wouldn't say âÂÂKERNELâ either, so if you found a tutorial that says that, you should probably ditch it as well.
â Gilles
Nov 19 '17 at 20:52
9
Boot on a live cd, mount the harddisk and locate /etc/password. You will be able to see your username there.
â Thorbjørn Ravn Andersen
Nov 19 '17 at 23:56
14
@ThorbjørnRavnAndersen Isn't that/etc/passwd
?
â Angew
Nov 20 '17 at 9:11
5
@Angew Typically, yes. (This is one reason why answers in comments is almost universally considered poor form. There is no easy way to fix that.)
â Michael Kjörling
Nov 20 '17 at 10:41
3
Errrm, have you asked your friend, who installed it for you ?
â Mawg
Nov 20 '17 at 13:12
30
30
You need to pay attention to what you read. It wouldn't ever read âÂÂKERNALâ because that's not how the word is spelled. (If you really found a tutorial that says âÂÂKERNALâÂÂ, ditch it.) Mind you, it wouldn't say âÂÂKERNELâ either, so if you found a tutorial that says that, you should probably ditch it as well.
â Gilles
Nov 19 '17 at 20:52
You need to pay attention to what you read. It wouldn't ever read âÂÂKERNALâ because that's not how the word is spelled. (If you really found a tutorial that says âÂÂKERNALâÂÂ, ditch it.) Mind you, it wouldn't say âÂÂKERNELâ either, so if you found a tutorial that says that, you should probably ditch it as well.
â Gilles
Nov 19 '17 at 20:52
9
9
Boot on a live cd, mount the harddisk and locate /etc/password. You will be able to see your username there.
â Thorbjørn Ravn Andersen
Nov 19 '17 at 23:56
Boot on a live cd, mount the harddisk and locate /etc/password. You will be able to see your username there.
â Thorbjørn Ravn Andersen
Nov 19 '17 at 23:56
14
14
@ThorbjørnRavnAndersen Isn't that
/etc/passwd
?â Angew
Nov 20 '17 at 9:11
@ThorbjørnRavnAndersen Isn't that
/etc/passwd
?â Angew
Nov 20 '17 at 9:11
5
5
@Angew Typically, yes. (This is one reason why answers in comments is almost universally considered poor form. There is no easy way to fix that.)
â Michael Kjörling
Nov 20 '17 at 10:41
@Angew Typically, yes. (This is one reason why answers in comments is almost universally considered poor form. There is no easy way to fix that.)
â Michael Kjörling
Nov 20 '17 at 10:41
3
3
Errrm, have you asked your friend, who installed it for you ?
â Mawg
Nov 20 '17 at 13:12
Errrm, have you asked your friend, who installed it for you ?
â Mawg
Nov 20 '17 at 13:12
add a comment |Â
3 Answers
3
active
oldest
votes
up vote
35
down vote
Exactly what happens when you replace quiet splash
or splash quiet
(the order doesn't matter) by single
depends on the distribution. Most distributions will ask for a root password.
If you don't remember the root password, or you just want to boot in the most minimal way, you can replace quiet splash
(and $vt_handoff
, for that matter) by init=/bin/bash
. The line should look like
linux /vmlinuz-⦠root=⦠ro init=/bin/bash
The amount of whitespace between the parts doesn't matter, just leave at least one space wherever there was one before. The parts that I replaced by â¦
above do matter, you must leave what was there before. Remove everything except for the leading word linux
, the word after that, root=â¦
and ro
, and add init=/bin/bash
.
When you boot, you'll get a bash command line, running as root. When you have physical access, the only security that could prevent you from getting in is encryption. (If your system has full-disk encryption, you will need to enter the encryption password.)
At this command line, run the following commands:
mount -o remount,rw /
mount /proc
Then you can view and modify the user database. The main user database file is /etc/passwd
. It contains user names (for both physical users and system accounts), but passwords are in a different file /etc/shadow
. Both files are human-readable up to a point. You cannot recover passwords though; if you've forgotten a password, all you can do is change it.
The following command lists accounts that have a password:
grep -v ':[*!]:' /etc/shadow
(Type it carefully, it's pretty sensitive to the exact punctuation.) The first part of each line, before the first :
sign, is the username.
If you want to change the password for an account, run
passwd rob
where rob
is the username.
Once you've noted the username and changed the password if desired, run
mount -o remount,ro /
reboot
6
OP has forgot their username, but don't say anything about the password. For that use case, justcat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run throughpasswd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "runcat /etc/passwd
, look for a reasonable name in the first field, then runreboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).
â Michael Kjörling
Nov 20 '17 at 10:40
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
add a comment |Â
up vote
14
down vote
Follow these steps:
- boot from a live cd
- open a terminal in the live environment
- run command
lsblk
, you will get a list of drives and partitions. One of these should be the root partition in which you installed linux mint (sdxn, x being a letter, n being a number?). - mount the root partition on an empty directory
- open
etc/passwd
file in the mounted partition. this should contain your username in one of the lines, you should be able to identify it.
add a comment |Â
up vote
0
down vote
http://www.microhowto.info/howto/reset_a_forgotten_root_password_using_a_live_distribution.html
That article seems to cover it well. Yes, you need a live cd.
In the article he gives you an alternate, and he notes, very risky method, of directly editing the password file. Follow his advice and do not try that.
it's not worth copying over verbatim his method, because it's well explained and complete, as well as being as verbose as necessary to do all the steps, with the code examples for each step.
It's not hard, just follow the directions closely.
Basically you boot into the live cd on the system you want to update, then you mount the root file system on the system to be updated, chroot to that mount point, then use passwd to change the password. It may sound intimidating, but really it's not. Note that some systems have /mnt, and others have /media, as defaults, just use which ever your live cd comes with when creating the mount
directory, that does not matter at all, it's a just a path you are going to use when you chroot into the system you are trying to update the password on.
Many live cds, by the way, will give you root with this command (I think that's it, it's been a while, heh):
sudo su -
You will need to be root to do those actions on the live cd, so just check the live cd docs on how it allows the root user to login to the shell on the live cd.
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
add a comment |Â
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
35
down vote
Exactly what happens when you replace quiet splash
or splash quiet
(the order doesn't matter) by single
depends on the distribution. Most distributions will ask for a root password.
If you don't remember the root password, or you just want to boot in the most minimal way, you can replace quiet splash
(and $vt_handoff
, for that matter) by init=/bin/bash
. The line should look like
linux /vmlinuz-⦠root=⦠ro init=/bin/bash
The amount of whitespace between the parts doesn't matter, just leave at least one space wherever there was one before. The parts that I replaced by â¦
above do matter, you must leave what was there before. Remove everything except for the leading word linux
, the word after that, root=â¦
and ro
, and add init=/bin/bash
.
When you boot, you'll get a bash command line, running as root. When you have physical access, the only security that could prevent you from getting in is encryption. (If your system has full-disk encryption, you will need to enter the encryption password.)
At this command line, run the following commands:
mount -o remount,rw /
mount /proc
Then you can view and modify the user database. The main user database file is /etc/passwd
. It contains user names (for both physical users and system accounts), but passwords are in a different file /etc/shadow
. Both files are human-readable up to a point. You cannot recover passwords though; if you've forgotten a password, all you can do is change it.
The following command lists accounts that have a password:
grep -v ':[*!]:' /etc/shadow
(Type it carefully, it's pretty sensitive to the exact punctuation.) The first part of each line, before the first :
sign, is the username.
If you want to change the password for an account, run
passwd rob
where rob
is the username.
Once you've noted the username and changed the password if desired, run
mount -o remount,ro /
reboot
6
OP has forgot their username, but don't say anything about the password. For that use case, justcat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run throughpasswd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "runcat /etc/passwd
, look for a reasonable name in the first field, then runreboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).
â Michael Kjörling
Nov 20 '17 at 10:40
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
add a comment |Â
up vote
35
down vote
Exactly what happens when you replace quiet splash
or splash quiet
(the order doesn't matter) by single
depends on the distribution. Most distributions will ask for a root password.
If you don't remember the root password, or you just want to boot in the most minimal way, you can replace quiet splash
(and $vt_handoff
, for that matter) by init=/bin/bash
. The line should look like
linux /vmlinuz-⦠root=⦠ro init=/bin/bash
The amount of whitespace between the parts doesn't matter, just leave at least one space wherever there was one before. The parts that I replaced by â¦
above do matter, you must leave what was there before. Remove everything except for the leading word linux
, the word after that, root=â¦
and ro
, and add init=/bin/bash
.
When you boot, you'll get a bash command line, running as root. When you have physical access, the only security that could prevent you from getting in is encryption. (If your system has full-disk encryption, you will need to enter the encryption password.)
At this command line, run the following commands:
mount -o remount,rw /
mount /proc
Then you can view and modify the user database. The main user database file is /etc/passwd
. It contains user names (for both physical users and system accounts), but passwords are in a different file /etc/shadow
. Both files are human-readable up to a point. You cannot recover passwords though; if you've forgotten a password, all you can do is change it.
The following command lists accounts that have a password:
grep -v ':[*!]:' /etc/shadow
(Type it carefully, it's pretty sensitive to the exact punctuation.) The first part of each line, before the first :
sign, is the username.
If you want to change the password for an account, run
passwd rob
where rob
is the username.
Once you've noted the username and changed the password if desired, run
mount -o remount,ro /
reboot
6
OP has forgot their username, but don't say anything about the password. For that use case, justcat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run throughpasswd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "runcat /etc/passwd
, look for a reasonable name in the first field, then runreboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).
â Michael Kjörling
Nov 20 '17 at 10:40
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
add a comment |Â
up vote
35
down vote
up vote
35
down vote
Exactly what happens when you replace quiet splash
or splash quiet
(the order doesn't matter) by single
depends on the distribution. Most distributions will ask for a root password.
If you don't remember the root password, or you just want to boot in the most minimal way, you can replace quiet splash
(and $vt_handoff
, for that matter) by init=/bin/bash
. The line should look like
linux /vmlinuz-⦠root=⦠ro init=/bin/bash
The amount of whitespace between the parts doesn't matter, just leave at least one space wherever there was one before. The parts that I replaced by â¦
above do matter, you must leave what was there before. Remove everything except for the leading word linux
, the word after that, root=â¦
and ro
, and add init=/bin/bash
.
When you boot, you'll get a bash command line, running as root. When you have physical access, the only security that could prevent you from getting in is encryption. (If your system has full-disk encryption, you will need to enter the encryption password.)
At this command line, run the following commands:
mount -o remount,rw /
mount /proc
Then you can view and modify the user database. The main user database file is /etc/passwd
. It contains user names (for both physical users and system accounts), but passwords are in a different file /etc/shadow
. Both files are human-readable up to a point. You cannot recover passwords though; if you've forgotten a password, all you can do is change it.
The following command lists accounts that have a password:
grep -v ':[*!]:' /etc/shadow
(Type it carefully, it's pretty sensitive to the exact punctuation.) The first part of each line, before the first :
sign, is the username.
If you want to change the password for an account, run
passwd rob
where rob
is the username.
Once you've noted the username and changed the password if desired, run
mount -o remount,ro /
reboot
Exactly what happens when you replace quiet splash
or splash quiet
(the order doesn't matter) by single
depends on the distribution. Most distributions will ask for a root password.
If you don't remember the root password, or you just want to boot in the most minimal way, you can replace quiet splash
(and $vt_handoff
, for that matter) by init=/bin/bash
. The line should look like
linux /vmlinuz-⦠root=⦠ro init=/bin/bash
The amount of whitespace between the parts doesn't matter, just leave at least one space wherever there was one before. The parts that I replaced by â¦
above do matter, you must leave what was there before. Remove everything except for the leading word linux
, the word after that, root=â¦
and ro
, and add init=/bin/bash
.
When you boot, you'll get a bash command line, running as root. When you have physical access, the only security that could prevent you from getting in is encryption. (If your system has full-disk encryption, you will need to enter the encryption password.)
At this command line, run the following commands:
mount -o remount,rw /
mount /proc
Then you can view and modify the user database. The main user database file is /etc/passwd
. It contains user names (for both physical users and system accounts), but passwords are in a different file /etc/shadow
. Both files are human-readable up to a point. You cannot recover passwords though; if you've forgotten a password, all you can do is change it.
The following command lists accounts that have a password:
grep -v ':[*!]:' /etc/shadow
(Type it carefully, it's pretty sensitive to the exact punctuation.) The first part of each line, before the first :
sign, is the username.
If you want to change the password for an account, run
passwd rob
where rob
is the username.
Once you've noted the username and changed the password if desired, run
mount -o remount,ro /
reboot
answered Nov 19 '17 at 21:04
Gilles
507k12010031531
507k12010031531
6
OP has forgot their username, but don't say anything about the password. For that use case, justcat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run throughpasswd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "runcat /etc/passwd
, look for a reasonable name in the first field, then runreboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).
â Michael Kjörling
Nov 20 '17 at 10:40
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
add a comment |Â
6
OP has forgot their username, but don't say anything about the password. For that use case, justcat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run throughpasswd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "runcat /etc/passwd
, look for a reasonable name in the first field, then runreboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).
â Michael Kjörling
Nov 20 '17 at 10:40
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
6
6
OP has forgot their username, but don't say anything about the password. For that use case, just
cat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run through passwd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "run cat /etc/passwd
, look for a reasonable name in the first field, then run reboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).â Michael Kjörling
Nov 20 '17 at 10:40
OP has forgot their username, but don't say anything about the password. For that use case, just
cat /etc/passwd
will likely be enough; no need to remount the root file system read-write, or run through passwd
. Basically, if OP knows their password but has somehow forgot their username, everything from "At this command line, run..." onward can pretty much be replaced by "run cat /etc/passwd
, look for a reasonable name in the first field, then run reboot
and try that name for login" (expanded upon with some on how to do that because I'm running out of space in the margin).â Michael Kjörling
Nov 20 '17 at 10:40
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
Also, on some systems mount will need an -n switch.
â rackandboneman
Nov 20 '17 at 22:35
add a comment |Â
up vote
14
down vote
Follow these steps:
- boot from a live cd
- open a terminal in the live environment
- run command
lsblk
, you will get a list of drives and partitions. One of these should be the root partition in which you installed linux mint (sdxn, x being a letter, n being a number?). - mount the root partition on an empty directory
- open
etc/passwd
file in the mounted partition. this should contain your username in one of the lines, you should be able to identify it.
add a comment |Â
up vote
14
down vote
Follow these steps:
- boot from a live cd
- open a terminal in the live environment
- run command
lsblk
, you will get a list of drives and partitions. One of these should be the root partition in which you installed linux mint (sdxn, x being a letter, n being a number?). - mount the root partition on an empty directory
- open
etc/passwd
file in the mounted partition. this should contain your username in one of the lines, you should be able to identify it.
add a comment |Â
up vote
14
down vote
up vote
14
down vote
Follow these steps:
- boot from a live cd
- open a terminal in the live environment
- run command
lsblk
, you will get a list of drives and partitions. One of these should be the root partition in which you installed linux mint (sdxn, x being a letter, n being a number?). - mount the root partition on an empty directory
- open
etc/passwd
file in the mounted partition. this should contain your username in one of the lines, you should be able to identify it.
Follow these steps:
- boot from a live cd
- open a terminal in the live environment
- run command
lsblk
, you will get a list of drives and partitions. One of these should be the root partition in which you installed linux mint (sdxn, x being a letter, n being a number?). - mount the root partition on an empty directory
- open
etc/passwd
file in the mounted partition. this should contain your username in one of the lines, you should be able to identify it.
edited Dec 8 '17 at 8:32
answered Nov 19 '17 at 20:27
saga
874219
874219
add a comment |Â
add a comment |Â
up vote
0
down vote
http://www.microhowto.info/howto/reset_a_forgotten_root_password_using_a_live_distribution.html
That article seems to cover it well. Yes, you need a live cd.
In the article he gives you an alternate, and he notes, very risky method, of directly editing the password file. Follow his advice and do not try that.
it's not worth copying over verbatim his method, because it's well explained and complete, as well as being as verbose as necessary to do all the steps, with the code examples for each step.
It's not hard, just follow the directions closely.
Basically you boot into the live cd on the system you want to update, then you mount the root file system on the system to be updated, chroot to that mount point, then use passwd to change the password. It may sound intimidating, but really it's not. Note that some systems have /mnt, and others have /media, as defaults, just use which ever your live cd comes with when creating the mount
directory, that does not matter at all, it's a just a path you are going to use when you chroot into the system you are trying to update the password on.
Many live cds, by the way, will give you root with this command (I think that's it, it's been a while, heh):
sudo su -
You will need to be root to do those actions on the live cd, so just check the live cd docs on how it allows the root user to login to the shell on the live cd.
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
add a comment |Â
up vote
0
down vote
http://www.microhowto.info/howto/reset_a_forgotten_root_password_using_a_live_distribution.html
That article seems to cover it well. Yes, you need a live cd.
In the article he gives you an alternate, and he notes, very risky method, of directly editing the password file. Follow his advice and do not try that.
it's not worth copying over verbatim his method, because it's well explained and complete, as well as being as verbose as necessary to do all the steps, with the code examples for each step.
It's not hard, just follow the directions closely.
Basically you boot into the live cd on the system you want to update, then you mount the root file system on the system to be updated, chroot to that mount point, then use passwd to change the password. It may sound intimidating, but really it's not. Note that some systems have /mnt, and others have /media, as defaults, just use which ever your live cd comes with when creating the mount
directory, that does not matter at all, it's a just a path you are going to use when you chroot into the system you are trying to update the password on.
Many live cds, by the way, will give you root with this command (I think that's it, it's been a while, heh):
sudo su -
You will need to be root to do those actions on the live cd, so just check the live cd docs on how it allows the root user to login to the shell on the live cd.
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
add a comment |Â
up vote
0
down vote
up vote
0
down vote
http://www.microhowto.info/howto/reset_a_forgotten_root_password_using_a_live_distribution.html
That article seems to cover it well. Yes, you need a live cd.
In the article he gives you an alternate, and he notes, very risky method, of directly editing the password file. Follow his advice and do not try that.
it's not worth copying over verbatim his method, because it's well explained and complete, as well as being as verbose as necessary to do all the steps, with the code examples for each step.
It's not hard, just follow the directions closely.
Basically you boot into the live cd on the system you want to update, then you mount the root file system on the system to be updated, chroot to that mount point, then use passwd to change the password. It may sound intimidating, but really it's not. Note that some systems have /mnt, and others have /media, as defaults, just use which ever your live cd comes with when creating the mount
directory, that does not matter at all, it's a just a path you are going to use when you chroot into the system you are trying to update the password on.
Many live cds, by the way, will give you root with this command (I think that's it, it's been a while, heh):
sudo su -
You will need to be root to do those actions on the live cd, so just check the live cd docs on how it allows the root user to login to the shell on the live cd.
http://www.microhowto.info/howto/reset_a_forgotten_root_password_using_a_live_distribution.html
That article seems to cover it well. Yes, you need a live cd.
In the article he gives you an alternate, and he notes, very risky method, of directly editing the password file. Follow his advice and do not try that.
it's not worth copying over verbatim his method, because it's well explained and complete, as well as being as verbose as necessary to do all the steps, with the code examples for each step.
It's not hard, just follow the directions closely.
Basically you boot into the live cd on the system you want to update, then you mount the root file system on the system to be updated, chroot to that mount point, then use passwd to change the password. It may sound intimidating, but really it's not. Note that some systems have /mnt, and others have /media, as defaults, just use which ever your live cd comes with when creating the mount
directory, that does not matter at all, it's a just a path you are going to use when you chroot into the system you are trying to update the password on.
Many live cds, by the way, will give you root with this command (I think that's it, it's been a while, heh):
sudo su -
You will need to be root to do those actions on the live cd, so just check the live cd docs on how it allows the root user to login to the shell on the live cd.
edited Nov 19 '17 at 20:27
answered Nov 19 '17 at 20:21
Lizardx
1,581410
1,581410
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
add a comment |Â
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
Thanks to all of you. I'll let know what happens. One more question: Was it right for me to start a new thread or should I have used another one?
â Rob Ricci
Nov 19 '17 at 20:43
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
It depends on if the same question has been asked verbatim or not. I didn't search, I should have. But I'd say, if you searched, or gave it a good try, and didn't find it, then tacking onto an existing thread is probably inappropriate. Mods can determine if it's duplicated or not. I liked your question, because while I never lose my passwords, it was nice to see how easy it would be to recover them were I to lose them, so on my part, thanks for asking the question.
â Lizardx
Nov 19 '17 at 20:51
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f405649%2fcant-log-in-because-i-forgot-my-user-name%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
30
You need to pay attention to what you read. It wouldn't ever read âÂÂKERNALâ because that's not how the word is spelled. (If you really found a tutorial that says âÂÂKERNALâÂÂ, ditch it.) Mind you, it wouldn't say âÂÂKERNELâ either, so if you found a tutorial that says that, you should probably ditch it as well.
â Gilles
Nov 19 '17 at 20:52
9
Boot on a live cd, mount the harddisk and locate /etc/password. You will be able to see your username there.
â Thorbjørn Ravn Andersen
Nov 19 '17 at 23:56
14
@ThorbjørnRavnAndersen Isn't that
/etc/passwd
?â Angew
Nov 20 '17 at 9:11
5
@Angew Typically, yes. (This is one reason why answers in comments is almost universally considered poor form. There is no easy way to fix that.)
â Michael Kjörling
Nov 20 '17 at 10:41
3
Errrm, have you asked your friend, who installed it for you ?
â Mawg
Nov 20 '17 at 13:12