{"id":20221135,"url":"https://github.com/kevchu3/openshift-persistent-storage","last_synced_at":"2025-07-28T08:43:48.060Z","repository":{"id":140538112,"uuid":"179163116","full_name":"kevchu3/openshift-persistent-storage","owner":"kevchu3","description":"Sample implementation of hostpath for OpenShift infrastructure","archived":false,"fork":false,"pushed_at":"2019-12-13T15:56:18.000Z","size":36,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-03T12:14:45.180Z","etag":null,"topics":["hostpath","metrics","openshift","registry"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kevchu3.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-04-02T21:41:48.000Z","updated_at":"2019-12-13T15:56:20.000Z","dependencies_parsed_at":null,"dependency_job_id":"be108c2c-b45e-40c7-92ee-11b28515ef25","html_url":"https://github.com/kevchu3/openshift-persistent-storage","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/kevchu3/openshift-persistent-storage","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevchu3%2Fopenshift-persistent-storage","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevchu3%2Fopenshift-persistent-storage/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevchu3%2Fopenshift-persistent-storage/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevchu3%2Fopenshift-persistent-storage/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kevchu3","download_url":"https://codeload.github.com/kevchu3/openshift-persistent-storage/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kevchu3%2Fopenshift-persistent-storage/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267487629,"owners_count":24095652,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-28T02:00:09.689Z","response_time":68,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hostpath","metrics","openshift","registry"],"created_at":"2024-11-14T06:51:39.099Z","updated_at":"2025-07-28T08:43:48.007Z","avatar_url":"https://github.com/kevchu3.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"OpenShift Persistent Storage\n===========================\n\nThe following are persistent storage examples on OpenShift:\n* Hostpath implementation of infrastructure components (registry, metrics, logging) on a single node using NFS\n* GlusterFS implementation for applications\n* Additional customization of NFS for Docker registry\n\nDisclaimer\n----------\n\nThis is for lab installation and educational purposes only and not to be used in a production environment.\n\nThe use of NFS for the core OpenShift Container Platform components is not recommended, as NFS (and the NFS Protocol) does not provide the proper consistency needed for the applications that make up the OpenShift Container Platform infrastructure.\n\nRequirements\n------------\n\n* OpenShift Container Platform 3.11\n* OpenShift Container Storage 3.11 (for application persistent storage only)\n\nSetup\n-----\n\nTo configure persistent storage, the cluster should have the following tiers:\n* Master node(s)\n* 1 infrastructure node - with NFS storage\n* 3 GlusterFS nodes - for OpenShift Container Storage (OCS) converged mode\n* N application nodes\n\nOn the infra node, create a new partition for each of Docker registry and Cassandra (assumes Docker pool has already been created)\n```\nfdisk /dev/vdb\n               enter \"n\" #To create new partition (vdb2 with all defaults)\n               enter \"t\" #To tag/label the partition which got created (tag \"8e\")\n               enter \"w\" #To write the created partition to the server\npartprobe /dev/vdb\n```\n\nThe resulting partitions should look something like this:\n```\nlsblk\n...\nvdb           252:16   0   50G  0 disk \n├─vdb1        252:17   0   30G  0 part /var/lib/docker\n├─vdb2        252:18   0   15G  0 part\n├─vdb3        252:19   0    5G  0 part\n├─vdb4        252:20   0    1K  0 part \n└─vdb5        252:21   0   10G  0 part\n```\n\nFormat the new partitions\n```\nmkfs.xfs /dev/vdb2\nmkfs.xfs /dev/vdb3\nmkfs.xfs /dev/vdb5\n\n\n```\n\nDeploy\n------\n\nRun the hostpath setup from the node that will be used to host the registry, metrics, and logging.\n```\n./hostpath-setup.sh\n```\n\nThe partitions should now be mounted:\n```\nlsblk\n...\nvdb           252:16   0   50G  0 disk \n├─vdb1        252:17   0   30G  0 part /var/lib/docker\n├─vdb2        252:18   0   15G  0 part /exports/registry\n├─vdb3        252:19   0    5G  0 part /exports/metrics\n├─vdb4        252:20   0    1K  0 part \n└─vdb5        252:21   0   10G  0 part /exports/logging-es\n```\n\nRun the GlusterFS setup from the nodes that will be used to host application persistent storage.\n```\n./glusterfs-setup.sh\n```\n\nCopy the files in `group_vars/OSEv3` and run the base Ansible playbooks to configure infrastructure and application persistent storage:\n```\ncp group_vars/OSEv3 \u003cdestination\u003e\nansible-playbook -i hosts.lab config.yml\n```\n\nIf needed, manually create the PersistentVolume for metrics:\n```\noc create -f metrics-volume.pv.yml\noc create -f logging-volume.pv.yml\n```\n\nOptionally, to apply NFS customizations on the Docker registry:\n```\nansible-playbook -i hosts.lab post-config.yml\n```\n\nLicense\n-------\n\nGPLv3\n\nAuthor\n------\n\nKevin Chung\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkevchu3%2Fopenshift-persistent-storage","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkevchu3%2Fopenshift-persistent-storage","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkevchu3%2Fopenshift-persistent-storage/lists"}