Skip to content

Commit 8585650

Browse files
committed
updates
1 parent 176b2ae commit 8585650

File tree

2 files changed

+139
-135
lines changed

2 files changed

+139
-135
lines changed

OracleSolaris_OCI/02_Block_Storage/Oracle Solaris 11.4 Utilizing storage resources on OCI.md

-134
This file was deleted.

OracleSolaris_OCI/02_Block_Storage/README.md

+139-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,144 @@
11
# Utilizing Storage Resources on the Oracle Cloud Infrastructure
22

3-
Once you have successfully [launched an Oracle Solaris](OracleSolaris_OCI/Launch_Instance) instance, you would likely want to use other Oracle Cloud Storage resources to run your applications or deploy zones in Oracle Solaris. This document provides a [demonstration](Oracle Solaris 11.4 Utilizing storage resources on OCI.md) on how you can create and attach Block Volumes to your Oracle Solaris instance. For more information on types of storage resources available, please refer to the [OCI documentation](https://docs.oracle.com/en-us/iaas/Content/home.htm).
3+
Once you have successfully [launched an Oracle Solaris](OracleSolaris_OCI/Launch_Instance) instance, you would likely want to use other Oracle Cloud Storage resources to run your applications or deploy zones in Oracle Solaris. This document provides a demonstration on how you can create and attach Block Volumes to your Oracle Solaris instance. For more information on types of storage resources available, please refer to the [OCI documentation](https://docs.oracle.com/en-us/iaas/Content/home.htm).
4+
5+
------
6+
7+
8+
9+
## Step (1): Adding a block storage to your compartment
10+
11+
In order to attach a block volume to your instance you need to first have a block storage created in your compartment. If you already have a block storage attached to your compartment, you can skip this step.
12+
13+
14+
15+
#### a) Navigate to the Block Storage list by clicking on the hamburger icon on the left and click on Block Volumes
16+
17+
![](Images/OCI_attach_block_storage.png)
18+
19+
20+
21+
#### b) Creating your block volume in the specified compartment
22+
23+
24+
25+
![](Images/OCI_create_block_volume.png)
26+
27+
28+
29+
#### c)Configure your block volume in your preferred compartment and define the appropriate volume size and backup policies
30+
31+
32+
33+
![](Images/OCI_define_block_storage.png)
34+
35+
36+
37+
#### c) Once you have created the Block Volume you can then navigate to your instance to attach the Block Volume to your instance
38+
39+
40+
41+
![](Images/OCI_attached_block_volume_compartment.png)
42+
43+
44+
45+
46+
47+
## Step (2): Attaching a Block Volume to your running instance
48+
49+
Once you have created a Block Volume in your compartment, you can then attach it to your running instance to start utilizing OCI storage resources.
50+
51+
Here is how to attach a Block Volume to your instance.
52+
53+
#### a) Navigate to your instance and scroll down to find Resources
54+
55+
![](Images/OCI_attach_block_volume.png)
56+
57+
58+
59+
#### b) Select Attach Block Volume and define parameters
60+
61+
Note: For Solaris instances, only iSCSI and emulated attachments are supported.
62+
63+
64+
65+
![](Images/OCI_attach_block_volume_instance.png)
66+
67+
68+
69+
70+
71+
![](Images/OCI_attaching_block_volume.png)
72+
73+
74+
75+
76+
77+
Once you've created a block volume and attached it to your Solaris guest in the OCI console, you still need to do a small amount of work on the Solaris guest to let it see the storage you've attached.
78+
79+
80+
81+
## Step (3): Enabling Solaris guest to recognize the attached block volume
82+
83+
84+
85+
Before we move to enable Solaris to discover the attached block volume, let us check for the available disks. Once we run the format command, we see the current available disk to be a QEMU emulated c1d0.
86+
87+
```
88+
root@oraclesolaris-demo:/export/home/opc# format
89+
Searching for disks...done
90+
91+
AVAILABLE DISK SELECTIONS:
92+
0. c1d0 <QEMU HAR-QM0000-0001-50.00GB>
93+
/pci@0,0/pci-ide@1,1/ide@1/cmdk@0,0
94+
/dev/chassis/SYS/MB/hba0
95+
Specify disk (enter its number):
96+
```
97+
98+
In order to create a new zpool, we need to attach an iSCSI disk to the Solaris instance.
99+
100+
#### a) Navigate to the iSCI commands for your attached disk
101+
102+
![](Images/OCI_block_volume_iSCSICommands.png)
103+
104+
105+
106+
#### b) Run the Volume specific iSCSI commands in your console
107+
108+
The OCI Console will display the Linux iSCSI commands, you just need to translate them to the Solaris equivalents. Here's an example of the Linux commands:
109+
110+
```
111+
sudo iscsiadm -m node -o new -T iqn.2015-12.com.oracleiaas:de785f06-2288-4f2f-8ef7-f0c2c25d6144 -p 169.254.2.2:3260
112+
sudo iscsiadm -m node -o update -T iqn.2015-12.com.oracleiaas:de785f06-2288-4f2f-8ef7-f0c2c25d6144 -n node.startup -v automatic
113+
sudo iscsiadm -m node -T iqn.2015-12.com.oracleiaas:de785f06-2288-4f2f-8ef7-f0c2c25d6144 -p 169.254.2.2:3260 -l
114+
```
115+
116+
0. c1d0 <QEMU HAR-QM0000-0001-50.00GB>
117+
/pci@0,0/pci-ide@1,1/ide@1/cmdk@0,0
118+
/dev/chassis/SYS/MB/hba0
119+
120+
Specify disk (enter its number):
121+
122+
The Solaris version of the iSCSI commands follows this format:
123+
124+
```
125+
sudo iscsiadm add static-config iqn.<Enter your disk specific Volume IQN>,<Enter disk specific IP Address and port>
126+
sudo iscsiadm modify discovery --static enable
127+
```
128+
129+
130+
131+
#### c) Verify that the Solaris has discovered the attached disk
132+
133+
![](Images/OCI_attach_disk.png)
134+
135+
136+
137+
Once the disk is attached, you can now create a ZFS pool on the storage. Here is our [GitHub post](https://github.com/oracle/oraclesolaris-contrib/blob/master/Blog_Supplements/Threshold_FMA_Alerts/StatsStore_threshold_alerts.md) on how to create a ZFS pool.
138+
139+
Since the iscsiadm command automatically persists the configuration you enter, the storage (and the ZFS pool) will still be visible after the guest is rebooted.
140+
141+
4142

5143

6144

0 commit comments

Comments
 (0)