[syslinux] Boot Linux ram disk image from DOS prompt

Alexander Foken alexander at foken.de
Wed Jan 30 11:34:54 PST 2013


On 30.01.2013 19:17, Leandro Becker wrote:
> I'm using the 16f version. The error messages are not confidential, but
> hard to get from the screen.

Write them down. Or use a digital camera and take a (literal) screen 
shot. Then type them into your mail program.

> If you think it should be working, maybe
> I'm configuring the command line wrongly. Right now, the commands I'm
> using are:
>   
> loadlin bzImage initrd=init.gz rw root=/dev/ram0
I didn't use loadlin for several years, but I see no obvious errors.

Are you sure your combination of bzImage, init.gz, and root device 
parameter don't cause any errors? Try loading them using Syslinux. If 
that works, but using loadlin fails, you have probably found a loadlin 
bug. If using Syslinux also fails, the problem is probably with the 
kernel image, the ramdisk, or the root device parameter.

>   
> But got errors telling that the RAM disk is smaller that the kernel
> think.
Exact error message?
>   
> Right now I will follow you advice and check the comboot approach.
>   
> Do you think is possible when booting a DOS image with ramdisk make
> some configuration in syslinux to allow the fresh booted DOS see and
> also "mount" my USB media device like an drive B: or something?

DOS does not know about USB devices. Unless the BIOS or some special DOS 
device driver offers legacy support, DOS won't be able to use them.

> Thus I
> can manipulate the syslinux.cfg in the DOS to decide what to boot next.

I would try to get rid of DOS. While DOS *can* still be booted on modern 
machines, it does not mean it *should* be booted. Many legacy programs 
have problems with current high speed CPUs and large disks, and more and 
more devices lack DOS drivers or legacy emulations from BIOS.

Automatically editing files from DOS is possible, but ugly. I thing you 
need a port of sed or awk for DOS for that job, or you create two 
configuration files and copy them over the actually used configuration file.

>   
> One thing I'm starting to consider is the new lua support. I will check
> the docs more deply if is possible to use it to check for and create
> files on my usb memory stick. If possible, I can resolve my needs with
> it.
Syslinux mutates more and more from a linux loader to a small operating 
system, so your chances are getting better from day to day.

What is the purpose of the "test program"?

Can you rewrite it to use the COMBOOT API or to run on bare hardware or 
to use only the common API subset of Syslinux and DOS (the first few INT 
0x21 functions)?

Alexander

>   
> Thank you!
>
>>>> Em Quarta, 30 de Janeiro de 2013 às 12:33, na mensagem
> <51092F4C.5070605 at foken.de>, Alexander Foken <alexander at foken.de>
> gravou:
>
> On 01/30/2013 12:04 PM, Leandro Becker wrote:
>> Hello,
>>    
>> There is a way to boot a ram disk Linux from DOS prompt like the old
>> tool loadlin.exe? I tried it, but getting errors.
>>    
> Check the loadlin version. Loadlin 16f, released 2012-09-17, is the
> current one, it should be able to boot recent kernels. 16e, released
> 2010-08-25, may damage the initial ramdisk when loading Linux. 16d,
> released 2009-02-08, contains code to boot Linux >= 2.6.23, but it
> probably does not boot recent linux kernels.
>
> Alexander
>



More information about the Syslinux mailing list