Android support in snapd


#41

It depends on how much extra seconds it adds, actually. The more seconds, the less interesting it gets, up to the point where we can’t do it anymore. That’s why we need to get more precise figures before moving on with it.


#42

One of the things that was happening is that initramfs debug output was enabled and was being sent through the serial port, which slowed things a bit. Just removing that gets us to 20 seconds.

Re: the time the bootloader takes to load the kernel image/ramdisk, it is around 10 seconds, so that is our lower bound.

We are then in the 10-20 secs interval.


#43

well, the alternative is a rather risky partition switching back and forth between boot and recovery, enforcing of a kernel patch onto customers (to automatically force reboot to recovery on a panic to trigger the rollback there) and quite a set of code changes to snapd (there are a bunch of initial PRs for that already). the result will be a lot more porting work and code to maintain for potential customers, adding a 10sec reboot to an existing 30sec boot still levels that out IMHO.

how do you want to get more precise figures if you dont know how long the pre-boot bits take ? we can surely test on a dragonboard but that wont tell you anything about the future foobar-board that might have an SPL that takes 20sec on its own to initialize the board before switching to the actual second stage bootloader.

the figures we can measure are kernel and initrd and these wont be 30 additional seconds.

we also wont be able to do any measurements at all if we dont move on btw :slight_smile:


#44

I’m pointing out something very straightforward: there’s a limit to how much additional time any reasonable person will tolerate on a boot. We need to evaluate it before we consider this okay. If you disagree, then please let the rest of us figure this out.


#45

i assume you are testing with a generic ubuntu initrd ?
that would be total overkill for the actual implementation, we should weed out everything and turn /init into a simple 20-30 line script (simply the snappy_boot script that we use in uboot with some extra bits added), i can promise you to get you an initrd that runs the whole thing in less than 5sec :wink: