You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
13. The command you just executed will create your Kube config file. To test it, run the following:
75
75
76
76
```bash
77
-
<copy>
78
77
kubectl cluster-info
79
78
kubectl get nodes -o wide
80
-
</copy>
81
79
```
82
80
83
81
>Note: The GPU nodes may still be provisioning and might not show up just yet. The node name is its private IP address.
@@ -96,7 +94,6 @@
96
94
1. Return to Cloud Shell. Create a new file called **jh-values.yaml** and paste the following:
97
95
98
96
```
99
-
<copy>
100
97
# default configuration
101
98
singleuser:
102
99
cloudMetadata:
@@ -108,33 +105,26 @@
108
105
# kubespawner_override:
109
106
# extra_resource_limits:
110
107
# nvidia.com/gpu: "1"
111
-
</copy>
112
108
```
113
109
114
110
>Note: In this tutorial we use Jupyter notebooks to interact with the GPU-driven NVIDIA microservices. You will not need to enable GPU-based user notebooks to complete the tasks herein.
4. Once the deployment is complete, the Kubernetes service that gets created will provision an OCI Load Balancer for public access. Locate the public IP address of the load balancer and store it for later.
133
125
134
126
```bash
135
-
<copy>
136
127
kubectl get svc -n k8s-jupyter
137
-
</copy>
138
128
```
139
129
140
130
Output:
@@ -150,7 +140,6 @@
150
140
1. Before creating the database, you'll need to create role-based access control (RBAC) for the node. Create a file called **node-rbac.yaml** and paste the following:
151
141
152
142
```
153
-
<copy>
154
143
---
155
144
apiVersion: rbac.authorization.k8s.io/v1
156
145
kind: ClusterRole
@@ -178,13 +167,11 @@
178
167
name: default
179
168
namespace: oracle-database-operator-system
180
169
---
181
-
</copy>
182
170
```
183
171
184
172
2. Create a file called **db-admin-secret.yaml** that will be used to set the DB password upon deployment. Paste the follwing:
185
173
186
174
```
187
-
<copy>
188
175
apiVersion: v1
189
176
kind: Secret
190
177
metadata:
@@ -193,15 +180,13 @@
193
180
type: Opaque
194
181
stringData:
195
182
oracle_pwd: YOURPASSWORDHERE
196
-
</copy>
197
183
```
198
184
199
185
>Note: Be sure to replace the **YOURPASSWORDHERE** above with a value of your own choosing. At least 15 characters, 2 upper case, 2 lower case, 2 numbers, and 2 special characters.
200
186
201
187
3. Create a file called **db23ai-instance.yaml** and paste the following:
202
188
203
189
```
204
-
<copy>
205
190
apiVersion: database.oracle.com/v1alpha1
206
191
kind: SingleInstanceDatabase
207
192
metadata:
@@ -224,23 +209,18 @@
224
209
225
210
replicas: 1
226
211
---
227
-
</copy>
228
212
```
229
213
230
214
4. Apply the manifests using the following command; this creates the RBAC, the password, and the DB pod.
5. After the command completes, it may take 3-5 minutes for the DB instance to come online. You can check the status with the following command. Do not proceed until the status is **Healthy**
export ORACLE_SID=$(kubectl get singleinstancedatabase -n oracle23ai -o 'jsonpath={.items[0].metadata.name}')
259
240
export ORA_POD=$(kubectl get pods -n oracle23ai -o jsonpath='{.items[0].metadata.name}')
260
241
export ORA_CONN=$(kubectl get singleinstancedatabase ${ORACLE_SID} -n oracle23ai -o "jsonpath={.status.connectString}")
261
-
</copy>
262
242
```
263
243
264
244
>Note: If you leave Cloud Shell and return later, you'll need to run the above commands again if you wish to connect to the DB instance directly. That said, after this section, all DB access should be done via Jupyter Notebooks.
32. Now that everything is up and running, you can return to your Jupyter-hub web page and launch a new notebook.
445
+
10. Now that everything is up and running, you can return to your JupyterHub web page and launch a new notebook. If you need to double-check the IP address of your JupyterHub instance, run the following command:
446
+
447
+
```
448
+
kubectl get svc -n k8s-jupyter
449
+
```
450
+
451
+
>Note: make sure to access via HTTP and not HTTPS as we did not configure TLS in this exercise.
452
+
453
+
11. Within the notebook, install the oracledb libraries:
446
454
447
-
33. Within the notebood, install the oracledb libraries
0 commit comments