Stuck on a problem for months because i forget the password
Slackware - InstallationThis forum is for the discussion of installation issues with Slackware.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Stuck on a problem for months because i forget the password
Good day
I was trying to install Slackware but I have a problem, when I was set up the user root and the visual interfaz I forget the password therefore I try to fix in other ways that I dont remeber good, the problem is this, I turn on the computer and the first screen is this:
GNU GRUB Version 2.06
grub>
I figured that I can boot into the system if I run this comands:
insmod all_video
set root=(hd0,gpt3);
linux /boot/vmlinuz root=/dev/sda1 nomodeset
initrd /boot/initrd.gz;
boot
After that, the screen show me this:
modprobe: ERROR: could not insert ´ext4: Exec format error
mount: mounting /dev/sda1 on /mnt failed: Invalid argument.
ERROR: No /sbin/init found on rootdev (or not mounted). Trouble ahead.
You can try to fix it. Type ´exit´ when things are done.
/bin/sh: cant acces tty: job control turned off
/#
Thing that I know:
This envioremen the system is not monted in rewrite
The problem is not in init command
The problem is at the grub boatloader
I try to restore the factory settings but was useless, do you have any idea what can I do?
You do have a grub problem but you solved it temporarily with the instructions you gave. The error messages which you then got came from the kernel, not from grub. But for some reason, the kernel couldn't load the ext4 filesystem driver module from the initrd and therefore couldn't mount the root partition.
Restoring factory settings was a waste of time; it only affects the firmware, not the bootloader on disk. In this kind of situation the usual procedure is to boot from a rescue image on a CD or memory stick and repair the system from there. You could, for example, have set a new root password that way. But as this is a completely new system, perhaps reinstalling would be easier than trying to fix it. Especially as you/we have no idea what you have done to the system "in ways you can't remember".
Writing down the root password and storing it in a safe place is also useful. Don't beat yourself up, we've all been there.
insmod all_video
set root=(hd0,gpt3);
linux /boot/vmlinuz root=/dev/sda1 nomodeset
initrd /boot/initrd.gz;
boot
modprobe: ERROR: could not insert ´ext4: Exec format error
That error means initrd tries to load module ext4 but the module in initrd is not compiled for the kernel version you boot. You could try to load the huge kernel which has ext4 built in. Change the linux command to
Code:
linux /boot/vmlinuz-huge root=/dev/sda3 nomodeset ro
and don't use the initrd command at all.
Edit: changed root= kernel parameter. Without initrd you need to point kernel to the correct root partition.
Last edited by Petri Kaukasoina; 10-07-2023 at 06:00 AM.
How is it with runlevel 1 in Slackware actually? In some other distroes, runlevel 1 allows you to get a root "maintenance" console without having to log in with a password, so you can change the password there. Is this also the case in Slackware?
How is it with runlevel 1 in Slackware actually? In some other distroes, runlevel 1 allows you to get a root "maintenance" console without having to log in with a password, so you can change the password there. Is this also the case in Slackware?
No, you need to log in even in run level 1.
Instead, you could append 'init=/bin/sh' to the kernel command line to get a root command line without login. At least on systems booting without initrd.
(The OP got a similar command line of the initrd system. That does not help without access to the ext4 root disk.)
Last edited by Petri Kaukasoina; 10-08-2023 at 02:33 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.