Centos deployment problems on KVM
Hi,
I'm trying to create a VM from Centos ISO file. I've created successfully an interactive Centos 7. But when i tried creating a centos with kickstart file I've encountered some problems This is what I ran: 1. qemu-img create -f qcow2 /opt/disk3.qcow2 20G 2. virt-install --virt-type kvm --name allotOS --ram 4096 --cdrom=/opt/OS.iso --disk /opt/disk3.qcow2,format=qcow2 --network network=default --graphics vnc,listen=0.0.0.0 --noautoconsole --os-type=linux --os-variant=rhel6 3.This is my kickstart file (just the beginning) install # Use DVD installation media cdrom lang en_US.UTF-8 #System keyboard keyboard us #System timezone timezone --utc GMT network --onboot yes --device eth0 --bootproto static --ip 11.11.11.11 --netmask 255.255.0.0 --noipv6 --gateway 11.11.0.1 --nameserver 198.168.254.2 #Root password rootpw --iscrypted $1$R.alKkPn$kzGDYBkJKb3Tc2OcjSFu7. #Initial user #user --name=admin --iscrypted --password=Ce455MjL5TAqc firewall --disabled authconfig --enableshadow --enablemd5 selinux --disabled bootloader --location=mbr --append="crashkernel=auto transparent_hugepage=never rhgb quiet" --driveorder=vda #************PARTITIONING ************************* zerombr ## ignoredisk --only-use=vda clearpart --drives=vda --all --initlabel part / --fstype ext4 --size=20000 --asprimary --ondisk=vda #part swap --size=8192 %include /tmp/swappart part /opt --fstype ext4 --size=100 --grow --asprimary --ondisk=vda #Reboot after installation reboot --eject #Use text mode install #text 4. the error i recieve is: "Boot failed: Couldnt read from CDROM (codde0004) Any advice? Thx |
A few steps that I would have tried:
Can you connect that ISO file to another virtual machine and access it from there? And when does the error occur - before syslinux starts or after? Are there any other messages, error or not, before "boot failed"? I also wonder if SELinux could be involved. If your VM host has SELinux, set it to permissive. Centos 7 now allows checking a kickstart file with the ksvalidator program (yum install pykickstart). Tried it? |
it should NOT be a SE issue on the cent host
installing the KVM from yum will have set the CORRECT SE context Quote:
please use the REAL name "CentOS-7-x86_64-DVD-1503-01.iso" or "CentOS-7-x86_64-Everything-1503-01.iso" |
Issue resolved
The problem was with the ISO file.
The only change made to the original ISO is the change of disks. In original (for physical disks) the disk is sda. For virtual the disk is vda |
All times are GMT -5. The time now is 11:04 PM. |