Recommendation to boot / resume Linux in less than a second...

It looks well represented, http://en.wikipedia.org/wiki/Systemd#Adoption

Maxim, for distro’s like Debian which is slow moving for stability reason. I would imagine the Debian team wants the technology proven before they make the leap. From what I understand, the next iteration of Debian will include systemd, and it is an apt-get-able package for wheezy right now.

Also according to what I’ve read, it will work right along side SYSV, or at least init scripts, with no harm to anything, except perhaps slower boot times ( versus just using systemd by its self ).

If you really want to know about it, I would suggest you do a bit of googling. There is lots of information out there about it, it is just that I have not been able to find a decent simple example of how to setup services yet. This is either because I’m not searching for the correct thing, or the documentation on the whole process is jut limited right now.

The key point, is if Debian is going to move to using it, it is probably worth researching yourself.

Also, as far as I know. ARCH uses systemd by default. However, since I do not personally use ARCH, this is pure speculation on my own behalf. I’ve also read that fedora, and a few others use systemd as well.

If this is for automotive ,systemd is not so useful
last mode is required when in automotive enviroment
while as I know systemd can not turnning boot sequence for different modules
If not about automotive ,skip this .
And,if only talking about 0.5s or 1s , its only about u-boot and kernel

what I test in imx 6 , whats’ my test result is boot from nand slc onfi1@80M
Arm@800M with 16bit DDR@400m

unless you remove kernel printk, its possible boot less than 1s

remove any print out from serial ,boot loader turn mmu can cache on

load kernel with uncompressed and make small than 4M,without prink

actually I remove lots of in kernel .the best time is about less than 1s

but also double check with lzo... As it can beat uncompressed...

http://free-electrons.com/blog/arm-xz-kernel-decompression-benchmarks/

Regards,

This is depends on your SOC main clock and cache size and nand /eMMC read speed
If on 512K L2 cache and over than 1G , lzo MAYBE will beat uncompressed
but in less than 500M and with very fast nand 16bit EDO ddr mode /eMMC 50M@8bit with ADMA
what I get test result is raw (uncompressed) kernel image will be the better choice on iMX6

You can see the test result from the link ,

None | 6965644 | 4.626749 | 0 | 4.626749 |

  • | - | - | - | - |

Ti dont have eDMA and ADMA enable as default in previous u-boot driver
While this is patched in 2014.04 version on omap5 and dra7x driver
It wont take over than 1s while loading 6M size kernel image
What I test on imx6 , u-boot with ADMA driver enable on eMMC 4.4 @8bit 50M
Will over than 15MBytes /s
And with APBH DMA enable in 8bit nand driver @100M EDO mode enable
Will over than 15MBytes/s too

So , what I suggest , you should check your u-boot driver , and make sure ADMA enable for eMMC/sd

https://www.dropbox.com/s/ltnedy59gv5i70j/VID_20140723_084207.mp4

This is what I have done in my iMX6 solo @800M 16bit ddr board

Hi,

### Yaoshi, really nice job! If you could share some instructions on how to make imx6 boot faster - it would be great!

As I said

  1. Turn mmu and cache on,use dma in u-boot, remove any you dont needed code

  2. Remove code you dont needed , or make as modules in kernel

  3. Dont print in serial port

  4. And use wayland instead of X11

  5. make sure font cache prepared in write able folder

Some not so good options
1)overclock
2)remove printk in kernel
3)sstrip your binary code (this will cause QT plugin failed load)

You should define what "boot time" is.

You could say that is:
• The time that that takes to your device from power on until you can
run a user space program.
• Power on until getting X11
• Power on until ssh connection

Did your <2 seconds means this the first option? Or only the kernel logs?

Yaoshi,

for the first point - is it possible to enable MMU/DMA just by checking some options in the ENV file or it requires hard code hacking?

I can confirm this: debian is going to default on systemd in jessie
(the next release, currently in freeze) and Ubuntu is considering
dropping upstart and moving to systemd because of it.

https://lists.debian.org/debian-ctte/2014/02/msg00405.html

http://www.markshuttleworth.com/archives/1316

Other mayor distros had already been using it for a while, e.g.
Fedora and Arch Linux.

I use hard code

less than 2 seconds get in first shell ,and about 5 seconds get in first qt demo for wayland client

@robert.berger,

Did you read my whole post ?

william@eee-pc:~$ uname -a
Linux eee-pc 3.2.0-4-686-pae #1 SMP Debian 3.2.60-1+deb7u3 i686 GNU/Linux
william@eee-pc:~$ pstree
init─┬─acpid
├─cron
├─dbus-daemon
├─6*[getty]
├─nmbd
├─rpc.idmapd
├─rpc.mountd
├─rpc.statd
├─rpcbind
├─rsyslogd───3*[{rsyslogd}]
├─smbd───smbd
├─sshd───sshd───sshd───bash───pstree
├─udevd───2*[udevd]
└─winbindd───3*[winbindd]

Doesnt seem to be using it here on the latest stable release.

Debian 7: (Wheezy) defaulted to sys-v, systemd was only an option.
(which we enabled by default for bb.org)

Debian 8: (Jessie, (currently unstable, released sometime in 2015)) is
defaulting to systemd..

Regards,

Which is pretty much what I said yesterday.

Q: Have you guys ever tried reducing boot-times through a hibernate-based solution? (e.g. Warp) How do these stackup versus efforts to fast-boot Linux as detailed in this thread?

This won’t work at this time:

http://www.spinics.net/lists/linux-omap/msg109331.html

Regards,
John

Hi John, thanks for the heads up on that patch.

When you say it doesn’t work at this time, is it because it’s temporarily broken for embedded? If it gets fixed, would you recommend this patch for our needs?

Q1: Given several senior devs are reporting amazing 1s boot-time on i.MX6, should I take from this it’s the platform of choice for quick-booting Linux?

Q2: Given the above, should I even consider hibernate-based solutions such as Warp?