You are not logged in.
Logged in as root, I changed username with usermod, copy paste of old username from /etc/passwd, then change of password with passwd.
Thank you all!
I could do with a graphical keyboard or character map to type the dead letters until I have the new keyboard.
@aitor
After using the passwd -R command
I followed your excellent step-by-step description, exited the chrooted system and unmounted /mnt.
(Without the exit it didn't work.)
Apparently passwd has built-in chroot
# passwd -R /mnt
You're a genius !!!!!!
Just copy all the required text from an existing document or website in to a text file and delete what you need until you have your password in the file.
su select the text and middle click in the terminal press enter not return
edit: Then change your password :-)
Sorry if I'm being dense. I can only get into single user mode.
You mean su into root or my personal user from
I don't have a file containing the word but I could find a b somewhere.
What's wrong with copying and pasting your password in?
How? Where do I copy it from?
The ultimate goal is to change my personal user name and password, both of which contain b and n, the dead letters.
Now bind the directories:
# mount -o bind /sys /mnt/sys # mount -t proc proc /mnt/proc # mount -o bind /dev /mnt/dev # mount -o bind /dev/pts /mnt/dev/pts
.
I probably need some of this.
But how do I type bind?
Next problem:
chroot /mnt
Error:
/bin/sh: 0: can't access tty: job control turned off
The linux line on the boot screen specifies ro.
That needs to be changed to rw.
Once booted into single user mode, I executed
mount /dev/sda2 /mnt
No more read-only warning!
Mounted with write access.
Even more simple:
Can I run firefox in single user mode?
Or can I just do command line stuff?
Literally, that's all I want in the short term until I have a new keyboard.
You might need to run /sbin/fsck -y /dev/sda2 or /sbin/fsck.ext4 -y /dev/sda2 to mount it rw.
I tried this. Came back as clean.
Then
mount -o rw /dev/sda2 /mnt
Warning: source write-protected, mounted read-only
Any more ideas to mount read write?
What about
mount -o remount,rw /
I can use wildcards for the mount command, but how do I type remount without n ?
What about
mount -o remount,rw /
I mounted at /mnt.
I can't create /A because the file system is read-only.
How about using backquote with echo to make use of globbing, e.g.
# `echo /?i?/mou?t` /dev/sda1 /A
EDIT: actually might not need backquoting even:
# /?i?/mou?t /dev/sda1 /A
This is a task for creative minds.
My command worked as is without echo.
Read-only mount is the problem now.
Is it an android device?
Yes, no Apple or Windows in this house.
But as per my previous post, I got into single user mode.
I can type the mount command
/?i?/mou?t /de?/sda2 /m?t
The v is broken now too.
I'm getting the warning that the source is write protected and mounted read only.
I never found my Devuan USB and didn't get anywhere with the Debian USB installation stick.
But I got into single user mode via the boot screen.
I managed to type
init=/bin/bash
by copying and pasting the broken letters with Emacs commands.
Now I'm struggling to autocomplete the mount command because there are several in /bin and /sbin
It also thinks I have a QUERTY keyboard but I roughly remember where the keys are.
Head_on_a_Stick wrote:How about ssh from another machine?
Élisabeth wrote:That's my only machine.
Couldn't you try to ssh from the machine you are writing from now?.
I'm typing on my mobile phone. And it's a pain in the back.
In a live system you can copy and paste them from anywhere.
I have a Devuan installation ISO, not live. (I wish I knew where I put it.)
And I think I have a Debian live.
I think a new keyboard is inevitable. If it hasn't dried after three days I don't hold out much hope.
But I'm looking for this interim solution because finding the right one for this laptop might take a bit - a backlit french AZERTY.
There is a way to do it from the boot screen by editing the kernel line. bluesdog has a howto over on the debian forum that I have used but it may be outdated by now. I would copy some notes that I have here but don't trust their accuracy because I haven't had to do it in years . . .
Yes, that's what I tried.
The linux line has to be appended with
init=/bin/bash
I don't have n and b !
How about having your instalation media still around and using it in rescue mode?
Would that enable me to change my username and password?
Change to another keyboard layout ?
That's my only machine.
Actually, I need creative ideas to work around a keyboard problem, which has locked me out of my laptop:
I spilt water on my keyboard three days ago and the letters b and n are no longer working.
I can't log in now because my username and passwords contain b.
I wanted to log in as root to change those but the root password contains a b too.
I found instructions how to reset the root password on Debian. But this requires typing init=/bin/bash on grub.
Any ideas for a temporary workaround?
I have no USB keyboard nor friends who have one. I live in the sticks without ready access to shops.
I just need a smart idea.
This only happens following lid action.
If I suspend or lock screen manually, I am presented with a visible password dialog on resume.
If I switch Security Lock screen off, the problem does not occur.
When testing my irrelavant grub config changes yesterday, I got the password dialog, which led me to believe they changes had been successful. However, this seems to happen occasionally when the lid is closed and opened quickly.