Skip to content

Commit ec0f230

Browse files
authored
Merge pull request #92695 from apurvabhide17/OADP-5953-resource-requests-for-nodeagent-pod
OADP-5953-Added a module for nodeAgent pod
2 parents 42acf0d + c2b177a commit ec0f230

File tree

4 files changed

+117
-1
lines changed

4 files changed

+117
-1
lines changed

backup_and_restore/application_backup_and_restore/troubleshooting/pods-crash-or-restart-due-to-lack-of-memory-or-cpu.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,5 @@ requests:
2828
* xref:../../../backup_and_restore/application_backup_and_restore/installing/about-installing-oadp.adoc#oadp-velero-cpu-memory-requirements_about-installing-oadp[Velero CPU and memory requirements based on collected data]
2929
3030
include::modules/oadp-pod-crash-set-resource-request-velero.adoc[leveloffset=+1]
31-
include::modules/oadp-pod-crash-set-resource-request-restic.adoc[leveloffset=+1]
31+
include::modules/oadp-pod-crash-set-resource-request-restic.adoc[leveloffset=+1]
32+
include::modules/setting-resource-requests-for-a-nodeagent-pod.adoc[leveloffset=+1]

modules/oadp-pod-crash-set-resource-request-restic.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
You can use the `configuration.restic.podConfig.resourceAllocations` specification field to set specific resource requests for a `Restic` pod.
1010

11+
include::snippets/about-restic-deprecation.adoc[leveloffset=+1]
12+
1113
.Procedure
1214

1315
* Set the `cpu` and `memory` resource requests in the YAML file:
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * backup_and_restore/application_backup_and_restore/pods-crash-or-restart-due-to-lack-of-memory-or-cpu
4+
:_mod-docs-content-type: PROCEDURE
5+
6+
[id="setting-resource-requests-for-a-nodeagent-pod_{context}"]
7+
= Setting resource requests for a nodeAgent pod
8+
9+
You can use the `configuration.nodeAgent.podConfig.resourceAllocations` specification field to set specific resource requests for a `nodeAgent` pod.
10+
11+
include::snippets/about-restic-deprecation.adoc[leveloffset=+1]
12+
13+
14+
.Procedure
15+
16+
. Set the `cpu` and `memory` resource requests in the YAML file:
17+
+
18+
.Example `nodeAgent.yaml` file
19+
[source,yaml]
20+
----
21+
apiVersion: oadp.openshift.io/v1alpha1
22+
kind: DataProtectionApplication
23+
metadata:
24+
name: ts-dpa
25+
spec:
26+
backupLocations:
27+
- velero:
28+
default: true
29+
objectStorage:
30+
bucket: oadp.....njph
31+
prefix: velero
32+
credential:
33+
key: cloud
34+
name: cloud-credentials-gcp
35+
provider: gcp
36+
configuration:
37+
velero:
38+
defaultPlugins:
39+
- gcp
40+
- openshift
41+
- csi
42+
nodeAgent:
43+
enable: true
44+
uploaderType: kopia
45+
podConfig:
46+
resourceAllocations: <1>
47+
requests:
48+
cpu: 1000m
49+
memory: 16Gi <2>
50+
----
51+
<1> The resource allocation examples shown are for average usage.
52+
<2> You can modify this parameter depending on your infrastructure and usage.
53+
54+
. Create the DPA CR by running the following command:
55+
+
56+
[source,terminal]
57+
----
58+
$ oc create -f nodeAgent.yaml
59+
----
60+
61+
.Verification
62+
63+
. Verify that the `nodeAgent` pods are running by using the following command:
64+
+
65+
[source,terminal]
66+
----
67+
$ oc get pods
68+
----
69+
+
70+
.Example output
71+
[source,terminal]
72+
----
73+
NAME READY STATUS RESTARTS AGE
74+
node-agent-hbj9l 1/1 Running 0 97s
75+
node-agent-wmwgz 1/1 Running 0 95s
76+
node-agent-zvc7k 1/1 Running 0 98s
77+
openshift-adp-controller-manager-7f9db86d96-4lhgq 1/1 Running 0 137m
78+
velero-7b6c7fb8d7-ppc8m 1/1 Running 0 4m2s
79+
----
80+
81+
. Check the resource requests by describing one of the `nodeAgent` pod:
82+
+
83+
[source,terminal]
84+
----
85+
$ oc describe pod node-agent-hbj9l | grep -C 5 Requests
86+
----
87+
+
88+
.Example output
89+
[source,terminal]
90+
----
91+
--log-format=text
92+
State: Running
93+
Started: Mon, 09 Jun 2025 16:22:15 +0530
94+
Ready: True
95+
Restart Count: 0
96+
Requests:
97+
cpu: 1
98+
memory: 1Gi
99+
Environment:
100+
NODE_NAME: (v1:spec.nodeName)
101+
VELERO_NAMESPACE: openshift-adp (v1:metadata.namespace)
102+
----
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
// Snippet included in the following modules
2+
3+
//modules/oadp-pod-crash-set-resource-request-restic.adoc
4+
//modules/setting-resource-requests-for-a-nodeagent-pod.adoc
5+
6+
:_mod-docs-content-type: SNIPPET
7+
8+
[NOTE]
9+
====
10+
With {oadp-short} 1.5.0, the `configuration.restic.podConfig.resourceAllocations` specification field is removed from Data Protection Application (DPA). Use the `nodeAgent` section with the `uploaderType` field set to `Kopia` instead of `Restic` .
11+
====

0 commit comments

Comments
 (0)