Articles tagged with ocp

OCP 4.5: Rough etcd backup cronjob

8 | Written on Mon 28 September 2020. Posted in Nuggets | Richard Walker

Change project

oc project openshift-config

Create Service Account

oc create sa approver

Make service account cluster admin

oc adm policy add-role-to-user cluster-admin system:serviceaccount:approver

Add service account to scc "privileged"

oc edit scc privileged

Example:

users:
- system:admin
- system:serviceaccount:openshift-infra:build-controller
- system:serviceaccount:approver

Create NFS PV

vi …

Read more

OCP 4.2: Quick Reference

1 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

Get cluster version:

oc get clusterversion

List clsuter operators:

oc get clusteroperators

List nodes:

oc get nodes

Web console runs as pods in the openshift-console project, managed by the openshift-console-operator project. Get the URL with:

oc get routes -n openshift-console

List existing machinset:

oc get machinesets -n openshift-machine-api -o wide …

Read more

OCP 4.2: Update Cluster

0 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

OpenShift 4 enables clusters to upgrade Over-the-Air (OTA), ensuring that a cluster runs the latest available version seamlessly.

  • Machine Config Operator

The Machine Config Operator applies the desired machine state to each of the nodes. This component also handles the rolling upgrade of nodes in the cluster, and uses CoreOS …

Read more

OCP 4.2: Scaling Cluster

1 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

Manually Scaling

OpenShift Container Platform can scale the cluster in and out by adding or removing workers through the Machine API.

  • The MachineSet controller describes a group of worker nodes.
  • The Cluster Autoscaler operator manages the ClusterAutoscaler and MachineAutoscaler

The Machine API provides the following custom resources:

  • Machines are the …

Read more

OCP 4.2: Scaling Applications

1 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

The number of pod replicas for a specific deployment or deployment configuration can be increased or decreased. The number of replicas needed for an application is typically defined in a deployment or deployment configuration resource. A replica set or replication controller (managed by a deployment or a deployment configuration) guarantees …

Read more

OCP 4.2: Limiting Resource Usage

2 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

A pod definition can include both resource requests and resource limits:

  • Resource requests
  • Resource limits

Resource request and resource limits should be defined for each container in either a deployment or a deployment configuration resource.

To view compute usage information on individual nodes, the oc describe node command is used …

Read more

OCP 4.2: Pods

1 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

OpenShift Scheduler Algorithm

The pod scheduler determines placement of new pods onto nodes in the OpenShift cluster which supports concepts of zones and regions by using node labels, affinity rules, and anti-affinity rules.

Pod scheduler algorithm follows a three step process:

  • Filtering nodes
  • Prioritizing the filtered list of nodes
  • Selecting …

Read more

OCP 4.2: Networking

5 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

OpenShift implements a software-defined network (SDN) to manage the network infrastructure of the cluster and user applications. It decouples the software that handles the traffic, called the control plane, and the underlying mechanisms that route the traffic, called the data plane.

  • programmatically manage network traffic and network resources
  • manage communication …

Read more

OCP 4.2: Security Context Constraints

1 | Written on Tue 11 February 2020. Posted in Nuggets | Richard Walker

Controlling Application Permissions with Security Context Constraints (SCCs) which are a security mechanism that restricts access to resources, but not to operations .

SCCs limit the access from a running pod in OpenShift to the host environment:

  • Running privileged containers
  • Requesting extra capabilities to a container
  • Using host directories as volumes …

Read more

  (Page 1 / 2)  Next