Bienvenidos

Todos estos pasos descriptos fueron probados en ambientes productivos

miércoles, 7 de junio de 2017

Oracle Linux Server 6.7 sobre un LDOM en Ultra Sparc T5


En este Articulo, se detalla un paso a paso , para la creacion de un ldom sobre un T5 , y posteriormente la instalacion de Oracle Linux Server 6.7, partiendo de la base que ya tenemos un PDOM con otros LDOMS creados, si tiene que crear un ldom paso a paso lea Este Articulo

El nombre que voy a usar de aqui en adelante para el zpool,hostname y todo lo relacionado a este ldom con oracle linux es "dorclx01" el nombre es por   d=desarrollo, orc=oracle lx=linux 01=Primer Ldom con linux

Primero creo un ZPOOL para el disco del SO
root@t5-2 # zpool create dorclx01_so c0t60050768018107A79000000000000CF3d0
root@t5-2 # zpool list
NAME          SIZE  ALLOC   FREE  CAP  DEDUP  HEALTH  ALTROOT

dorclx01_so  79.5G   126K  79.5G   0%  1.00x  ONLINE  -
laboratorio   199G  10.7G   188G   5%  1.00x  ONLINE  -
rpool         278G   102G   176G  36%  1.00x  ONLINE  -
root@t5-2 #
Le agrego el valor "none" al mountpoint para que No monte el zfs en el PDOM
root@t5-2 # zfs set mountpoint=none dorclx01_so
Creo un Volumen vol01, dentro del Zpool dorclx01 el cual luego lo usare para pasarselo al ldom y este sera visto como un disco, en el cual instalare el Sistema Operativo
root@t5-2 # zfs create -V 75g dorclx01_so/vol01

Ahora creo el LDOM
root@t5-2 # ldm add-domain dorclx01
root@t5-2 # ldm set-vcpu 8 dorclx01
root@t5-2 # ldm set-mem 8g dorclx01
root@t5-2 # ldm ls
NAME             STATE      FLAGS   CONS    VCPU  MEMORY   UTIL  NORM  UPTIME
primary          active     -n-cv-  UART    8     16G      0.4%  0.4%  274d 1h
net1002         active     -n----  5002    8     8G       1.1%  1.1%  271d 1h
sunlab1          bound      ------  5000    8     8G
dorclx01         inactive   ------          8     8G
root@t5-2 #
Agrego la placa de red y el switch al ldom
root@t5-2 # ldm add-vnet vnet1 vsw4 dorclx01
root@t5-2 # ldm add-vds dorclx01-vds0 primary
Agrego el virtual device ( el volumen que cree unas lineas mas arriba )
root@t5-2 #  ldm add-vdsdev /dev/zvol/dsk/dorclx01_so/vol01 vol01@dorclx01-vds0
Agrego los Virtual disk al ldom
root@t5-2 #  ldm add-vdisk vdisk1 vol01@dorclx01-vds0 dorclx01
Agrego la imagen ISO al primary
root@t5-2 # ldm add-vdsdev /sun/OL-201705232017-R6-U7-sparc-dvd.iso oracle-linux@primary-vds0
Agrego la imagen ISO al ldom
root@t5-2 # ldm add-vdisk oracle-linux oracle-linux@primary-vds0 dorclx01
Agrego el autoboot en False para que quede en OBP cuando bootee
root@t5-2 # ldm add-variable auto-boot?=false dorclx01
Le doy start al LDOM
root@t5-2 # ldm start dorclx01
LDom dorclx01 started
root@t5-2 #
Me conecto a la Consola del nuevo LDOM ,
root@t5-2 # telnet 0 5001
Trying 0.0.0.0...
Connected to 0.
Escape character is '^]'.

Connecting to console "dorclx01" in group "dorclx01" ....
Press ~? for control options ..

{0} ok  boot

A partir de aqui, se muestra la salida de lo que va mostrando en el booteo, la recorto y modifico porque es muy larga y no aporta mucho a este documento"


