We continue the game with experimental T2000 - stage, share power

    Today I will continue to describe the tests on the Sun Fire T2000 server, which we already knew from the previous post. You need to try how painlessly the installation of such a fresh Oracle VM (former Ldom) and the launch of Solaris in it will take place. So to speak, the training race before the official work. Yes, a detailed manual is useful to someone.

    Well, let's begin, for starters we need to download this package, this can be done from the official Oracle website (it may require registration), or from here - p12569204_210_SOLARIS64 (1) .zip
    , uploaded for the lazy.
    It is necessary to check whether your hardware meets the criteria of Oracle (firmware, version of Solaris, etc.). For readers, I will cover:

    root @ T2000 # cat / etc / release 
                       Oracle Solaris 10 9/10 s10s_u9wos_14a SPARC
         Copyright (c) 2010, Oracle and / or its affiliates. All rights reserved.
                                Assembled 11 August 2010
    root @ T2000 # prtdiag -v
    ......................
    ============================= FW Version ==================== ========
    Version
    -------------------------------------------------- ----------
    System Firmware 6.7.10 2010/07/14 16:35
    ======================== System PROM revisions =======================
    Version
    -------------------------------------------------- ----------
    OBP 4.30.4.b 2010/07/09 13:48
    ........................................
    

    Well, suppose that everything is in order, we have downloaded the necessary software and are ready to install, naturally we need to prepare the place where the virtual disk of the guest OS will be located. To do this, I allocated a little space on 2 disks combined them into a
    ZFS mirror pool .

    root @ T2000 # zpool list
    NAME SIZE ALLOC FREE CAP HEALTH ALTROOT
    OracleVM 29.8G 9.54G 20.2G 32% ONLINE -
    mainpool 38G 10.8G 27.2G 28% ONLINE -
    root @ T2000 # df -h | grep OracleVM
    OracleVM 29G 9.5G 20G 33% / OracleVM
    

    You see, it has a taken place, it is a previously created image file (which will be our virtual disk), the file was created using the dd command, it looked something like this:

    root@T2000 # dd if=/dev/zero of=/OracleVM/image bs=1024 count=10000000

    Installing Oracle VM is more than simple, after unpacking the downloaded archive, go to the Install folder and we see there is the only script that we run:

    root @ T2000 # ./install-ldm
    root @ T2000 # svcs -a | grep ldmd
    online 16:51:52 svc: / ldoms / ldmd: default
    root @ T2000 # ldm list
    NAME STATE FLAGS CONS VCPU MEMORY UTIL UPTIME
    primary active -nc-- SP 16 8064M 0.1% 49m
    


    The result tells us that everything went well. So you can proceed to the next steps, and here the fun begins. First, we configure the services of our VM, these are three services:
    vcc - virtual console
    vds - virtual disk
    vsw - virtual switch.
    To do this, enter the following commands, in the future we will understand the use of all options and arguments.

    root @ T2000 # ldm add-vcc port-range = 5000-5100 primary-vcc0 primary
    root @ T2000 # ldm add-vds primary-vds0 primary
    root @ T2000 # ldm add-vsw net-dev = e1000g1 primary-vsw0 primary
    root @ T2000 # ldm list-services primary
    Vcc
        NAME LDOM PORT-RANGE
        primary-vcc0 primary 5000-5100
    VSW
        NAME LDOM MAC NET-DEV ID DEVICE LINKPROP DEFAULT-VLAN-ID PVID VID MTU MODE INTER-VNET-LINK
        primary-vsw0 primary 00: 14: 4f: f9: 29: 98 e1000g1 0 switch @ 0 1 1 1500 on         
    Vds
        NAME LDOM VOLUME OPTIONS MPGROUP DEVICE
        primary-vds0 primary         
    

    As a result, we have successfully assigned virtual devices to our primary domain. Now let's move on to allocating physical resources for the guest domain. We know the parameters of our server, but to make sure once again that we have a command, we enter:

    root @ T2000 # prtdiag
    System Configuration: Sun Microsystems sun4v Sun Fire T200
    Memory size: 8064 Megabytes
    ================================= Virtual CPUs ================= =================
    CPU ID Frequency Implementation Status
    ------ --------- ---------------------- -------
    0 1000 MHz SUNW, UltraSPARC-T1 on-line  
    1 1000 MHz SUNW, UltraSPARC-T1 on-line  
    2 1000 MHz SUNW, UltraSPARC-T1 on-line  
    3 1000 MHz SUNW, UltraSPARC-T1 on-line  
    4 1000 MHz SUNW, UltraSPARC-T1 on-line  
    5 1000 MHz SUNW, UltraSPARC-T1 on-line  
    6 1000 MHz SUNW, UltraSPARC-T1 on-line  
    7 1000 MHz SUNW, UltraSPARC-T1 on-line  
    8 1000 MHz SUNW, UltraSPARC-T1 on-line  
    9 1000 MHz SUNW, UltraSPARC-T1 on-line  
    10 1000 MHz SUNW, UltraSPARC-T1 on-line  
    11 1000 MHz SUNW, UltraSPARC-T1 on-line  
    12 1000 MHz SUNW, UltraSPARC-T1 on-line  
    13 1000 MHz SUNW, UltraSPARC-T1 on-line  
    14 1000 MHz SUNW, UltraSPARC-T1 on-line  
    15 1000 MHz SUNW, UltraSPARC-T1 on-line  
    ======================== Physical Memory Configuration ========================
    Segment table:
    -------------------------------------------------- ------------
    Base Segment Interleave Bank Contains
    Address Size Factor Size Modules
    -------------------------------------------------- ------------
    0x0 8 GB 4 2 GB MB / CMP0 / CH0 / R0 / D0
                                                 MB / CMP0 / CH0 / R0 / D1
                                        2 GB MB / CMP0 / CH1 / R0 / D0
                                                 MB / CMP0 / CH1 / R0 / D1
                                        2 GB MB / CMP0 / CH2 / R0 / D0
                                                 MB / CMP0 / CH2 / R0 / D1
                                        2 GB MB / CMP0 / CH3 / R0 / D0
                                                 MB / CMP0 / CH3 / R0 / D1
    

    This is sufficient information so that we can configure the primary system based on the guest. Next will follow the commands that I will describe a little lower. After entering these commands, we received a new boot configuration for our server. Next, we need to reboot in order to continue our setup. In the boot process, we already see that the RAM, as we ordered 6GB. Then we finish our network:

    root@T2000 # ldm set-vcpu 8 primary
    Crypto unit 2 was removed from domain primary



    root@T2000 # ldm start-reconf primary
    Initiating a delayed reconfiguration operation on the primary domain.
    All configuration changes for other domains are disabled until the primary
    domain reboots, at which time the new configuration for the primary domain
    will also take effect.
    root@T2000 # ldm set-memory 4G primary
    root@T2000 # ldm add-config initial
    root@T2000 # ldm list-config
    factory-default
    initial [current]




    root@T2000 # shutdown -y -g0 -i6



    root @ T2000 # ifconfig -a
    lo0: flags = 2001000849 mtu 8232 index 1
            inet 127.0.0.1 netmask ff000000 
    e1000g0: flags = 1000843 mtu 1500 index 2
            inet 192.168.0.241 netmask ffffff00 broadcast 192.168.0.255
            ether 0: 14: 4f: ae: 88: 14 
    root @ T2000 # ifconfig vsw0 plumb
    root @ T2000 # dladm show-link
    vsw0 type: non-vlan mtu: 1500 device: vsw0
    e1000g0 type: non-vlan mtu: 1500 device: e1000g0
    e1000g1 type: non-vlan mtu: 1500 device: e1000g1
    e1000g2 type: non-vlan mtu: 1500 device: e1000g2
    e1000g3 type: non-vlan mtu: 1500 device: e1000g3
    root @ T2000 # ifconfig vsw0 dhcp start
    root @ T2000 # ifconfig -a
    lo0: flags = 2001000849 mtu 8232 index 1
            inet 127.0.0.1 netmask ff000000 
    e1000g0: flags = 1000843 mtu 1500 index 2
            inet 192.168.0.241 netmask ffffff00 broadcast 192.168.0.255
            ether 0: 14: 4f: ae: 88: 14 
    vsw0: flags = 1004843 mtu 1500 index 3
            inet 192.168.0.233 netmask ffffff00 broadcast 192.168.0.255
            ether 0: 14: 4f: f9: 29: 98 
    

    The output shows how we connected the virtual network and told her to get ip via dhcp.
    Let's check the virtual terminal services: After making sure that everything works, go to the hardware configuration for the guest OS, the operations are similar to configuring the primary system. In these few lines the entire configuration of our guest domain is hidden, explain them one by one: 1 - add the domain and name it 2 - add processors to a domain 3 - add RAM 4 - adding a virtual network created before and call it vnet1 5 - associate previously created image as a device 6 - adding a device as a virtual d ck 7.8 - say the guest system is loaded with it.

    root@T2000 # svcs -a | grep vntsd
    online 17:20:25 svc:/ldoms/vntsd:default




    root@T2000 # ldm add-domain VMtest
    root@T2000 # ldm add-vcpu 4 VMtest
    root@T2000 # ldm add-memory 2G VMtest
    root@T2000 # ldm add-vnet vnet1 primary-vsw0 VMtest
    root@T2000 # ldm add-vdsdev /OracleVM/image vol1@primary-vds0
    root@T2000 # ldm add-vdisk vdisk1 vol@primary-vds0 VMtest
    root@T2000 # ldm set-var auto-boot\?=true VMtest
    root@T2000 # ldm set-var boot-device=vdisk1 VMtest










    Next, we fix everything that happened by binding devices to the domain. And check it all out.

    root @ T2000 # ldm bind-domain VMtest
    root @ T2000 # ldm list-domain VMtest
    NAME STATE FLAGS CONS VCPU MEMORY UTIL UPTIME
    VMtest bound ------ 5000 8 2G             
    root @ T2000 # ldm list-bindings VMtest
    NAME STATE FLAGS CONS VCPU MEMORY UTIL UPTIME
    VMtest bound ------ 5000 8 2G             
    Uuid
        7b0130b5-f955-c92e-ca1e-e83aeb583e35
    MAC
        00: 14: 4f: f8: 4b: 59
    Hostid
        0x84f84b59
    CONTROL
        failure-policy = ignore
        extended-mapin-space = off
    DEPENDENCY
        master = 
    CORE
        CID CPUSET
        1 (10, 11)
        2 (12, 13, 14, 15)
        3 (18, 19)
    Vcpu
        VID PID CID UTIL STRAND
        0 10 1 100%
        1 11 1 100%
        2 12 2 100%
        3 13 2 100%
        4 14 2 100%
        5 15 2 100%
        6 18 3 100%
        7 19 3 100%
    Memory
        RA PA SIZE            
        0x8000000 0x108000000 2G
    Variables
        auto-boot? = true
        boot-device = vdisk1
    NETWORK
        NAME SERVICE ID DEVICE MAC MODE PVID VID MTU LINKPROP  
        vnet1 primary-vsw0 @ primary 0 network @ 0 00: 14: 4f: fb: b5: bb 1 1500            
            PEER MAC MODE PVID VID MTU LINKPROP  
            primary-vsw0 @ primary 00: 14: 4f: f9: 29: 98 1 1500 
    DISK
        NAME VOLUME TOUT ID DEVICE SERVER MPGROUP       
        vdisk1 vol1 @ primary-vds0 0 disk @ 0 primary                      
    Vcons
        NAME SERVICE PORT
        VMtest primary-vcc0 @ primary 5000  
    

    Now it’s the turn of installing Solaris directly onto the hardware, for this I will use a live DVD drive, but it also supports installation from an ISO image.
    In order for our guest hardware to intercept the DVD drive, you must initially disable the service controlling this in the primary domain. In these commands, we indicate to the guest OS that it will now use a live DVD as its own, and we do this with the q key because sometimes without it. Next, bind the iron to the guest domain again, but also using the q option and start. Then we just need to connect via telnet to the port designated in advance and continue the installation.

    root@T2000 # svcadm disable volfs
    root@T2000 # ldm unbind VMtest
    root@T2000 # ldm add-vdsdev /dev/dsk/c1t0d0s2 dvd_vol@primary-vds0
    Path /dev/dsk/c1t0d0s2 is not valid on service domain primary
    root@T2000 # ldm add-vdsdev -q /dev/dsk/c1t0d0s2 dvd_vol@primary-vds0
    root@T2000 # ldm add-vdisk vdisk_dvd_media dvd_vol@primary-vds0 VMtest




    root@T2000 # ldm bind -q VMtest
    root@T2000 # ldm start VMtest
    LDom VMtest started




    root @ T2000 # telnet localhost 5000
    Trying 127.0.0.1 ...
    Connected to localhost.
    Escape character is '^]'.
    Connecting to console "VMtest" in group "VMtest" ....
    Press ~? for control options ..
    {0} ok 
    {0} ok devalias
    vdisk_dvd_media / virtual-devices @ 100 / channel-devices @ 200 / disk @ 1
    vdisk1 / virtual-devices @ 100 / channel-devices @ 200 / disk @ 0
    vnet1 / virtual-devices @ 100 / channel-devices @ 200 / network @ 0
    net / virtual-devices @ 100 / channel-devices @ 200 / network @ 0
    disk / virtual-devices @ 100 / channel-devices @ 200 / disk @ 0
    virtual-console / virtual-devices / console @ 1
    name aliases
    {0} ok boot vdisk_dvd_media: f
    Boot device: / virtual-devices @ 100 / channel-devices @ 200 / disk @ 1: f File and args: 
    SunOS Release 5.10 Version Generic_120011-14 64-bit
    Copyright 1983-2007 Sun Microsystems, Inc. All rights reserved.
    Use is subject to license terms.


    And then, if everything goes well, we will get another OS on our piece of hardware.
    Thank you all for your attention.

    Also popular now: