OC Infra Funda SG (050 101)
OC Infra Funda SG (050 101)
OC Infra Funda SG (050 101)
ORACLE CLOUD DATA CENTER REGION • Create an IPSec connection for VPN
AVAILABILITY DOMAIN-2 • Data center admin must configure the on-
premises router before network traffic can flow
Custom Route
Table
between your on-premises network and VCN
• At your end of the IPSec VPN is the actual
SUBNET B,
10.0.2.0/24 router in your on-premises network (hardware or
software). A virtual representation of the router
VCN, 10.0.0.0/16 in Bare Metal Cloud Services is referred to
as Customer-Premises Equipment (CPE)
CUSTOMER
DATA CENTER
• The Domain Name System (DNS) enables lookup of other computers using host names.
• You choose the DNS for each subnet in the cloud network.
– Default Choice: Internet and VCN Resolver. This is an Oracle-provided option that
includes two parts:
— Internet Resolver: Lets instances use host names that are publicly published on the
Internet. The instances do not need to have Internet access by way of either an IGW or
an IPSec VPN DRG.
— VCN Resolver: Lets instances use host names (which you can assign) to communicate
with other instances in the VCN.
– Custom Resolver: Use your own DNS servers. These could be Internet IP
addresses for DNS servers in your VCN, or DNS servers in your on-premises
network, which is connected to your VCN by way of an IPSec VPN connection.
Instance FQDN: <hostname>.<subnet DNS label>.<VCN DNS label>.oraclevcn.com
(you can specify VCN, Subnet and hostname DNS labels)
If you choose to use the default option of DNS, that is, Internet and VCN Resolver with DNS
Hostnames Across the VCN, then all instances in the VCN can communicate with each other without
knowing their IP addresses. Make sure to assign a DNS label to the VCN and every subnet. Then
make sure to assign every instance a host name (or at least a display name) at launch. The
instances can then communicate with each other using FQDNs instead of IP addresses. If you also
set the Search Domain DHCP option to the VCN domain name, the instances can then communicate
with each other using just <hostname>.<subnet DNS label> instead of the FQDN.
If you use Custom DNS Servers to Resolve DNS Hostnames, then you can set up an instance to be
a custom DNS server within your VCN and configure that instance to resolve the hostnames for your
instances. You must configure the servers to use 169.254.169.254 as the forwarder for the VCN
domain.
Your cloud network uses DHCP options to automatically provide configuration information to the
instances when they boot up. Each cloud network comes with a default set of DHCP options with an
initial value that you can change. If you don't specify otherwise, every subnet will use the VCN's
default set of DHCP options.
You can't change which set of DHCP options is associated with a subnet after the subnet is created.
If you don't want to use the default set, make sure to create your desired set of DHCP options before
creating the subnet. However, remember that you can also change the values for the options.
Whenever you change the value of one of the DHCP options, you need to either restart the DHCP
client on the instance, or reboot the instance, for the change to take effect on existing instances in
the subnets associated with that set of DHCP options.
Be sure to keep the DHCP client running so you can always access the instance. If you stop the
DHCP client manually or disable Network Manager, the instance can't renew its DHCP lease and will
become inaccessible when the lease expires (typically within 24 hours). Do not disable Network
Manager unless you use another method to ensure renewal of the lease. Stopping the DHCP client
might remove the host route table when the lease expires. Also, loss of network connectivity to your
iSCSI connections might result in loss of the boot drive.
Gray VCN
Red VCN
Off-Box Network
Virtualization
Physical Network
We use ‘Off Box Network Virtualization’. Note that the virtualization layer is well isolated from the
Bare-Metal nodes and as a result, it is much harder for a bad actor to compromise the virtualization
layer.
[opc@iperf-client ~]$ sudo iperf3 -c 10.0.0.5 [opc@iperf-client ~]$ sudo iperf3 -c 129.213.56.64
Connecting to host 10.0.0.5, port 5201 Connecting to host 129.213.56.64, port 5201
[ 4] local 10.0.2.3 port 45988 connected to 10.0.0.5 port 5201 [ 4] local 10.0.2.3 port 34528 connected to 129.213.56.64 port 5201
[ ID] Interval Transfer Bandwidth Retr Cwnd [ ID] Interval Transfer Bandwidth Retr Cwnd
[ 4] 0.00-1.00 sec 1.13 GBytes 9.67 Gbits/sec 25 2.54 MBytes [ 4] 0.00-1.00 sec 666 MBytes 5.59 Gbits/sec 428 1.43 MBytes
[ 4] 1.00-2.00 sec 1.15 GBytes 9.87 Gbits/sec 0 3.02 MBytes [ 4] 1.00-2.00 sec 462 MBytes 3.88 Gbits/sec 556 1.32 MBytes
[ 4] 2.00-3.00 sec 1.15 GBytes 9.86 Gbits/sec 66 3.02 MBytes [ 4] 2.00-3.00 sec 462 MBytes 3.88 Gbits/sec 550 1.22 MBytes
[ 4] 3.00-4.00 sec 1.15 GBytes 9.86 Gbits/sec 6 2.12 MBytes [ 4] 3.00-4.00 sec 461 MBytes 3.87 Gbits/sec 499 1.25 MBytes
[ 4] 4.00-5.00 sec 1.15 GBytes 9.87 Gbits/sec 3 3.02 MBytes [ 4] 4.00-5.00 sec 462 MBytes 3.88 Gbits/sec 509 1.24 MBytes
[ 4] 5.00-6.00 sec 1.15 GBytes 9.87 Gbits/sec 0 3.02 MBytes [ 4] 5.00-6.00 sec 476 MBytes 3.99 Gbits/sec 512 446 KBytes
[ 4] 6.00-7.00 sec 1.15 GBytes 9.87 Gbits/sec 0 3.02 MBytes [ 4] 6.00-7.00 sec 491 MBytes 4.12 Gbits/sec 600 428 KBytes
[ 4] 7.00-8.00 sec 1.15 GBytes 9.87 Gbits/sec 0 3.02 MBytes [ 4] 7.00-8.00 sec 486 MBytes 4.08 Gbits/sec 565 376 KBytes
[ 4] 8.00-9.00 sec 1.15 GBytes 9.86 Gbits/sec 0 3.02 MBytes [ 4] 8.00-9.00 sec 480 MBytes 4.03 Gbits/sec 522 376 KBytes
[ 4] 9.00-10.00 sec 1.15 GBytes 9.87 Gbits/sec 0 3.02 MBytes [ 4] 9.00-10.00 sec 482 MBytes 4.05 Gbits/sec 590 227 KBytes
------------------------- -------------------------
[ ID] Interval Transfer Bandwidth Retr [ ID] Interval Transfer Bandwidth Retr
[ 4] 0.00-10.00 sec 11.5 GBytes 9.85 Gbits/sec 100 sender [ 4] 0.00-10.00 sec 4.82 GBytes 4.14 Gbits/sec 5331 sender
[ 4] 0.00-10.00 sec 11.5 GBytes 9.84 Gbits/sec receiver [ 4] 0.00-10.00 sec 4.81 GBytes 4.13 Gbits/sec receiver
USER U01
VCN01
COMPARTMENT
TENANCY
Compute Service
September 2017
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
Latency: Same Random and Sequential: ~90 μsec Read, ~20 μsec Write
• Oracle Compute Cloud Service enables you to select from a range of predefined shapes
that determine the number of CPUs available in an instance and the amount of RAM
available in an instance.
• Several predefined shapes are available for both bare metal and virtual machine
instances.
While creating Compute instances, you can assign CPU and memory resources by selecting from a
wide range of resource profiles (called shapes), each of which is a carefully designed combination of
processor and memory limits.
In the case of standard VM instances, NVMe storage is not available. For all the shapes, Block
Volume storage is offered.
The Dense I/O instances are configured with 28.8 TB of local NVMe storage and are ideal for
extreme transactional workloads that work on large datasets and require low latency and high
throughput, such as Big Data and High Performance Compute (HPC) applications.
RAID 1: An exact copy RAID 10: Stripes data across multiple mirrored RAID 6: Block-level striping with two parity
(or mirror) of a set of pairs. As long as one disk in each mirrored pair blocks distributed across all member disks
data on two or more is functional, data can be retrieved
disks
RAID 10 across all 4 SSDs with 6.4 TB RAID 6 across all 4 SSDs with 6.4 TB
usable space, can survive the failure of usable space, but can survive the failure of
one device; fast performance two devices; slower, but higher durability
Canonical-Ubuntu-16.x-
Ubuntu 16.04 LTS Ubuntu is a free, open-source Linux distribution
<date>-<number>
Windows Server 2012 R2 – Windows-Server-2012-R2-
Windows Server 2012 R2 Standard Edition
Bare Metal (BM) Standard-Edition-BM
Windows Server 2012 R2 - Windows-Server-2012-R2-
Windows Server 2012 R2 Standard Edition
Virtual Machine (VM) Standard-Edition-VM
All Oracle-provided images include rules that allow only "root" on Linux instances or "Administrators"
on Windows instances to make outgoing connections to the iSCSI network endpoint
(169.254.0.2:3260) that serves the instance's boot and block volumes.
Oracle recommends that you do not reconfigure the firewall on your instance to remove these rules.
Removing these rules allows non-root users or non-administrators to access the instance’s boot disk
volume. Oracle recommends that you do not create custom images without these rules unless you
understand the security risks.
• Possible to create a custom image of an instance’s boot disk and use it to launch other
instances.
• Instances you launch from your image include customizations, configuration, and
software installed when you created the image.
• When you create an image of a running instance, the instance shuts down and remains
unavailable for several minutes. When the process completes, the instance restarts.
• Custom images do not include the data from any attached block volumes.
• Custom images cannot be > 50 GB in size.
• Custom images cannot be downloaded or exported.
• Support Generalized and Specialized images for Windows.
– Generalized image - generalized OS disk, cleaned of computer-specific information.
– Specialized image - OS disk that is already fully installed, and a copy of the original
BM or VM.
While use of PuTTY is shown in the slide for accessing from Windows environments, you could also
install a bash shell – such as the Ubuntu based bash shell or Git bash – in a Windows environment.
When you use a bash environment, the Linux commands work the same way in bash shell in
Windows environment.
Before you can launch an instance, you need to have a Virtual Cloud Network (VCN). In the VCN,
you launch the instance into a subnet. A subnet is a subdivision of your VCN that you define in a
single Availability Domain. The subnet directs traffic according to a route table. The subnet also uses
a security list to control traffic in and out of the instance.
When you created a VCN, you would have noted the details of the VCN that you just created. The
VCN has the following resources and characteristics:
• CIDR block range of 10.0.0.0/16
• An Internet Gateway
• A route table with a default route rule to enable traffic to and from the Internet Gateway
• A Default Security List that allows specific ingress traffic to and all egress traffic from the
instance
• A public subnet in each Availability Domain.
• The VCN will automatically use the Internet and VCN Resolver for DNS.
The instance is displayed in the Console in a provisioning state. Expect provisioning to take a few
minutes before the status changes to Running. Do not refresh the page. Once the instance is
running, wait a few more minutes for the operating system to boot before you attempt to connect.
The shape you select determines the number of CPUs, memory to be allocated to your Compute
instances.
The public IP address of your instance is what you need to connect to the instance and configure
other resources within that instance.
Use the following SSH command to access the instance. Enter the passphrase welcome1 when
prompted.
$ ssh opc@<public-ip-address>
• <public-ip-address> is your instance IP address that you retrieved from the Console.
Block Volume Service provides network storage to use with your Compute instances. After you
create, attach, and mount a volume to your instance, you can use it just as you would a physical
hard drive on your computer. A volume can be attached to a single instance at a time, but you can
detach it from one instance and attach to another instance, keeping your data intact.
Challenge-Handshake Authentication Protocol (CHAP) is a security protocol. When you set up your
production environment, Oracle recommends that you use CHAP credentials.
SUBNET01
• Mounts the block volume and
transfers some content
• Customizes the instance and USER U01
COMPARTMENT
TENANCY
• Block Volume Service lets you dynamically add storage capacity to an instance.
• You can create, attach, connect, and move volumes, as needed, to meet your storage
and application requirements.
• Once attached and connected to an instance, you can use a volume like a regular hard
drive.
• Volumes can also be disconnected and attached to another instance without the loss of
data, thereby providing persistence and portability.
• Elastic block storage volumes are configurable from 50GB to 2TB
• The service offers 60 IOPS per GB and scales linearly
• Data is encrypted at rest in both volumes and backups
• All volumes are automatically replicated for you helping to protect against data loss.
• Typically used for persistent and durable storage.
A common usage of Block Volume Service is to add storage capacity to an instance. To use a bock
storage volume, you should:
• Create a block storage volume through the console or the API
• Attach the volume to an instance using a volume attachment
• Connect to the volume from your instance's guest OS using iSCSI
• Mount the volume and use within your instance
A Block Volume Service volume can be detached from an instance and moved to a different instance
without loss of data. This data persistence allows you to easily migrate data between instances and
ensures that your data is safely stored, even when it is not connected to an instance. Any data will
remain intact until you reformat or delete the volume.
To move your volume to another instance, unmount the drive from the initial instance, terminate the
iSCSI connection, and attach it to the second instance. From there, you simply connect and mount
the drive from that instance's guest OS to instantly have access to all of your data. Additionally,
Block Volume Service volumes offer a high level of data durability compared to standard, attached
drives. All volumes are automatically replicated for you, helping to protect against data loss.
The components required to create a volume and attach it to an instance are briefly
described as follows:
• Instance
– An Oracle Cloud Infrastructure compute host
• iSCSI
– A TCP/IP-based standard used for communication between the instance and the
attached volume
• Volume
– A detachable block storage device that allows you to dynamically expand the storage
capacity of an instance
• Resource Identifier
– Each Oracle Bare Metal Cloud Services resource has a unique, Oracle-assigned
identifier called an Oracle Cloud ID (OCID).
The Internet Small Computer System Interface (iSCSI) is an IP-based standard for connecting
storage devices. iSCSI encapsulates SCSI commands in IP network packets, which allows data
transfer over long distances and sharing of storage by client systems. As iSCSI uses the existing IP
infrastructure, it does not require the purchase and installation of fiber-optic cabling and interface
adapters that are needed to implement Fibre Channel (FC) storage area networks.
Oracle Linux supports iSCSI initiator functionality in software. The kernel-resident device driver uses
the existing network interface card (NIC) and network stack to emulate a hardware iSCSI initiator. As
the iSCSI initiator functionality is not available at the level of the system BIOS, you cannot boot an
Oracle Linux system from iSCSI storage.
Data
Applications
Instance
Virtual
Disk
A storage volume is a virtual disk that provides persistent block storage for Compute instances.
You can use storage volumes to store data and applications.
Block Volume Service, a part of Oracle Cloud Infrastructure, allows you to:
• Create block storage volumes and attach them to your Compute instances. When you create
a storage volume, you can specify the capacity that you need.
• Attach one or more storage volumes to an instance either while creating the instance or later,
while the instance is running.
• Scale up or scale down the block storage capacity for the instance by attaching or detaching
storage volumes even while the instance is running. Also, remember that, when a storage
volume is detached from an instance or when the instance is deleted, data stored on the
storage volume is not lost.
You use the iSCSI protocol to attach a volume to an instance. Once the volume is attached, you log
on to the instance and use the iscsiadm command-line tool to configure the iSCSI connection. After
you configure the volume, you can mount it and use it like a normal hard drive.
To take a backup:
• In the console, click Storage.
• Click Backups.
• Click the block volume for which you want to create a backup.
• Click Create Backup.
• Enter a name for the backup, and then click Create Backup.
The backup will be completed once its icon no longer lists it as CREATING in the volume list.
To restore a new volume from a backup:
• In the Console, click Storage, and then click Backups.
- A list of the block volumes in the compartment you're viewing is displayed. If you don’t
see the one you're looking for, make sure you’re viewing the correct compartment.
• Select the block volume backup you want to restore.
• Click Create Block Volume.
• Enter a name for the block volume and choose the Availability Domain in which you want to
restore it.
• Click Create.
The volume will be ready to attach once its icon no longer lists it as PROVISIONING in the volume
list.
Mount on any
Mount Point
• When an instance no longer requires a block volume, you can disconnect and then
detach it from the instance without any loss of data.
• When you attach the same volume to another instance or to the same instance, DO
NOT FORMAT the disk volume. Otherwise, you will lose all the data on the volume.
• When the volume itself is no longer needed, you can delete the block volume.
• You cannot undo a delete operation. Any data on a volume will be permanently deleted
once the volume is deleted.
• Object storage is where data is handled as an object, also known as unstructured data.
• Object Storage use cases:
– Big Data: Object Storage Service enables you to not only store large data sets, but
also operate seamlessly on them. You can generate business insights by using
the HDFS connector to interface with analytics engines such as Apache Spark and
MapReduce.
– Archive and Storage: Backup or archive data is typically written once and read
many times. The durability and low cost characteristics of Object Storage
Service make it suitable to store data for long durations.
– Content Repository: Object Storage Service supports any content type, images,
logs, and video. You can store this data for a long time and the storage scales in tune
with your need.
• Object storage is where data is handled as an object, also known as unstructured data. The
main differences between object storage and traditional storage (also known as block
storage), are listed as follows:
- Stored data contains customized metadata.
- Data is indexed, allowing for much faster search results.
- Data can be located by using pointers instead of finding its location based on tracks
and sectors on the hard disk (that is, the standard file system that we have used for
many years).
• This type of storage is used as an essential part of cloud services, in data centers, and it is
normally integrated with virtual machines.
• Because object storage allows for additional attributes as part of the “bundle,” applications,
programs and storage devices are able to better manipulate data.
• Nearly any file type can be stored in the form of object storage. Some popular files include
media files (images, videos, music, and photos), documents, PDFs, backups, archives, and
so on.
• Multiple users can access the data.
With Object Storage Service, you can safely and securely store or retrieve data directly from the
Internet or from within the cloud platform. Object Storage Service is agnostic to data content type. It
enables a variety of use cases and works equally well with them. The Object Storage Service is a
regional service. It is not tied to any specific compute instance. You can access data from anywhere
within or outside the context of the Oracle Cloud Infrastructure, as long as you have Internet
connectivity and can access the Object Storage Service API endpoint.
(HDFS Connector: https://docs.us-phoenix-1.oraclecloud.com/Content/Object/Tasks/hadoopsupport.htm)
• Object
• Bucket
• Namespace
• Compartment
A bucket is associated with a single compartment. The compartment has policies that indicate what
actions a user can perform on a bucket and all the objects in the bucket.
An object is a file or unstructured data such as: multimedia files, data backups, static web content, or
logs that you upload to a bucket within a compartment within a namespace. Objects are processed
as a single entity. You can't edit or append data to an object, but you can replace the entire object.
Note: In this course, while you can create a bucket and upload data as objects, we will not use
object storage resources in the hands-on labs and practices.
• Object Storage Service supports multipart uploads for more efficient and resilient
uploads, especially for large objects.
• You can use the retry feature to upload only the failed upload.
• You can use multipart upload RESTAPI calls or the Java Software Development Kit
(SDK) to manage multipart uploads, but not the Console.
With multipart uploads, individual parts of an object can be uploaded in parallel to reduce the amount
of time you spend uploading. Multipart uploads can also minimize the impact of network failures by
letting you retry a failed part upload instead of requiring you to retry an entire object upload. Oracle
recommends that you perform a multipart upload to upload objects larger than 100 MB. The
maximum size for an uploaded object is 10 TB. Object parts must be no larger than 50 GB. For very
large uploads, a multipart upload also offers you the flexibility of pausing and resuming at your own
pace.
A multipart upload consists of the following steps:
• Initiating an upload
• Uploading object parts
• Committing the upload
In the initiating step, you should create the parts to upload. The Object Storage Service provides API
operations for the remaining steps. The service also provides API operations for listing in-progress
multipart uploads, listing the object parts in an in-progress multipart upload, and aborting in-progress
multipart uploads.
Creating Object Parts
With multipart upload, you split the object you want to upload into individual parts. Individual parts
can be as large as 50 GB or as small as 10 MB. (The Object Storage Service waives the minimum
part size restriction for the last uploaded part.) Decide what part number you want to use for each
part. Part numbers can range from 1 to 10,000. You do not need to assign contiguous numbers, but
the Object Storage Service will construct the object by ordering part numbers in ascending order.
SUBNET01
USER U01
VCN01
COMPARTMENT
TENANCY