Documente Academic
Documente Profesional
Documente Cultură
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-2
Compute: Bare Metal & Virtual Machines
Hypervisor
VM compute instances runs on the same hardware as a Bare Metal instances, leveraging the
same cloud-optimized hardware, firmware, software stack, and networking infrastructure
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-3
Console Connections
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-4
Instance Console Connections
The Oracle Cloud Infrastructure Compute service provides console connections that enable
you to remotely troubleshoot malfunctioning instances, such as:
• An imported or customized image that does not complete a successful boot.
• A previously working instance that stops responding.
• Add or reset the SSH keys for the opc user
• Edit system configuration files
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-6
Creating the instance Console Connection
• Specify the public key portion for the SSH key and then click Create Console
Connection
NOTE: This SSH key can be different than the one used to launch your instance
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-7
Creating the instance Console Connection
• Once the console connection has been created and is available, the status changes to
ACTIVE.
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-8
Connecting to the Serial Console
• Once you have created the console connection for the instance, you can then connect to the
serial console by using a Secure Shell (SSH) connection.
• Once you are finished with the serial console and have terminated the SSH connection, you
should delete the serial console connection.
• If you do not disconnect from the session, Oracle Cloud Infrastructure will terminate the serial
console session after 24 hours and you will need to re-authenticate to connect again.
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4-9
Connecting from Mac OS X and Linux Operating Systems
You connect to the serial console by using an SSH client. Mac OS X and most Linux
distributions by default include the SSH client OpenSSH.
• In the Console, on the Instances Details page, in the Resources section, click Console
Connections.
• Click the Actions icon, and then click Connect with SSH.
• Select LINUX/MAC OS for PLATFORM.
7. Reboot the instance from the terminal window by entering the keyboard shortcut CTRL+x
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. 4 - 13
Troubleshooting Instances from Instance Console Connections
5. In edit mode, use the down arrow key to scroll down through the entries until you reach the
line that starts with either linuxefi for instances running Oracle Linux 7.x, or kernel for
instances running Oracle Linux 6.x.
6. At the end of that line, add the following: init=/bin/bash
7. Reboot the instance from the terminal window by entering the keyboard shortcut Ctrl+x
• Oracle X5 and X7 servers have different host hardware. As a result, using an X5 image on an X7 bare
metal or virtual machine (VM) instance may not work without additional modifications.
• If you do attempt to use an existing X5 image on X7 hardware, note that Ubuntu 14.04 and all Windows
and CentOS versions are not cross-compatible.
• Oracle Linux and Ubuntu 16.04 are cross-compatible, however you need to update the kernel to the
most recent version to install the latest device drivers. To do so, run the following commands from a
terminal session:
• Click Instances, if necessary, and find the instance you want to use as the basis for an image.
• Click the Actions icon, and then click Create Custom Image
• Enter a name for the image, and then click Create Custom Image
• Click Custom Images and find the custom image you want to use
1. Emulated Mode:
Fully emulated NIC, block boot, legacy BIOS boot.
•Pro’s: compatibility with wide range of older/custom OS
•Con’s: Low Performance – 20% less compared with Native mode
2. Native Mode:
Current OCI VM experience offering maximum performance with modern OS’s.
•Pro’s: Available for Oracle provided smaller set of modern OS’s only
•Con’s: Near Bare-metal Performance
You can import a wide range of new and legacy production operating systems, using the
QCOW2 or VMDK formats, and then run them on Compute VMs using emulated hardware.
The following table lists the operating systems that are supported for emulation mode VMs
2. Export the image as VMDK or QCOW2 format using existing virtualization tools. See the tools
documentation for your virtualization environment.
3. Upload the image to Oracle Cloud Infrastructure Object Storage. See Managing Objects and Overview
of Object Storage for more information.
4. Import the image. See Importing Custom Images for Emulation Mode.
Availability Domain 1
ORACLE CLOUD INFRASTRUCTURE (REGION)
AD2
• In a BYOH scenario, each guest VM can get
AD3
one or more secondary VNICs.
Subnet A
10.0.0.0/24
Subnet B
10.0.1.0/24 • In case SR-IOV virtual functions (VF) are
being used by the hypervisor to provide
VNIC1 VNIC2 VNIC3 VNIC4 network access to the guest VMs, each VF
can be configured with the VLAN tag and
MAC address of a secondary VNIC.
primar
• Guest-VM can have a private and a public IP
y
NIC associated
VF2
VF1
VF3
1
Hypervisor
• Each Shape has a limit on the amount of
VNICs you can have. Please check compute
shapes documentation for more information
Guest VM3
Guest VM2
VNIC5
Guest VM1
Subnet X
172.16.0.0/2
Bare metal instance 4
NIC2
• Oracle Linux KVM image is available for deployment as a custom image for Oracle Cloud
infrastructure.
• This Oracle packaged image simplifies the deployment of virtual machines (VMs) by
integrating with services such as block storage and virtual network interfaces through the use
of scripted tools
• These tools include support for defining the VM guest domain, allocating a specific block
device or VNIC and launching and removing VMs on Oracle Cloud Infrastructure
• Currently, the BM.Standard1.36 and BM.Standard2.52 shapes are supported
• Users should be familiar with managing virtual guests using libvirt, specifically virsh and virt-
install
Prior to creating a new virtual machine, take note of what resources are required. In particular:
# oci-kvm create -D guest-01 --disk /dev/sdX –net <internal IP address> -V --vcpus 4 --memory
8192 --boot cdrom,hd --location /home/opc/Oracle-Linux-7.4-Boot-ISO.iso --nographics --console
pty,target_type=serial --console pty,target_type=virtio --noautoconsole --os-variant=rhel7 --
extra-args "console=tty0 console=ttyS0,115200n8 serial"
• For those familiar with Oracle Cloud Infrastructure, to use NGC, you need to log into the
Console, configure the settings as needed, and then create an instance based on the NGC
image by specifying the image OCID. After launching the instance, you can SSH into the
instance and start running deep learning jobs using framework containers from the NGC
container registry.
The content of the user_data attribute must be a base64 encoded script in any of the cloud-init
formats supported by the OS being launched, including:
The first two IP addresses and the last one in each subnet's CIDR are reserved
• Make sure to keep the DHCP client running so you can always access the instance
• If you stop the DHCP client manually or disable NetworkManager (which stops the DHCP
client on Linux instances), the instance can't renew its DHCP lease and will become
inaccessible when the lease expires (typically within 24 hours)
• OCI offers a fully managed, secure, and highly available NTP (Network Time Protocol) server
• You can use the NTP service to set the date, time, and time zone for your compute and DBaaS instances
• Multiple internal services including Exadata, 2-node RAC, compute, and audit services use the NTP time
source
• Any new compute and DBaaS instance created on OCI is automatically configured to use the NTP service
through DHCP. You can also choose use a public NTP server or use FC to leverage an on-premises NTP
server.
• Steps to configure NTP service (NTP service offers a Stratum 2 clock source accurate to within 1 second)
[root@webserver1 opc]# ntpq -p
remote refid st t when poll reach delay offset jitter
==============================================================================
*169.254.169.254 192.168.0.4 2 u 34 64 1 0.338 0.118 0.242