You are on page 1of 7

LDOM LDOM Name

Primary control LDOM primary


Second I/O Domain secondary
Guest LDOM node1

Initial Configuration of the Control Domain


Initially, all system resources are allocated to the control domain. To allow the creation of other logical
domains, you must release some of these resources.

How to build Primary Domain


Determine whether you have cryptographic devices in the control domain.

primary# ldm list -o crypto primary


Assign cryptographic resources to the control domain, if applicable.

The following example would assign one cryptographic resource to the control domain, primary. This leaves the
remainder of the cryptographic resources available to a guest domain.

primary# ldm set-mau 1 primary

Assign virtual CPUs to the control domain.

primary# ldm set-vcpu 8 primary

Initiate a delayed reconfiguration on the control domain.

primary# ldm start-reconf primary

Assign memory to the control domain.


For example, the following command would assign 4 gigabytes of memory to the control domain, primary.
This leaves the remainder of the memory available to a guest domain.

primary# ldm set-memory 4G primary

Add a logical domain machine configuration to the service processor (SP).


For example, the following command would add a configuration called initial.
primary# ldm add-config initial

Verify that the configuration is ready to be used at the next reboot.

primary# ldm list-config


factory-default
initial [next poweron]

Shut down and reboot the control domain.

primary# shutdown -y -g0 -i6

# ldm add-vds pri-root-vds primary


# ldm add-vcc port-range=5000-5100 primary-vcc0 primary
# ldm add-vsw net-dev=net0 pri-public-vsw primary -- LDOM Public Network
# ldm add-vsw net-dev=net3 pri-backup-vsw primary -- LDOM Backup Network

# ldm list
NAME STATE FLAGS CONS VCPU MEMORY UTIL NORM UPTIME
primary active -n-cv- UART 16 32GB 20% 20% 2d 23h 21m

How to build secondary IO domain

# ldm list-io -- Check the IO devices

Note: Our system have two PIC card one is pci_0 and one is pci_1. pci_0 we will use for control domain
and pci_1 we will use for Secondary domain.

# ldm add-domain secondary


# ldm add-vcpu 8 secondary
# ldm add-memory 16G secondary
# ldm start-reconf primary

Install and configure your root filesystem for your primary domain on the controllers based on PCI_0.
This leaves you PCI_1 to map to the second or secondary IO domain

# ldm remove-io pci_1 primary


# ldm add-config secondary
We have now carved out the hardware that we needed for the secondary LDOM. We rab tge add-config
secondary which creates the framework of the new IO domain called secondary. So we need to reboot
to make changes take effect.

# shutdown -i6 -g0 -y

Now that we have a freshly booted IO domain named secondary, we can add the disk service and the
network switch device and service

# ldm stop-domain secondary

We We now add the PCI_1 bus to the secondary domain, which is the new additional IO domain.

# ldm add-io pci_1 secondary

We now add the boot ISO image so we can boot and install the LDOM we created, again its called
secondary.
# ldm add-vdsdev /root/sol-10-u10-ga2-sparc-dvd.iso iso@primary-vds0
# ldm add-vdisk vdisk_iso iso@pri-root-vds secondary
# ldm add-spconfig secondary-new1

Lets see what our hardware buses look like now. The PCI_0 and PCI_1 buses should be splint in half.
Here is a long and brief listing of the io subsystem of the T4-4 system.

# ldm list-io -l
# ldm bind-domain secondary
# ldm start-domain secondary

Install secondary IO domain operating system


# telnet localhost 5000
{0} ok boot vdisk_iso:f
Boot device: /virtual-devices@100/channel-devices@200/disk@0:f File and args:
SunOS Release
Because we are using a split or 2 IO domains, we need two virtual disk services. Create vdisk service
(vds0) now.

# ldm add-vds sec-root-vds secondary

From the control domain, you need to create the second virtual switch for the secondary or second IO
domain first NIC net0 which was carved off and mapped to the PCI_1 bus. That was the NIC we moved
over to the IO domain when we split the PCI buses. From the control and service domain (primary), we
have to create secondary vsw that uses the first logical NIC from the secondary (second IO domain).
Here we create a new switch.

# ldm add-vsw net-dev=net0 sec-public-vsw secondary


# ldm add-vsw net-dev=net3 sec-backup-vsw secondary

Creating guest domain ldom using both service and io domains for storage and network services

# ldm add-domain ldg1


# ldm add-vcpu 8 ldg1
# ldm add-memory 8G ldg1
# ldm set-variable auto-boot\?=false ldg1
# ldm add-vdisk vdisk_iso iso@primary-vds0 ldg1
----------------------------------------

How to Configure Virtual Disk Multipathing

Export the virtual disk back end from the primary service domain.

ldm add-vdsdev mpgroup=node1-root-mg /dev/rdsk/emcpower105c node1-root@pri-root-vds


Export the same virtual disk back end from the secondary service domain.

ldm add-vdsdev mpgroup=node1-root-mg /dev/rdsk/emcpower105c node1-root@sec-root-vds

Note - two different domains (primary and secondary) using the same virtual disk (emcpower105c) back end.

Export the virtual disk to the guest domain.

ldm add-vdisk root node1-root@pri-root-vds node1

Note - Although the virtual disk back end is exported several times through different service domains, you assign only
one virtual disk to the guest domain and associate it with the virtual disk back end through any of the service domains.

Result of Virtual Disk Multipathing


After you configure the virtual disk with multipathing and start the guest domain, the virtual disk accesses its back end through
the service domain it has been associated with (the primary domain in this example). If this service domain becomes
unavailable, the virtual disk attempts to access its back end through another service domain that is part of the same
multipathing group.

Remove a Virtual Disk

Remove a virtual disk from a guest domain by using the following command.
# ldm rm-vdisk disk_name ldom

Stop exporting the corresponding backend from the service domain by using the following command.
# ldm rm-vdsdev volume_name@service_name
Assign the network service from the switches being hosted from both domains

Each Virtual Network Device Connected to Different Service Domains

Public Network
# ldm add-vnet linkprop=phys-state net0 pri-public-vsw node1
# ldm add-vnet linkprop=phys-state net1 sec-public-vsw node1

Backup Network
# ldm add-vnet linkprop=phys-state net2 pri-backup-vsw node1
# ldm add-vnet linkprop=phys-state net3 sec-backup-vsw node1

Note - The virtual switch must have a physical network device assigned for the domain to successfully
bind. If the domain is already bound and the virtual switch does not have a physical network device
assigned, the ldm add-vnet commands will fail.

# ldm bind node1


# ldm start node1

# ldm list
NAME STATE FLAGS CONS VCPU MEMORY UTIL NORM UPTIME
primary active -n-cv- UART 16 32G 20% 20% 2d 23h 21m
secondary active -n--v- 5000 8 16G 0.0% 0.0% 3d 19h 29m
node1 active -t---- 5001 8 8G 2.7% 2.7% 1s

# telnet localhost 5001

{0} ok boot vdisk_iso:f

Boot device: /virtual-devices@100/channel- devices@200/disk@0:f File and args:

SunOS Release 5.10 Version Generic_147440-01 64-bit


Using Link-Based IPMP in Logical Domains Virtual Networking
Note that net0 and net1 are the vanity names for vnet0 and vnet1, respectively.

# ipadm create-ip net0


# ipadm create-ip net1
# ipadm create-ipmp ipmp0
# ipadm add-ipmp -i net0 -i net1 ipmp0
# ipadm create-addr -T static -a 192.168.1.1/24 ipmp0/v4addr1
# ipadm create-addr -T static -a 192.168.1.2/24 ipmp0/v4addr2

You might also like