页面

2008-10-24

Forge Virtual Machine with BOCHS

A brand new BOCHS machine has been done on my Debian! I do it as:
  1. Install bochs and bochs VGA lib:
    $ aptitude install bochs bochs-x
  2. Create a virtual hard drive:
    $ bximage
  3. Use and revise the bochs configuration template file: bochsrc. You may find it out. Mine is the follows:
    config_interface: textconfig
    display_library: x
    #romimage: file=/usr/share/bochs/BIOS-bochs-latest, address=0xf0000
    romimage: file=$BXSHARE/BIOS-bochs-latest
    megs: 1024
    vgaromimage: file=/usr/share/vgabios/vgabios.bin
    #floppya: 1_44=/dev/fd0, status=inserted
    ata0: enabled=1, ioaddr1=0x1f0, ioaddr2=0x3f0, irq=14
    ata1: enabled=0, ioaddr1=0x170, ioaddr2=0x370, irq=15
    #ata2: enabled=0, ioaddr1=0x1e8, ioaddr2=0x3e0, irq=11
    #ata3: enabled=0, ioaddr1=0x168, ioaddr2=0x360, irq=9
    ata0-master: type=disk, path="/home/be/iso_image/box_windownsxp_12g.img", mode=flat, cylinders=24966, heads=16, spt=63
    #ata0-slave: type=cdrom, path="/dev/cdrom", status=inserted
    ata0-slave: type=cdrom, path="/home/be/iso_image/en_windows_xp_professional_with_service_pack_3_x86_cd_x14-80428.iso", status=inserted

    boot: cdrom

    cpu: count=1, ips=50000000
    #floppy_bootsig_check: disabled=0
    log: /dev/stdout
    panic: action=ask
    error: action=report
    info: action=report
    debug: action=ignore
    debugger_log: -
    com1: enabled=1, dev=/dev/ttyS0
    #parport1: enabled=1, file="/dev/lp0"
    sb16: midimode=1, midi=/dev/midi00, wavemode=1, wave=/dev/dsp, loglevel=2, log=/dev/stdout, dmatimer=600000
    vga_update_interval: 300000
    keyboard_serial_delay: 250
    keyboard_paste_delay: 100000
    #floppy_command_delay: 500
    mouse: enabled=1, type=imps2
    private_colormap: enabled=0
    #ne2k: ioaddr=0x240, irq=9, mac=b0:c4:20:00:00:00, ethmod=linux, ethdev=eth0
    #keyboard_mapping: enabled=0, map=/usr/share/bochs/keymaps/x11-pc-de.map
    #keyboard_type: mf
    #user_shortcut: keys=ctrlaltdel
    #magic_break: enabled=1
    #cmosimage: cmos.img
    #load32bitOSImage: os=nullkernel, path=../kernel.img, iolog=../vga_io.log
    #load32bitOSImage: os=linux, path=../linux.img, iolog=../vga_io.log, initrd=../initrd.img
    #i440fxsupport: enabled=1
    #usb1: enabled=1, ioaddr=0xFF80, irq=10
    usb1: enabled=1, port1=mouse
    #text_snapshot_check: enable
  4. Run the new machine:
    $ bochs -f bochsrc

没有评论: