~~~~~~~~~~~~~~Installation~~~~~~~~~~~~~~~
Download latest binary from Oracle website & upgrade the system firmware.http://www.oracle.com/technetwork/server-storage/vm/downloads/index.html
Note: On Oracle Solaris 10 you need to manually install Ldom packages. In Solaris 11 its part of default installation. LDom is supported in Oracle's SPARC T-Series Servers only.
unzip LDom_3.0.zip
./Install/install-ldm
You can choose no to ldom configuration assistant if you want to manually configure. Below is just a quick reference of commands to configure ldom(Its recommend you go through the Oracle VM for SPARC (Ldom) administration guide for any details).
~~~~~~~~~~~Control Domain Initial Configuration~~~~~~~~~~
1. After installation ldmd service will be enabled by defaultsvcs svc:/ldoms/ldmd:default
To enable :
svcadm enable svc:/ldoms/ldmd:default
2. Adding virtual disk service
ldm add-vds primary-vds0 primary
3. Adding console service
ldm add-vcc port-range=5000-5100 primary-vcc0 primary
4. Adding Virtual network switch
ldm add-vsw net-dev=e1000g0 primary-vsw0 primary
5.
ldm list-services primary
6. Starting delayed configuration, requires reboot
ldm start-reconf primary
7. Setting 2 cores of CPU & 8GB Memory for control domain
ldm set-vcpu -c 2 primary
ldm set-memory 8G primary
ldm add-config initial
ldm list-config
8. IO domain configuration.
Latest LDom supports PCIE bus/Leaf level devices can be directly allocated to guest domains (Ref Admin Guide for any details)
a. List the devices/Bus which can be added to guest domains.
ldm list-io
--Remove IO device you want to allocate to guest domain
b. ldm remove-io <Bus/device> primary
ldm add-io <Bus/device> primary
Note: If you remove a Bus, internal disks and onboard network ports associated to that PCI controller/bus will be removed and once you add that bus to guest ldom it will appear in the guest ldom. If you are creating a IO domain no need of virtualising the disks and network (in step 2 & 4).
shutdown -y -g0 -i6
~~~~~~~~~~~~~~~~Configuring Guest LDom~~~~~~~~~~~~~~~~~~
1. Create a logical domain.ldm add-domain ldom1
2. Add CPUs to the guest domain.
ldm set-vcpu -c 4 ldom1
3. Add memory to the guest domain.
ldm set-memory 8G ldom1
4. Add IO device/bus directly to guest domain.
You can add io which is removed from primary in step 8 above. so that on-board disk & network which are associated with that bus or leaf level devices will be directly available on the guest LDom. You may not need to virtualise as is below step 5 & 6.
ldm list-io
ldm add-io <bus/device> ldom1
5. Add a virtual network device to the guest domain.
ldm add-vnet vnet1 primary-vsw0 ldom1
6, Add virtual disk to LDom (with any of the below three option)
a. Adding physical disk
ldm add-vdsdev /dev/dsk/c0t0d0s2 vol1@primary-vds0
ldm add-vdisk vdisk0 vol1@primary-vds0 ldom1
.b Create (mkfile)and add as another disk (install_disk) on which to install the Solaris OS.
primary# mkfile 30g /LDomFS/Ldisk1
primary# ldm add-vdsdev /LDomFS/Ldisk1 install_vol@primary-vds0
primary# ldm add-vdisk vdisk_install install_vol@primary-vds0 ldom1
.c Create disk with zfs create -v and add as disk (install_disk) on which to install the Solaris OS.
(If you are using zfs file system you can also create disk as below and use zfs snapshot/clone feature if you want to replicate LDoms later)
primary# zfs create -V 30g rpool/Ldisk1
primary# ldm add-vdsdev /rpool/Ldisk1 install_vol@primary-vds0
primary# ldm add-vdisk vdisk_install install_vol@primary-vds0 ldom1
7,
a. Adding OS ISO Image and Installing
ldm add-vdsdev /solaris/sol-10-u10-ga2-sparc.iso iso_vol@primary-vds0
ldm add-vdisk vdisk_iso iso_vol@primary-vds0 ldom1
b. Installing from Physical DVD drive.
svcadm disable volfs
ldm add-vdsdev /dev/dsk/c0t0d0s2 dvd_vol@primary-vds0
ldm add-vdisk vdisk_cd_media dvd_vol@primary-vds0 ldom1
8. set auto-boot variable false to go to 'ok' prompt
ldm set-variable auto-boot\?=false ldom1
or
ldm set-variable auto-boot\?=true ldom1
ldm set-var boot-device=vdisk ldom1
9. Enable console service
svcadm enable vntsd
svcs -l vntsd
Finally:
ldm bind ldom1
ldm list-domain
ldm start ldom1 or ldm stop ldom1
10. Save the config
ldm add-config complete
~~~~~~Installing OS~~~~~
ldm listtelnet localhost 5000
{0} ok show-disks
{0} ok devalias
{0} ok boot vdisk_iso
Proceed with regular installation.
Ctr ]
>q -> to come out from telnet session