Screwed up ch 6 of Linux from scratch, need a bit of help

Hi, I’m new to this and would appreciate any help, I’m currently at chapter 6 of LFS. As a result of me just being sloppy, I accidentally typed “rm -Rf grub-2.02.tar.xz” while trying to remove groff-1.22.4., not grub. When I tried “tar -xvf grub-2.02.tar.xz” it of course says that there’s no such file now, and I can’t figure out how to get it back. I tried wget followed by the grub link, this is what happened:

(lfs chroot) root:/sources# wget http://ftp.gnu.org/gnu/grub/grub-2.02.tar.xz
bash: wget: command not found

Do I have to do this outside of the sources directory? Or under a different user? I used wget earlier in the LFS process and it worked.

Thank you

What does the output of

find / -name wget

Say?

1 Like

Sounds like wget (and probably /usr/bin) is no longer in your PATH environment variable. Did you logout and then back in without your initializing your guest environment?

1 Like

Thanks. I tried that and nothing was returned, I assume that means that it doesn’t exist.

I don’t think so. I haven’t logged out at all since creating the LFS variable, I’ve kept the system on through the whole process. I think I was using wget from the host system before, now in my new LFS system it doesn’t work because it’s not installed. I tried to apt-get install wget, but I get the same “command not found” message from bash about apt-get. I may just start the LFS process over if I can’t figure it out.