[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Pls help fixing /boot/efi and GRUB



I have rechecked.

It doesn't work with sudo also.

Not in a one line, not when i tried to make line breaks with \, not in a bash script.

user@debian:~$ sudo for i in /dev /dev/pts /proc /sys /sys/firmware/efi/efivars /run; do mount -B $i /mnt/$i; done
bash: syntax error near unexpected token `do'
user@debian:~$ sudo bash bash.sh
mount: /mnt//dev: mount point does not exist.
       dmesg(1) may have more information after failed mount system call.
mount: /mnt//dev/pts: mount point does not exist.
       dmesg(1) may have more information after failed mount system call.
mount: /mnt//proc: mount point does not exist.
       dmesg(1) may have more information after failed mount system call.
mount: /mnt//sys: mount point does not exist.
       dmesg(1) may have more information after failed mount system call.
mount: /mnt//sys/firmware/efi/efivars: mount point does not exist.
       dmesg(1) may have more information after failed mount system call.
mount: /mnt//run: mount point does not exist.
       dmesg(1) may have more information after failed mount system call.
user@debian:~$

сб, 22 мар. 2025 г. в 06:33, Max Nikulin <manikulin@gmail.com>:
On 21/03/2025 20:38, J wrote:
> But i must mention that *this passage from Debian Wiki seems incorrect*
>
>     Bind mount various virtual filesystems:
>
>     # for i in /dev /dev/pts /proc /sys /sys/firmware/efi/efivars /run;
>     do mount -B $i /mnt/$i; done
>
> https://wiki.debian.org/GrubEFIReinstall#Using_the_rEFInd_rescue_media
> *I had to use*
>
>     sudo mount --bind /dev /mnt/dev
>     sudo mount --bind /dev/pts /mnt/dev/pts
>     sudo mount --bind /sys /mnt/sys
>     sudo mount --bind /proc /mnt/proc
>     sudo mount --bind /sys/firmware/efi/efivars /mnt/sys/firmware/efi/efivars

Sorry, but I can not spot anything apparently incorrect. Did you try to
execute the compound shell command by adding just "sudo" in front of it?
With leading "#" it is assumed that it is already a root shell (obtained
by e.g. "sudo -i") and in this case it is important.





Reply to: