@@ -43,14 +43,14 @@ Mirror an operator-registry catalog
43
43
oc adm catalog mirror file:///local/index/my/image:latest my-airgapped-registry.com
44
44
45
45
# Configure a cluster to use a mirrored registry
46
- oc apply -f manifests/imageContentSourcePolicy .yaml
46
+ oc apply -f manifests/imageDigestMirrorSet .yaml
47
47
48
48
# Edit the mirroring mappings and mirror with "oc image mirror" manually
49
49
oc adm catalog mirror --manifests-only quay.io/my/image:latest myregistry.com
50
50
oc image mirror -f manifests/mapping.txt
51
51
52
- # Delete all ImageContentSourcePolicies generated by oc adm catalog mirror
53
- oc delete imagecontentsourcepolicy -l operators.openshift.org/catalog=true
52
+ # Delete all ImageDigestMirrorSets generated by oc adm catalog mirror
53
+ oc delete imagedigestmirrorset -l operators.openshift.org/catalog=true
54
54
----
55
55
56
56
@@ -79,6 +79,10 @@ Deny a certificate signing request
79
79
80
80
81
81
82
+ == oc adm copy-to-node
83
+ Copies specified files to the node.
84
+
85
+
82
86
== oc adm cordon
83
87
Mark node as unschedulable
84
88
@@ -193,13 +197,13 @@ Remove old OpenShift groups referencing missing records from an external provide
193
197
# Prune all orphaned groups
194
198
oc adm groups prune --sync-config=/path/to/ldap-sync-config.yaml --confirm
195
199
196
- # Prune all orphaned groups except the ones from the blacklist file
197
- oc adm groups prune --blacklist=/path/to/blacklist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
200
+ # Prune all orphaned groups except the ones from the denylist file
201
+ oc adm groups prune --blacklist=/path/to/denylist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
198
202
199
- # Prune all orphaned groups from a list of specific groups specified in a whitelist file
200
- oc adm groups prune --whitelist=/path/to/whitelist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
203
+ # Prune all orphaned groups from a list of specific groups specified in an allowlist file
204
+ oc adm groups prune --whitelist=/path/to/allowlist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
201
205
202
- # Prune all orphaned groups from a list of specific groups specified in a whitelist
206
+ # Prune all orphaned groups from a list of specific groups specified in a list
203
207
oc adm groups prune groups/group_name groups/other_name --sync-config=/path/to/ldap-sync-config.yaml --confirm
204
208
----
205
209
@@ -229,8 +233,8 @@ Sync OpenShift groups with records from an external provider
229
233
# Sync all groups except the ones from the blacklist file with an LDAP server
230
234
oc adm groups sync --blacklist=/path/to/blacklist.txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
231
235
232
- # Sync specific groups specified in a whitelist file with an LDAP server
233
- oc adm groups sync --whitelist=/path/to/whitelist .txt --sync-config=/path/to/sync-config.yaml --confirm
236
+ # Sync specific groups specified in an allowlist file with an LDAP server
237
+ oc adm groups sync --whitelist=/path/to/allowlist .txt --sync-config=/path/to/sync-config.yaml --confirm
234
238
235
239
# Sync all OpenShift groups that have been synced previously with an LDAP server
236
240
oc adm groups sync --type=openshift --sync-config=/path/to/ldap-sync-config.yaml --confirm
@@ -263,12 +267,12 @@ Collect debugging data for a given resource
263
267
264
268
265
269
== oc adm migrate icsp
266
- Update imagecontentsourcepolicy file(s) to imagedigestmirrorset file(s).
270
+ Update imagecontentsourcepolicy file(s) to imagedigestmirrorset file(s)
267
271
268
272
.Example usage
269
273
[source,bash,options="nowrap"]
270
274
----
271
- # update the imagecontentsourcepolicy.yaml to new imagedigestmirrorset file under directory mydir
275
+ # Update the imagecontentsourcepolicy.yaml file to a new imagedigestmirrorset file under the mydir directory
272
276
oc adm migrate icsp imagecontentsourcepolicy.yaml --dest-dir mydir
273
277
----
274
278
@@ -310,7 +314,7 @@ Launch a new instance of a pod for gathering debug information
310
314
# Gather information using a specific image stream plug-in
311
315
oc adm must-gather --image-stream=openshift/must-gather:latest
312
316
313
- # Gather information using a specific image, command, and pod-dir
317
+ # Gather information using a specific image, command, and pod directory
314
318
oc adm must-gather --image=my/image:tag --source-dir=/pod/directory -- myspecial-command.sh
315
319
----
316
320
@@ -337,7 +341,7 @@ Display and filter node logs
337
341
# Show kubelet logs from all masters
338
342
oc adm node-logs --role master -u kubelet
339
343
340
- # See what logs are available in masters in /var/logs
344
+ # See what logs are available in masters in /var/log
341
345
oc adm node-logs --role master --path=/
342
346
343
347
# Display cron log file from all masters
@@ -346,6 +350,61 @@ Display and filter node logs
346
350
347
351
348
352
353
+ == oc adm ocp-certificates monitor-certificates
354
+ Watch platform certificates.
355
+
356
+ .Example usage
357
+ [source,bash,options="nowrap"]
358
+ ----
359
+ # Watch platform certificates.
360
+ oc adm ocp-certificates monitor-certificates
361
+ ----
362
+
363
+
364
+
365
+ == oc adm ocp-certificates regenerate-leaf
366
+ Regenerate client and serving certificates of an OpenShift cluster
367
+
368
+
369
+
370
+ == oc adm ocp-certificates regenerate-machine-config-server-serving-cert
371
+ Regenerate the machine config operator certificates in an OpenShift cluster
372
+
373
+
374
+
375
+ == oc adm ocp-certificates regenerate-top-level
376
+ Regenerate the top level certificates in an OpenShift cluster
377
+
378
+
379
+
380
+
381
+ == oc adm ocp-certificates remove-old-trust
382
+ Remove old CAs from ConfigMaps representing platform trust bundles in an OpenShift cluster
383
+
384
+ .Example usage
385
+ [source,bash,options="nowrap"]
386
+ ----
387
+ # Remove only CA certificates created before a certain date from all trust bundles
388
+ oc adm ocp-certificates remove-old-trust configmaps -A --all --created-before 2023-06-05T14:44:06Z
389
+ ----
390
+
391
+
392
+
393
+ == oc adm ocp-certificates update-ignition-ca-bundle-for-machine-config-server
394
+ Update user-data secrets in an OpenShift cluster to use updated MCO certfs
395
+
396
+ .Example usage
397
+ [source,bash,options="nowrap"]
398
+ ----
399
+ # Regenerate the MCO certs without modifying user-data secrets
400
+ oc adm certificates regenerate-machine-config-server-serving-cert --update-ignition=false
401
+
402
+ # Update the user-data secrets to use new MCS certs
403
+ oc adm certificates update-ignition-ca-bundle-for-machine-config-server
404
+ ----
405
+
406
+
407
+
349
408
== oc adm pod-network isolate-projects
350
409
Isolate project network
351
410
@@ -513,13 +572,13 @@ Remove old OpenShift groups referencing missing records from an external provide
513
572
# Prune all orphaned groups
514
573
oc adm prune groups --sync-config=/path/to/ldap-sync-config.yaml --confirm
515
574
516
- # Prune all orphaned groups except the ones from the blacklist file
517
- oc adm prune groups --blacklist=/path/to/blacklist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
575
+ # Prune all orphaned groups except the ones from the denylist file
576
+ oc adm prune groups --blacklist=/path/to/denylist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
518
577
519
- # Prune all orphaned groups from a list of specific groups specified in a whitelist file
520
- oc adm prune groups --whitelist=/path/to/whitelist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
578
+ # Prune all orphaned groups from a list of specific groups specified in an allowlist file
579
+ oc adm prune groups --whitelist=/path/to/allowlist .txt --sync-config=/path/to/ldap-sync-config.yaml --confirm
521
580
522
- # Prune all orphaned groups from a list of specific groups specified in a whitelist
581
+ # Prune all orphaned groups from a list of specific groups specified in a list
523
582
oc adm prune groups groups/group_name groups/other_name --sync-config=/path/to/ldap-sync-config.yaml --confirm
524
583
----
525
584
@@ -545,7 +604,7 @@ Remove unreferenced images
545
604
# To actually perform the prune operation, the confirm flag must be appended
546
605
oc adm prune images --prune-over-size-limit --confirm
547
606
548
- # Force the insecure http protocol with the particular registry host name
607
+ # Force the insecure HTTP protocol with the particular registry host name
549
608
oc adm prune images --registry-url=http://registry.example.org --confirm
550
609
551
610
# Force a secure connection with a custom certificate authority to the particular registry host name
@@ -554,6 +613,24 @@ Remove unreferenced images
554
613
555
614
556
615
616
+ == oc adm reboot-machine-config-pool
617
+ Initiate reboot of the specified MachineConfigPool.
618
+
619
+ .Example usage
620
+ [source,bash,options="nowrap"]
621
+ ----
622
+ # Reboot all MachineConfigPools
623
+ oc adm reboot-machine-config-pool mcp/worker mcp/master
624
+
625
+ # Reboot all MachineConfigPools that inherit from worker. This include all custom MachineConfigPools and infra.
626
+ oc adm reboot-machine-config-pool mcp/worker
627
+
628
+ # Reboot masters
629
+ oc adm reboot-machine-config-pool mcp/master
630
+ ----
631
+
632
+
633
+
557
634
== oc adm release extract
558
635
Extract the contents of an update payload to disk
559
636
@@ -567,7 +644,7 @@ Extract the contents of an update payload to disk
567
644
oc adm release extract --credentials-requests --cloud=aws
568
645
569
646
# Use git to check out the source code for the current cluster release to DIR from linux/s390x image
570
- # Note: Wildcard filter is not supported. Pass a single os/arch to extract
647
+ # Note: Wildcard filter is not supported; pass a single os/arch to extract
571
648
oc adm release extract --git=DIR quay.io/openshift-release-dev/ocp-release:4.11.2 --filter-by-os=linux/s390x
572
649
----
573
650
@@ -592,7 +669,7 @@ Display information about a release
592
669
oc adm release info quay.io/openshift-release-dev/ocp-release:4.11.2 --pullspecs
593
670
594
671
# Show information about linux/s390x image
595
- # Note: Wildcard filter is not supported. Pass a single os/arch to extract
672
+ # Note: Wildcard filter is not supported; pass a single os/arch to extract
596
673
oc adm release info quay.io/openshift-release-dev/ocp-release:4.11.2 --filter-by-os=linux/s390x
597
674
----
598
675
@@ -632,7 +709,7 @@ Create a new OpenShift release
632
709
.Example usage
633
710
[source,bash,options="nowrap"]
634
711
----
635
- # Create a release from the latest origin images and push to a DockerHub repo
712
+ # Create a release from the latest origin images and push to a DockerHub repository
636
713
oc adm release new --from-image-stream=4.11 -n origin --to-image docker.io/mycompany/myrepo:latest
637
714
638
715
# Create a new release with updated metadata from a previous release
@@ -649,6 +726,11 @@ Create a new OpenShift release
649
726
650
727
651
728
729
+ == oc adm restart-kubelet
730
+ Restarts kubelet on the specified nodes
731
+
732
+
733
+
652
734
== oc adm taint
653
735
Update the taints on one or more nodes
654
736
@@ -752,7 +834,7 @@ Upgrade a cluster or adjust the upgrade channel
752
834
.Example usage
753
835
[source,bash,options="nowrap"]
754
836
----
755
- # Review the available cluster updates
837
+ # View the update status and available cluster updates
756
838
oc adm upgrade
757
839
758
840
# Update to the latest version
@@ -785,3 +867,27 @@ Verify the image identity contained in the image signature
785
867
----
786
868
787
869
870
+
871
+ == oc adm wait-for-node-reboot
872
+ Wait for nodes to reboot after running `oc adm reboot-machine-config-pool`
873
+
874
+ .Example usage
875
+ [source,bash,options="nowrap"]
876
+ ----
877
+ # Wait for all nodes to complete a requested reboot from 'oc adm reboot-machine-config-pool mcp/worker mcp/master'
878
+ oc adm wait-for-node-reboot nodes --all
879
+
880
+ # Wait for masters to complete a requested reboot from 'oc adm reboot-machine-config-pool mcp/master'
881
+ oc adm wait-for-node-reboot nodes -l node-role.kubernetes.io/master
882
+
883
+ # Wait for masters to complete a specific reboot
884
+ oc adm wait-for-node-reboot nodes -l node-role.kubernetes.io/master --reboot-number=4
885
+ ----
886
+
887
+
888
+
889
+ == oc adm wait-for-stable-cluster
890
+ wait for the platform operators to become stable
891
+
892
+
893
+
0 commit comments