Boot tx2 faster

How can I make tx2 boot in less than 25 seconds?
I’m using Jetpack 4.2.1(REV 2) linux for tx2, Right now it takes about 40 seconds.

Anyone knows a way how to solve this problem ?

I have no specific advise, but if you save a serial console boot log, then actions and their time stamps will be plainly visible. You might find things you can disable. You might find things which wait for a default period before continuing, and those could be set to not wait. Without that you have no way to know what you have to work with. Some serial console information:
http://www.jetsonhacks.com/2017/03/24/serial-console-nvidia-jetson-tx2/

There is a way I can disable nvidia splash screen that appears in boot and all the logs? I hoping that it will make it boot faster.
I guess needs to customize kernel for it. not sure how.

When the GPU first boots there is a very short splash screen (half second?). Again during transition from text mode to GUI there is a very short splash screen with the NVIDIA logo. I think all other moments of seeing a splash are optional. Someone else would have to comment if splash of the NVIDIA logo can be removed, but setup time would likely be unchanged.

There is also the issue of the “quiet” argument to the kernel where you see a splash instead of the Linux kernel startup logs scrolling by (quite a bit longer than half a second). This particular splash in no way changes boot time, it simply hides the boot text. A serial console sees that content even if the monitor hides it with a splash screen, and so timestamps you see there where something seems “long” actually matters. In this case nothing is slowed down by waiting to display the splash screen for a specified time, splash is simply substituting a scroll of unrelated text with a nice picture instead. Shorter scroll, shorter splash. The time where there is a splash due to the quiet kernel argument would be unchanged by displaying text instead of a splash. Do you see “quiet” in “cat /proc/cmdline”? Is this the time you are talking about? If so, then it isn’t splash causing the delay.

You really do need a serial console boot log with timestamps to see what is taking time. Serial console works even before Linux starts, and timestamps would exist from “nearly” the moment the power button is pressed.

As an added note, the kernel load itself is almost instant. Once the kernel loads it executes the “init” system. PID 0 is the kernel process, PID 1 is init. It is from the choices which init makes that boot time varies (PIDs of greater than 1). Removing a feature from the kernel probably won’t speed anything up, although there may be a slight speed improvement in the executing kernel (a very very tiny improvement caused by reducing memory size during various jumps and branches). You would never notice a time improvement from removing most kernel features, but removing the init’s execution of a feature would improve things (of course a missing kernel feature can cause init to not execute the feature, but it is execution of the feature which matters, not the kernel’s support for the feature). But which init detail? Serial console logs will tell you this.

systemd-analyze blame is pointing at some things, am looking for the same thing, tx2 to boot faster, it takes 40 secs to bring up my qt screen.

Found that having the usb debug cable attached really slows the boot process.