[one-users] esxi vm instantiation not on scsi disk
Michael Curran
michael.curran at connectsolutions.com
Mon Aug 19 07:17:35 PDT 2013
Javier --
Thanks!! That resolved that portion of the issue
======================
Does anyone know if this is a bug report or a feature request that I need to make?
Vmware ESXi5.1 does not use mkfs to create a raw disk and attach it to the VM instances , it uses vmkfstools to do this task
Mon Aug 19 07:07:24 2013 [VMM][I]:
Mon Aug 19 07:07:24 2013 [VMM][I]: if [ ! -d /vmfs/volumes/102/16/disk.2 ]; then
Mon Aug 19 07:07:24 2013 [VMM][I]: mkdir -p /vmfs/volumes/102/16/disk.2
Mon Aug 19 07:07:24 2013 [VMM][I]: fi
Mon Aug 19 07:07:24 2013 [VMM][I]:
Mon Aug 19 07:07:24 2013 [VMM][I]: mkfs -t RAW /vmfs/volumes/102/16/disk.2" failed: sh: mkfs: not found
Mon Aug 19 07:07:24 2013 [VMM][E]: Could not create image /vmfs/volumes/102/16/disk.2
Mon Aug 19 07:07:24 2013 [VMM][I]: ExitCode: 127
Mon Aug 19 07:07:24 2013 [VMM][I]: Failed to execute transfer manager driver operation: tm_attach.
Mon Aug 19 07:07:24 2013 [VMM][E]: Error attaching new VM Disk: Could not create image /vmfs/volumes/102/16/disk.2
Since it cannot attach a disk using mkfs , it fails to add the additional disk. I suppose I could create a blank disk image and register it in the IMAGES Datastore and attach that for now -- Based on our use of that extra disk and VMware's ability to re-size them (especially for windows), this could lead to a large number of disks to manage on a given VM, instead of the ability to expand the disk.
Michael Curran | connectsolutions | Lead Network Architect
Phone 614.568.2285 | Mobile 614.403.6320 | www.connectsolutions.com
-----Original Message-----
From: Javier Fontan [mailto:jfontan at opennebula.org]
Sent: Monday, August 19, 2013 9:04 AM
To: Michael Curran
Cc: users at lists.opennebula.org
Subject: Re: [one-users] esxi vm instantiation not on scsi disk
Set the disk or image TARGET to "sda" or DEV_PREFIX to "sd".
On Thu, Aug 15, 2013 at 4:09 PM, Michael Curran <michael.curran at connectsolutions.com> wrote:
> So - I am having an issue with building VM's in ESXi from templates
>
>
>
> The root drive always instantiates as IDE and not SCSI - and no SCSI
> adapter is added that would allow me to add more disks to the VM
>
> Looking over this part of scripts_common.sh for VMKFSTOOLS - it
> doesn't appear to look like the build task from VMware's site - I
> don't see the -a that identifies the BUS type
>
>
>
> I have added this to the actual disk IMAGE
>
>
>
> BUS="scsi"
>
>
>
> And these to the template
>
>
>
> DISK=[
>
> BUS="scsi",
>
> IMAGE_ID="0" ]
>
>
>
>
>
> RAW=[
>
> DATA="<devices><controller type='scsi' index='0'
> model='lsilogic'/></devices>",
>
> TYPE="vmware" ]
>
>
>
>
>
> But never see a SCSI attached disk as the primary disk - always IDE
>
>
>
> Any suggestions?
>
>
>
> function mkfs_command {
>
> DST=$1
>
> FSTYPE=${2:-ext3}
>
> SIZE=${3:-0}
>
>
>
> # Specific options for different FS
>
> case "$FSTYPE" in
>
> "ext2"|"ext3"|"ext4"|"ntfs")
>
> OPTS="-F"
>
> ;;
>
>
>
> "reiserfs")
>
> OPTS="-f -q"
>
> ;;
>
>
>
> "jfs")
>
> OPTS="-q"
>
> ;;
>
> "raw"|"")
>
> echo ""
>
> return 0
>
> ;;
>
> "swap")
>
> echo "$MKSWAP -L swap $DST"
>
> return 0
>
> ;;
>
> "qcow2")
>
> echo "$QEMU_IMG create -f qcow2 $DST ${SIZE}M"
>
> return 0
>
> ;;
>
> "vmdk_"*)
>
> VMWARE_DISK_TYPE=`echo $FSTYPE|cut -d'_' -f 2`
>
>
>
> echo "$VMWARE_DISK_TYPE" | \
>
> grep '\<thin\>\|\<zeroedthic\>\|\<eagerzeroedthick\>' 2>&1
> /dev/null
>
>
>
> if [ $? -eq 1 ] ; then
>
> VMWARE_DISK_TYPE="thin"
>
> fi
>
>
>
> echo "$VMKFSTOOLS -U $DST/disk.vmdk; \
>
> rm -f $DST/*; \
>
> $VMKFSTOOLS -c ${SIZE}M -d ${VMWARE_DISK_TYPE} $DST
> /disk.vmdk"
>
> return 0
>
> ;;
>
> *)
>
> OPTS=""
>
> ;;
>
> esac
>
>
>
> echo "$MKFS -t $FSTYPE $OPTS $DST"
>
> }
>
>
>
>
>
> Michael Curran | connectsolutions | Lead Network Architect
>
> Phone 614.568.2285 | Mobile 614.403.6320 | www.connectsolutions.com
>
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>
--
Join us at OpenNebulaConf2013 in Berlin from the 24th to the 26th of September 2013!
Javier Fontán Muiños
Developer
OpenNebula - The Open Source Toolkit for Data Center Virtualization www.OpenNebula.org | @OpenNebula | github.com/jfontan
More information about the Users
mailing list