Reducing OS Boot Times for In-Car Computer Applications, Part III
The Epia patches include one called epia-fbdev, which leads to this encouragement from the LinuxBIOS mailing list:
El Jueves, 13 de Mayo de 2004 18:46, John Laur escribi?: > If you have VGA correctly working with LinuxBIOS (Ie you see the > linuxbios logo on startup), then you have VGA working as best it does > with LinuxBIOS. > > Then you can worry about the kernel. VESA Framebuffer does not work with > EPIA-M as the VGA bios doesn't initialize the video card up to where > vesafb can take over. You have to use viafb (part of the -epia patchset) > to get video on the console. Make sure you have it compiled into the > kernel and not as a module. Make sure vesafb is NOT compiled in either, > otherwise you'll need some commandline trickery to make it work. Also, > viafb doesn't work with bootsplash in silent mode on kernel 2.4 if you > are using that. I have not tested with kernel 2.6. > > John
However, all the flavors of epia-fbdev I tried hung the machine or produced scrambled text.
Anyway, one should build a kernel in the normal way. I unpacked the kernel, configured it and issue
make dep && make bzImage && make modules
Then, to install the modules somewhere so I could copy them to the Flash, I entered:
INSTALL_MOD_PATH=/home2/jamesh/linux-fast/ make modules_install
That command created /home2/jamesh/linux-fast/lib/modules/2.4.26-fast/. Next, make an elf image out of the kernel. This lets you put the command-line arguments in the kernel file itself and allows the bootloader to determine how big the kernel is:
/usr/local/sbin/mkelfImage --kernel=linux-2.4.26-fast/arch/i386/boot/bzImage --output=bzImage-2.4.26-fast.elf --command-line="root=/dev/hda4 console=tty0 console=ttyS0,115200n8 rw"
Note that I set root=/dev/hda4. I also set the FILO like so:
AUTOBOOT_FILE = "hda4:/bzImage"
Now, I only needed to put the kernel in /dev/hda4 in the root directory--easy. Next, copy the romimage and flash_and_burn files to your Epia box and run flash_and_burn by itself to see if it recognizes your Flash chip. Typing flash_and_burn romimage burns it.
Now, hook a terminal up to the serial port, set to 115200-n-8-1, and boot. In 20 seconds you should hear Dexter, assuming you are using my ZipSlack image. As you can see, X works but the mouse does not--I don't know why. Type startx to start X.
I've created two disk images. One is UMSDOS, which I unzip into a MS-DOS filesystem on partition 4 of a disk. The other is a tar file that should work on an ext2 or ext3 filesystem.
The full log of our successful boot with fine-grained timings is here, and the following guided tour takes you through the highlights.
I wrote a program to dump the console out from the serial port with a timestamp. Here are some interesting things to note:
It takes .334 seconds to get from power-on to the BIOS.
> 3.492 Copying LinuxBIOS to ram.
Three and a half seconds, and now it's copying the BIOS to shadow. I assume that time was spent finding shadow itself.
> 6.292 Jumping to LinuxBIOS.
Here's a major timewaster: reading from the Flash BIOS chip is slow.
> 6.616 POST: 0x75 > ... > 7.076 POST: 0x95
I have no idea what this really means.
> 7.153 found VGA: vid=1106, did=3122 > ... > 9.533 biosint: Unsupport int #0xcd
This attempts to run the video BIOS I installed. 2.38 seconds can be saved by removing the dir src/bioscall line in epia-config in the FreeBIOS build directory. The only build I have at the moment that skips this step also doesn't send anything to the serial port, so I don't have a log of it.
> 9.574 Welcome to elfboot, the open sourced starter.
We're not out of LinuxBIOS yet.
> 9.722 FILO version 0.4.2
We've finally moved out of LinuxBIOS and into the FILO bootloader.
> 9.792 No sound device found
Yes, that message is in FILO. If you have a sound device that FILO recognizes, it would play a sound at this point. However, I couldn't get it to find the the VIA sound device, not that I tried very hard. But if you were using a mobo with a standalone video card and SB-compatible sound, we would have picture and sound at just under ten seconds.
> 10.013 Loading Linux version ... > 12.242 Jumping to entry point...
Hmm, over two seconds to get the kernel off the Flash and into RAM.
> 13.252 Linux version 2.4.26-fast
This is the actual start of the Linux boot.
> 19.811 Playing Sound
At this point sound is playing out the soundcard--19.811 seconds, or 17.431 if you skip the video BIOS call. Of this, only 6.559 seconds actually is booting Linux.
|Non-Linux FOSS: libnotify, OS X Style||Jun 18, 2013|
|Containers—Not Virtual Machines—Are the Future Cloud||Jun 17, 2013|
|Lock-Free Multi-Producer Multi-Consumer Queue on Ring Buffer||Jun 12, 2013|
|Weechat, Irssi's Little Brother||Jun 11, 2013|
|One Tail Just Isn't Enough||Jun 07, 2013|
|Introduction to MapReduce with Hadoop on Linux||Jun 05, 2013|
- Containers—Not Virtual Machines—Are the Future Cloud
- Non-Linux FOSS: libnotify, OS X Style
- Lock-Free Multi-Producer Multi-Consumer Queue on Ring Buffer
- Linux Systems Administrator
- Validate an E-Mail Address with PHP, the Right Way
- RSS Feeds
- Introduction to MapReduce with Hadoop on Linux
- Weechat, Irssi's Little Brother
- New Products
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Poul-Henning Kamp: welcome to
1 hour 41 min ago
- This has already been done
1 hour 42 min ago
- Reply to comment | Linux Journal
2 hours 28 min ago
- Welcome to 1998
3 hours 16 min ago
- notifier shortcomings
3 hours 40 min ago
5 hours 17 min ago
- Android User
5 hours 18 min ago
- Reply to comment | Linux Journal
7 hours 11 min ago
10 hours 1 min ago
- This is a good post. This
15 hours 14 min ago
Free Webinar: Hadoop
How to Build an Optimal Hadoop Cluster to Store and Maintain Unlimited Amounts of Data Using Microservers
Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Some of key questions to be discussed are:
- What is the “typical” Hadoop cluster and what should be installed on the different machine types?
- Why should you consider the typical workload patterns when making your hardware decisions?
- Are all microservers created equal for Hadoop deployments?
- How do I plan for expansion if I require more compute, memory, storage or networking?