Friday, March 17, 2017

LDOM Interview Questions and Answers


Please Refer LDOM Quick Reference Guide 
 
 
1. How to check the Version of Logical Domain Manager and Hypervisor ?
# ldm -V     Display version information of LDM and Hypervisor
 
2. Brief about Primary/Control Domain ?
 
It Controls the Oracle VM and also called as Primary domain.
  • Used to configure server resources and guest domains and Provides virtual console services.
  • Logical domain Manager installed only on Control domain.
  • Control domain normally act as Service domain.
  • For more reference "How to Configure Primary or Control Domain." 


  • 3. Brief about Service Domain?
    Service domain Provides virtual device services to Guest Domain.
  • It provides Virtual Disk Services.
  • It provides Virtual Console Services.
  • It provides Virtual network Switches.
  • For more reference "How to Configure Service Domain"

  • 4. Brief about Guest/Logical Domain?
     Guest domain uses only virtual services.
    • Guest domain where our OS is installed.
    • Get the services from service domain in order to run application and user services.
    • Guest domain can be a I/O Domain.
    • For more reference "How to Configure Logical/Guest Domain"

    5. Brief about I/O domain ?
    • I/O Domain where we are getting phyiscal I/O device access directly.
    • I/O device which connects PCI bus, such as local network interface, disk drives and PCI adapters.
    • For more reference "How to Configure I/O Domain"
    6. How to check the list of services ?

    List the Virtual services currently configure in the Control Domain
    Syntax : # ldm list-services  [-e] [-p] [...]
    # ldm list-services primary

    7. How to backup the LDOM configuration and how to restore?

    Syntax : # ldm list-constraints ([-x] | [-e] [-p]) [...]
    # ldm list-constraints -p
    VERSION 1.5
    DOMAIN|name=primary
    UUID|uuid=f44b4e9e-330c-4a20-c22e-a18c1c6f61b1
    MAC|mac-addr=00:14:4f:82:5c:ee
    CONTROL|failure-policy=ignore
    CORE|count=2
    VCPU|count=8
    MAU|count=1
    MEMORY|size=2147483648
    VARIABLES
    |keyboard-layout=US-English
    IO
    |dev=pci@780|alias=
    |dev=pci@7c0|alias=
    VCC|name=primary-vcc0|port-range=5000-5100
    VSW|name=primary-vsw0|mac-addr=|net-dev=e1000g0|dev=switch@0|default-vlan-id=1|pvid=1|vid=|mode=|mtu=|linkprop=|id=0
    VDS|name=primary-vds0
    [root@unixrock /]#
    [root@unixrock /]# ldm list-constraints -x primary > /unixrock.xml
    [root@unixrock /]# file /unixrock.xml
    primary.xml:    XML document
    [root@unixrock /]# ls -l /unixrock.xml
    -rw-r--r--   1 root     root        3988 Feb 17 14:26 unixrock.xml
    [root@unixrock /]#

    To restore the configuration NOTE: System configuration should be Factory-default setting

    [root@unixrock /]# ldm list-spconfig
    factory-default (current)
    [root@unixrock /]# ldm init-system -i /unixrock.xml
    [root@unixrock /]# ldm add-spconfig unixrock_config
    [root@unixrock /]# ldm list-spconfig
    factory-default
    unixrock_config (current)
    [root@unixrock /]#

    8. How to check the list of available devices ?

    Syntax : # ldm list-devices [-a] [-p] [core] [cpu] [crypto|mau] [memory] [io] 
    Example : # ldm list-devices -a               To list all the host server resources details
    Example : # ldm list-devices -a cpu         To list all the host server CPU resources 
    Example : # ldm list-devices -a memory To list all the host server MEMORY resources 
    Example : # ldm list-devices -a io            To list all the host server I/O resources
    9. How to add and remove the LDOM ?

    Syntax :  # ldm  list-domain [-e] [-l] [-o ] [-p] [...]
    Syntax :  # ldm add-domain (-i |[mac-addr=] [hostid=][failure-policy=][master=] ...)
    Syntax :  # ldm remove-domain (-a | ...)

    [root@unixrock /]# ldm list-domain
    NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
    primary          active     -n-cv-  SP      8     8G       0.4%  4h 7m
    [root@unixrock /]#
    [root@unixrock /]# ldm add-domain rockldom1
    [root@unixrock /]# ldm list-domain
    [root@unixrock /]#
    NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  UPTIME
    primary          active     -n-cv-  SP      8     8G       0.4%  4h 7m
    rockldom1       inactive    ------ 
    [root@unixrock /]#
    [root@unixrock /]# ldm remove-domain rockldom1
    [root@unixrock /]#


    10. How to start and stop the LDOM ?

    Syntax :- ldm start-domain (-a | -i | ...) 
    Syntax :- ldm stop-domain [-f] (-a | ...)
    [root@unixrock /]# ldm start-domain rockldom1
    LDom rockldom1 started
    [root@unixrock /]# ldm stop-domain rockldom1
    LDom rockldom1 stopped
    [root@unixrock /]# 

    11. How to migrate the LDOM to another Host?

    NOTE: Source and Target service configuration should be same.
    Syntax :- # ldm migrate-domain [-f] [-n] [-p ] [@][:]
    [root@unixrock /]# ldm migrate-domain ldom1 root@192.168.10.25 
    Target Password:

    12. How to add/set the Memory resources to the LDOM ?

    To add the memory to the guest domain
    Syntax : # ldm add-memory [--auto-adj] [GMK]
               Example : # ldm add-memory 2G ldom1 
    To reconfigure the memory to the guest or primary domain
    Syntax : # ldm set-memory [--auto-adj] [GMK]
               Example : # ldm set-memory 5G primary 
               Example : # ldm set-memory 2G ldom1 
    To decrease the amount of memory in a domain
    Syntax : # ldm remove-memory [--auto-adj] [GMK]
                Example : # ldm remove-memory 1G primary 
                Example : # ldm remove-memory 1024M ldom1

    13. How to dump the configuration to the SP ?
    Syntax : # ldm list-spconfig [-r []]

                 Example : # ldm list-spconfig 
    Syntax : # ldm add-spconfig [-r ]
                 Example : # ldm add-spconfig config_initial 
    Syntax : # ldm remove-spconfig [-r]
                 Example : # ldm remove-spconfig config_initial 

    [root@unixrock /]# ldm list-spconfig
    factory-default
    tempprofile [current]
    [root@unixrock /]# ldm remove-spconfig tempprofile
    [root@unixrock /]# ldm list-spconfig
    factory-default [next poweron]
    [root@unixrock /]# ldm add-spconfig config_intial
    [root@unixrock /]# ldm list-spconfig
    factory-default
    config_intial [current]
    [root@unixrock /]#
    [root@unixrock /]# 


    14. How to set the LDOM variables ?

    To list the Variable settings of guest domain
    Syntax : # ldm list-variable [...]
           Example : # ldm list-variable auto-boot\? Ldom1
           Example : # ldm list-variable boot-device Ldom1
    To add the new variable setting to the guest domain
    Syntax : # ldm add-variable =...
           Example : # ldm add-variable boot-device Ldom1
    To set the "auto-boot" variable as false, this will leave the server at in OK prompt 
    Syntax : # ldm  set-variable =...
           Example : # ldm set-variable auto-boot\?=false Ldom1

    15. How to add the VCC on primary domain ?

    To add the Virtual console concentrator service to the control domain
    Syntax : # ldm add-vconscon port-range=-
          Example : # ldm add-vconscon port-range=5000-5100 primary-vcc0 primary
    To set or modify the Virtual console concentrator service to the control domain
    Syntax : # ldm set-vconscon port-range=-
          Example : # ldm set-vconscon port-range=5000-5100 primary-vcc0
    To remove the Virtual console service from domain
    Syntax : # ldm remove-vconscon [-f]
          Example : # ldm remove-vconscon primary-vcc0


    16. How to add/set/remove the virtual CPU to the domain?

    To add CPU to the guest domain
    Syntax : # ldm add-vcpu [-c|--core]
         Example : # ldm add-vpcu 8 ldom1
    To reconfigure the virtual CPU for any domain 
    Syntax : # ldm set-vcpu [-c|--core]
         Example : # ldm set-vpcu 10 primary
    To decrease the number of virtual CPU for any domain 
    Syntax : # ldm remove-vcpu [-f|--force] [-c|--core]
         Example : # ldm remove-vpcu 2 ldom1

    17. How to add/remove the Virtual disk to the domain?


    To assign the Virual disk to the guest domain
    Syntax :# ldm add-vdisk [timeout=] [id=]    @
          Example : # ldm add-vdisk vdisk0 vol0@primary-vds0 ldom1
          Example : # ldm add-vdisk iso01 iso01@primary-vds0 ldom1
    To remove the  Virual disk  on the guest domain
    Syntax :# ldm remove-vdisk [-f]
          Example : # ldm remove-vdisk vdisk0 ldom1

    18. How to add/remove the ISO image to the domain?
    To add or associating the iso resources to the Control domain's virtual disk services 
     

    [root@unixrock /]# ldm add-vdsdev options=ro /export/home/solaris.iso iso01@primary-vds0
    [root@unixrock /]#
    To remove Virtual disk server devices
    [root@unixrock /]# ldm remove-vdsdev iso01@primary-vds0
    [root@unixrock /]#

    19. How to add the vds services to the domain?

    To add the Virtual disk Server services
    Syntax : # ldm add-vdiskserver
           Example : # ldm add-vdiskserver primary-vds0 primary
           Example : # ldm add-vds primary-vds0 primary
    To remove the Virtual disk Server services
    Syntax : # ldm remove-vdiskserver [-f]
           Example : # ldm remove-vds primary-vds0

    20. How to add/remove Virtual Network services LDOM ?

    To add virtual network device which is associated with the virtual switch  to the guest domain
    Syntax : # ldm add-vnet [mac-addr=] [mode=hybrid] [pvid=] [vid=] [mtu=] [linkprop=phys-state][id=]
           Example : # ldm  add-vnet vnet0 primary-vsw0 ldom1
    To remove the Virtual network device
    Syntax : # ldm remove-vnet [-f]
           Example : # ldm  remove-vnet vnet0  ldom1
     
    21. How to add/remove Virtual Switch on the domain ?

    To add the virtual switch services 
    Syntax : # ldm  add-vswitch [default-vlan-id=] [pvid=] [vid=][mac-addr=] [net-dev=] [linkprop=phys-state][mode=] [mtu=] [id=]
           Example : # ldm add-vswitch net-dev=e1000g0 primary-vsw0 primary
    To remove the virtual switch services
    Syntax : # ldm remove-vswitch [-f]
           Example : # ldm remove-vswitch primary-vsw0 

    22. How to add/remove Virtual disk server device (vdsdev) ?

    To add or associating the resources to the Control domain's virtual disk services
    Syntax : # ldm add-vdiskserverdevice [-f] [options={ro,slice,excl}] [mpgroup=] @
          Example : # ldm add-vdsdev /dev/dsk/c0t1d0s2 vol01@primary-vds0
          Example : # ldm add-vdsdev options=ro /export/home/solaris.iso iso01@primary-vds0
    To remove Virtual disk server devices
    Syntax : # ldm  remove-vdiskserverdevice [-f] @
          Example : # ldm remove-vdsdev vol01@primary-vds0
          Example : # ldm remove-vdsdev iso01@primary-vds0

    Thanks for reading this post.....Please leave your valuable comments or queries, will get back to you at earliest 
     
     

    No comments: