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

Re: losetup: cannot find an unused loop device , kernel config of loopback device



Hi Thomas,

>The error message of losetup does not match this theory.

Re-reading http://ix.io/3v6K and it does appear that possibly
/mnt/src/host/ does exist based on some of the debugging output.
Thanks for making me look back. I made this "theory" on trying to `ls
/mnt/host/src/rc/build/images/kukui/R94-14125.0.2021_08_05_1510-a1/chromiumos_base_image.bin`
after the script had been executed. I received an error the path
didn't exist. But perhaps it was cleaned up after the script finished
executing.

>Is there a hard reason why you don't show the output of  losetup -l -a

I will now modify the script and also provide before and after below:

before:

(cr) ((b1688d0...)) colin@M00974055-VM ~/chromiumos/src/scripts $ losetup -l -a
-bash: losetup: command not found
(cr) ((b1688d0...)) colin@M00974055-VM ~/chromiumos/src/scripts $ sudo
losetup -l -a
(cr) ((b1688d0...)) colin@M00974055-VM ~/chromiumos/src/scripts $

no output appears

during:

I've added losetup here:
https://github.com/drocsid/cros-scripts/blob/feature/deb11-II/common.sh#L641

ourput after running ./build_image
https://chromium.googlesource.com/chromiumos/docs/+/main/developer_guide.md#Build-a-disk-image-for-your-board
with above changes: http://ix.io/3vfj

after:

colin@M00974055-VM:~/chromiumos/src/scripts$ cat ~/losetup-error.txt |
curl -F 'f:1=<-' ix.io
http://ix.io/3vfj
colin@M00974055-VM:~/chromiumos/src/scripts$ losetup -l -a
-bash: losetup: command not found
colin@M00974055-VM:~/chromiumos/src/scripts$ sudo losetup -l -a
[sudo] password for colin:
colin@M00974055-VM:~/chromiumos/src/scripts$

no output appears.



On Sat, Aug 7, 2021 at 1:19 AM Thomas Schmitt <scdbackup@gmx.net> wrote:
>
> Hi,
>
> Colin Williams:
> > 3) When trying to create the loopback device the script tries to use a
> > path
> > /mnt/host/src/rc/build/images/kukui/R94-14125.0.2021_08_05_1510-a1/chromiumos_base_image.bin
> > which does not exist
>
> The error message of losetup does not match this theory.
>
> Did you make sure that the file really does not exist when the losetup
> command fails ?
> E.g. by performing
>   ls -ld "${image}"
> immediately before
>   lb_dev=$(sudo losetup --show -f "$@" "${image}")
>
>
> > Let me know if I need to re-read your email.
>
> Is there a hard reason why you don't show the output of
>
>   losetup -l -a
>
> before, after, and maybe during the script run ?
>
> (I'm not alone with this proposal. See
>    https://lists.debian.org/debian-user/2021/08/msg00353.html
>  which was not Cd'ed to you.
> )
>
>
> Have a nice day :)
>
> Thomas
>


Reply to: