Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- stefan@halley ~ $ cat /mnt/KVM/Gentoo/startGentoo64.sh
- #!/bin/bash
- #
- # This seems complicated, so here are the parts:
- start_vm()
- {
- local conf=""
- # network config, see http://en.gentoo-wiki.com/wiki/KVM_with_VDE
- # conf="${conf} -net vde -net nic,vlan=0,macaddr=52:54:00:00:EE:03"
- conf="${conf} -net nic,macaddr=00:00:00:00:00:00 -net tap,ifname=tap0,script=no,downscript=no"
- # 1GB RAM
- conf="${conf} -m 1024"
- # time setting (localtime or utc): host has localtime for dual-boot with windows
- conf="${conf} -localtime"
- # hard disk image
- conf="${conf} -hda /mnt/KVM/Gentoo/gentoo-amd64.img"
- # boot from CD for installation
- # conf="${conf} -cdrom /mnt/KVM/ISO/systemrescuecd-x86-2.8.0.iso"
- conf="${conf} -cdrom /mnt/KVM/ISO/install-amd64-minimal-20120531.iso"
- # boot from CD-ROM first, switch back to default order after reboot
- conf="${conf} -boot d"
- # now start qemu-kvm
- qemu-kvm $conf &
- }
- start_vm
Advertisement
Add Comment
Please, Sign In to add comment