PROMLIB: Sun IEEE Boot Prom 'OBP 4.38.3 2015/11/11 10:38'
PROMLIB: Root node compatible: sun4v
Initializing cgroup subsys cpuset
Initializing cgroup subsys cpu
Initializing cgroup subsys cpuacct
Linux version 4.1.12-94.3.4.el6uek.sparc64 (mockbuild@sparc-ol6-builder-04.us.oracle.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16.0.6) (GCC) ) #1 SMP Mon May 15 1
3:52:26 PDT 2017
bootconsole [earlyprom0] enabled
ARCH: SUN4V
...........................
Initializing cgroup subsys cpu
Initializing cgroup subsys cpuacct
Linux version 4.1.12-94.3.4.el6uek.sparc64 (mockbuild@sparc-ol6-builder-04.us.oracle.com) (gcc 
.......................
Greetings.
anaconda installer init version 13.21.215 starting
mounting /proc filesystem... done
creating /dev filesystem... done
starting udev...udevd[86]: error setting /sys/class/firmware/timeout: No such file or directory
done
mounting /dev/pts (unix98 pty) filesystem... done
mounting /sys filesystem... done
anaconda installer init version 13.21.215 using a serial console
trying to remount root filesystem read write... done
mounting /tmp as tmpfs... done
running install...
running /sbin/loader
detecting hardware...
waiting for hardware to initialize...
detecting hardware...
waiting for hardware to initialize...
Welcome to Oracle Linux Server for sparc64




Luego, por ultimo, al darle a la opcion Reboot, queda en el OBP ( porque lo configuramos asi en el boot?=false ) 
terminating anaconda...done
sending termination signals...done
sending kill signals...done
disabling swap...
        /dev/dm-1
unmounting filesystems...
        /mnt/runtime done
        disabling /dev/loop0
        /dev/pts done
        /selinux done
        /mnt/sysimage/boot done
        /mnt/sysimage/dev/pts done
        /mnt/sysimage/dev/shm done
        /mnt/sysimage/dev done
        /mnt/sysimage/proc done
        /mnt/sysimage/sys done
        /mnt/sysimage/selinux done
        /mnt/sysimage done
waiting for mdraid sets to become clean...
rebooting system
reboot: Restarting system
NOTICE: Entering OpenBoot.
NOTICE: Fetching Guest MD from HV.
NOTICE: Starting additional cpus.
NOTICE: Initializing LDC services.
NOTICE: Probing PCI devices.
NOTICE: Finished PCI probing.

SPARC T5-2, No Keyboard
Copyright (c) 1998, 2015, Oracle and/or its affiliates. All rights reserved.
OpenBoot 4.38.3, 8.0000 GB memory available, Serial #83429474.
Ethernet address 0:14:4f:f9:8:62, Host ID: 84f90862.



{0} ok
 Para finalizar, le damos boot , y queda bootedo con Oracle linux sobre SPARC 
 ****** Corto la salida, dejo lo que me parece mas  importante para mostrar ****

                          GNU GRUB  version 2.02~beta3

 +----------------------------------------------------------------------------+
 |*Oracle Linux Server GNU/Linux                                |
 | Advanced options for Oracle Linux Server GNU/Linux           
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 |                                                                            |
 +----------------------------------------------------------------------------+

      Use the ^ and v keys to select which entry is highlighted.
      Press enter to boot the selected OS, `e' to edit the commands
      before booting or `c' for a command-line.
   The highlighted entry will be executed automatically in 0s.
  Booting `Oracle Linux Server GNU/Linux'

Loading Linux 4.1.12-94.3.4.el6uek.sparc64 ...
Loading initial ramdisk ...

PROMLIB: Sun IEEE Boot Prom 'OBP 4.38.3 2015/11/11 10:38'
PROMLIB: Root node compatible: sun4v
Initializing cgroup subsys cpuset
Initializing cgroup subsys cpu
Initializing cgroup subsys cpuacct
Linux version 4.1.12-94.3.4.el6uek.sparc64 (mockbuild@sparc-ol6-builder-04.us.oracle.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16.0.6) (GCC) ) #1 SMP Mon May 15 13:52:26 PDT 2017
bootconsole [earlyprom0] enabled
ARCH: SUN4V
Ethernet address: 00:14:4f:f9:08:62
MM: PAGE_OFFSET is 0xfff8000000000000 (max_phys_bits == 47)
MM: VMALLOC [0x0000000100000000 --> 0x0006000000000000]
MM: VMEMMAP [0x0006000000000000 --> 0x000c000000000000]
Kernel: Using 4 locked TLB entries for main kernel image.
Remapping the kernel... done.
OF stdout device is: /virtual-devices@100/console@1
PROM: Built device tree with 46376 bytes of memory.
MDESC: Size is 14704 bytes.
PLATFORM: banner-name [SPARC T5-2]
PLATFORM: name [ORCL,SPARC-T5-2]
PLATFORM: hostid [84f90862]
PLATFORM: serial# [0099f9b8]
PLATFORM: stick-frequency [3b9aca00]
PLATFORM: mac-address [144ff90862]
PLATFORM: watchdog-resolution [1000 ms]
PLATFORM: watchdog-max-timeout [31536000000 ms]
PLATFORM: max-cpus [1024]
Top of RAM: 0x22ffee000, Total RAM: 0x1ffa62000
Memory hole size: 773MB
Allocated 24576 bytes for kernel page tables.
Zone ranges:
  Normal   [mem 0x0000000030400000-0x000000022ffedfff]
Movable zone start for each node
Early memory node ranges
  node   0: [mem 0x0000000030400000-0x000000006fefffff]
  node   0: [mem 0x000000006ff80000-0x000000006ff8bfff]
  node   0: [mem 0x0000000070000000-0x000000022ff3ffff]
  node   0: [mem 0x000000022ffc0000-0x000000022ffcdfff]
  node   0: [mem 0x000000022ffe6000-0x000000022ffedfff]
Initmem setup node 0 [mem 0x0000000030400000-0x000000022ffedfff]
Booting Linux...
CPU CAPS: [flush,stbar,swap,muldiv,v9,blkinit,n2,mul32]
CPU CAPS: [div32,v8plus,popc,vis,vis2,ASIBlkInit,fmaf,vis3]
CPU CAPS: [hpc,ima,pause,cbcond,aes,des,kasumi,camellia]
CPU CAPS: [md5,sha1,sha256,sha512,mpmul,montmul,montsqr,crc32c]
PERCPU: Embedded 10 pages/cpu @fff800021e000000 s38080 r8192 d35648 u131072
SUN4V: Mondo queue sizes [cpu(131072) dev(16384) r(8192) nr(256)]
Built 1 zonelists in Node order, mobility grouping on.  Total pages: 1038645
Policy zone: Normal
Kernel command line: BOOT_IMAGE=/vmlinuz-4.1.12-94.3.4.el6uek.sparc64 root=/dev/mapper/VolGroup-lv_root ro
log_buf_len individual max cpu contribution: 4096 bytes
log_buf_len total cpu_extra contributions: 4190208 bytes
log_buf_len min size: 1048576 bytes
log_buf_len: 8388608 bytes
early log buf free: 1038696(99%)
PID hash table entries: 4096 (order: 2, 32768 bytes)
Sorting __ex_table...
Memory: 8092632K/8382856K available (6226K kernel code, 2345K rwdata, 2856K rodata, 624K init, 2489K bss, 290224K reserved, 0K cma-reserved)
Hierarchical RCU implementation.
        RCU restricting CPUs from NR_CPUS=2048 to nr_cpu_ids=1024.
RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1024
NR_IRQS:2048 nr_irqs:2048 1
SUN4V: Using IRQ API major 3, cookie only virqs enabled
clocksource stick: mask: 0xffffffffffffffff max_cycles: 0x1cd42e4dffb, max_idle_ns: 881590591483 ns
Console: colour dummy device 80x25
bootconsole [earlyprom0] disabled
PROMLIB: Sun IEEE Boot Prom 'OBP 4.38.3 2015/11/11 10:38'
PROMLIB: Root node compatible: sun4v
Linux version 4.1.12-94.3.4.el6uek.sparc64 (mockbuild@sparc-ol6-builder-04.us.oracle.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16.0.6) (GCC) ) #1 SMP Mon May 15 13:52:26 PDT 2017
bootconsole [earlyprom0] enabled
ARCH: SUN4V
Ethernet address: 00:14:4f:f9:08:62
Kernel: Using 4 locked TLB entries for main kernel image.
Remapping the kernel... done.
OF stdout device is: /virtual-devices@100/console@1
PROM: Built device tree with 46376 bytes of memory.
MDESC: Size is 14704 bytes.
PLATFORM: banner-name [SPARC T5-2]
PLATFORM: name [ORCL,SPARC-T5-2]
PLATFORM: hostid [84f99862]
PLATFORM: serial# [099f9b8]
Memory hole size: 773MB
Allocated 24576 bytes for kernel page tables.
Zone ranges:
Early memory node ranges
Booting Linux...
PERCPU: Embedded 10 pages/cpu @fff800021e000000 s38080 r8192 d35648 u131072
SUN4V: Mondo queue sizes [cpu(131072) dev(16384) r(8192) nr(256)]
Built 1 zonelists in Node order, mobility grouping on.  Total pages: 1038645
Policy zone: Normal
Kernel command line: BOOT_IMAGE=/vmlinuz-4.1.12-94.3.4.el6uek.sparc64 root=/dev/mapper/VolGroup-lv_root ro
log_buf_len min size: 1048576 bytes
log_buf_len: 8388608 bytes
early log buf free: 1038696(99%)
PID hash table entries: 4096 (order: 2, 32768 bytes)
Memory: 8092632K/8382856K available (6226K kernel code, 2345K rwdata, 2856K rodata, 624K init, 2489K bss, 290224K reserved, 0K cma-reserved)
Hierarchical RCU implementation.
 SUN4V: Using IRQ API major 3, cookie only virqs enabled
Brought up 8 CPUs
devtmpfs: initialized
Performance events:
Testing NMI watchdog ... OK.
Supported PMU type is 'niagara5'
VIO: Adding device channel-devices (tx_ino = ffffffffffffffff, rx_ino = ffffffffffffffff)
VIO: Adding device vnet-port-0-0 (tx_ino = 0, rx_ino = 1)
VIO: Adding device vnet-port-0-1 (tx_ino = 2, rx_ino = 3)
VIO: Adding device vnet-port-0-2 (tx_ino = 4, rx_ino = 5)
VIO: Adding device vdc-port-0-0 (tx_ino = 6, rx_ino = 7)
VIO: Adding device vdc-port-1-0 (tx_ino = 8, rx_ino = 9)
SCSI subsystem initialized
TCP established hash table entries: 65536 (order: 6, 524288 bytes)
TCP bind hash table entries: 65536 (order: 7, 1048576 bytes)
TCP: Hash tables configured (established 65536 bind 65536)
NET: Registered protocol family 1
Trying to unpack rootfs image as initramfs...
Freeing initrd memory: 29416K (fff8000071000000 - fff8000072cba000)
futex hash table entries: 262144 (order: 11, 16777216 bytes)
console [ttyHV0] enabled
Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
NET: Registered protocol family 17
rtc-sun4v rtc-sun4v: setting system clock to 2017-06-07 18:15:07 UTC (1496859307)
device-mapper: ioctl: 4.31.0-ioctl (2015-3-12) initialised: dm-devel@redhat.com
sunvdc: vdiska: 157286400 sectors (76800 MB) protocol 1.3
 vdiska: vdiska1 vdiska2 vdiska3
sunvdc: Virtual CDROM vdiskb
sunvdc: vdiskb: 1413328 sectors (690 MB) protocol 1.3
 vdiskb: vdiskb1
sunvnet.c:v1.0 (June 25, 2007)
vnet_port vnet-port-0-0 eth0: Sun LDOM vnet 00:14:4f:fb:b9:68
sunvnet: eth0: PORT ( remote-mac 00:14:4f:f8:53:33 switch-port )
sunvnet: eth0: PORT ( remote-mac 00:14:4f:f9:68:7c )
sunvnet: eth0: PORT ( remote-mac 00:14:4f:fa:75:19 )
udev: starting version 147
dracut: Starting plymouth daemon
aes_sparc64: Using sparc64 aes opcodes optimized AES implementation
sha256_sparc64: Using sparc64 sha256 opcode optimized SHA-256/SHA-224 implementation
dracut: Scanning devices vdiska3  for LVM volume groups
random: lvm urandom read with 6 bits of entropy available
dracut: Found volume group "VolGroup" using metadata type lvm2
dracut: 2 logical volume(s) in volume group "VolGroup" now active
EXT4-fs (dm-0): mounted filesystem with ordered data mode. Opts: (null)
dracut: Mounted root filesystem /dev/mapper/VolGroup-lv_root
dracut: Loading SELinux policy
audit: type=1404 audit(1496859308.368:2): enforcing=1 old_enforcing=0 auid=4294967295 ses=4294967295
SELinux:  Permission execmod in class dir not defined in policy.
SELinux:  Permission execmod in class lnk_file not defined in policy.
SELinux:  Permission attach_queue in class tun_socket not defined in policy.
SELinux:  Class binder not defined in policy.
SELinux: the above unknown classes and permissions will be allowed
audit: type=1403 audit(1496859308.740:3): policy loaded auid=4294967295 ses=4294967295
EXT4-fs (dm-0): re-mounted. Opts: (null)
kjournald starting.  Commit interval 5 seconds
EXT3-fs (vdiska1): using internal journal
EXT3-fs (vdiska1): mounted filesystem with ordered data mode
Adding 7864312k swap on /dev/mapper/VolGroup-lv_swap.  Priority:-1 extents:1 across:7864312k FS
NET: Registered protocol family 10
ip6_tables: (C) 2000-2006 Netfilter Core Team
nf_conntrack version 0.5.0 (65536 buckets, 262144 max)
ip_tables: (C) 2000-2006 Netfilter Core Team
audit: type=1305 audit(1496859318.384:4): audit_pid=988 old=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:auditd_t:s0 res=1
vldc.c:v1.0

Oracle Linux Server release 6.7
Kernel 4.1.12-94.3.4.el6uek.sparc64 on a sparc64

localhost.localdomain login:

Para terminar de configurar, lo basico, como ser  el nombre del host, la ip , netmask , consultar el documento Configuracion Basica de Oracle Linux, Post instalación.

*********** LISTO, tenemos instalado un Oracle Linux sobre SPARC T5  ******* 

Luego desde el PDOM, si quiero conectarme hago
root@t5-2 # telnet 0 5001
Trying 0.0.0.0...
Connected to 0.
Escape character is '^]'.

Connecting to console "dorclx01" in group "dorclx01" ....
Press ~? for control options ..

{0} ok


NOTA: Esta instalacion la realizamos con mi colega Nicolas Morono @nicomorono

3 comentarios:

  1. Como siempre, un gusto laburar con un genio cómo vos y además humilde y excelente persona. El artículo, otra maravilla como siempre en este blog.

    ResponderEliminar
  2. Karthi Thanks a lot for your comment, regards from Argentina

    ResponderEliminar
  3. Do you realize there's a 12 word sentence you can speak to your man... that will trigger intense feelings of love and impulsive appeal for you buried inside his chest?

    That's because hidden in these 12 words is a "secret signal" that fuels a man's impulse to love, treasure and protect you with his entire heart...

    =====> 12 Words Who Trigger A Man's Love Instinct

    This impulse is so built-in to a man's mind that it will drive him to try better than ever before to do his best at looking after your relationship.

    In fact, triggering this all-powerful impulse is so important to having the best possible relationship with your man that the moment you send your man one of the "Secret Signals"...

    ...You will soon find him open his heart and soul for you in such a way he haven't experienced before and he will recognize you as the only woman in the universe who has ever truly interested him.

    ResponderEliminar