Skip to content

Instantly share code, notes, and snippets.

View ruo91's full-sized avatar

Yongbok Kim ruo91

View GitHub Profile
@ruo91
ruo91 / openshift-4-mtu-size-issue.txt
Created December 29, 2022 17:28
OpenShift v4.x - MTU Size Issue
[root@bastion 00_Install_Config]# ssh core@master01
Warning: Permanently added 'master01,192.168.0.11' (ECDSA) to the list of known hosts.
Red Hat Enterprise Linux CoreOS 411.86.202212072103-0
Part of OpenShift 4.11, RHCOS is a Kubernetes native operating system
managed by the Machine Config Operator (`clusteroperator/machine-config`).
WARNING: Direct SSH access to machines is not recommended; instead,
make configuration changes via `machineconfig` objects:
https://docs.openshift.com/container-platform/4.11/architecture/architecture-rhcos.html
@ruo91
ruo91 / gentoo-dev-lang-ruby-build-error
Last active November 27, 2022 05:38
Gentoo - /usr/lib64/ruby/2.7.0/rubygems.rb:16:in `require': cannot load such file -- rubygems/compatibility (LoadError)
Using username "root".
Keyboard-interactive authentication prompts from server:
| Password:
End of keyboard-interactive prompts from server
ruo91 ~ # Z^C
ruo91 ~ # cat /var/tmp/portage/dev-lang/ruby-3.1.3/temp/build.log
* Package: dev-lang/ruby-3.1.3:3.1
* Repository: gentoo
* Maintainer: ruby@gentoo.org
* USE: abi_x86_64 amd64 elibc_glibc gdbm ipv6 kernel_linux rdoc ssl userland_GNU
@ruo91
ruo91 / gentoo-2022-11-26-dev-libs-gjs-1.74.1.txt
Created November 26, 2022 12:23
gentoo-2022-11-26-dev-libs-gjs-1.74.1
ruo91 /var/db/repos/gentoo/dev-libs/gjs # cat /var/tmp/portage/dev-libs/gjs-1.74.1/temp/build.log
* Package: dev-libs/gjs-1.74.1:0
* Repository: gentoo
* Maintainer: gnome@gentoo.org
* USE: abi_x86_64 amd64 cairo elibc_glibc kernel_linux readline userland_GNU
* FEATURES: network-sandbox preserve-libs sandbox userpriv usersandbox
>>> Unpacking source...
>>> Unpacking gjs-1.74.1.tar.xz to /var/tmp/portage/dev-libs/gjs-1.74.1/work
>>> Source unpacked in /var/tmp/portage/dev-libs/gjs-1.74.1/work
>>> Preparing source in /var/tmp/portage/dev-libs/gjs-1.74.1/work/gjs-1.74.1 ...
@ruo91
ruo91 / ocp4-on-aws-bootstrap-ignition-forbidden.txt
Created November 29, 2021 05:50
OpenShift v4.x on AWS - GET result: Forbidden (Bootstrap instance)
[?25lUse the ^ and v keys to change the selection.
Press 'e' to edit the selected item, or 'c' for a command prompt.   Red Hat Enterprise Linux CoreOS 46.82.202106161040-0 (Ootpa) (ostree:0)        
@ruo91
ruo91 / Ubuntu_-_refusing_to_run_with_writable_root_inside_chroot
Last active October 6, 2022 11:20
Ubuntu - refusing to run with writable root inside chroot()
Step 1. Remove the vsftpd
root@ruo91:~# apt-get remove vsftpd
Step 2. Install vsftpd v3.x
root@ruo91:~# wget http://us.archive.ubuntu.com/ubuntu/pool/main/v/vsftpd/vsftpd_3.0.2-14ubuntu1_amd64.deb
root@ruo91:~# dpkg -i vsftpd_3.0.2-14ubuntu1_amd64.deb
Step 3. Add in the vsftpd.conf
root@ruo91:~# echo "seccomp_sandbox=NO" >> /etc/vsftpd.conf
@ruo91
ruo91 / ocp4-sdn-issue.md
Last active August 11, 2022 16:18
OpenShift - 네트워크 흐름도 및 이슈 분석

OpenShift - 네트워크 흐름도 및 이슈 분석

OpenShift는 v3.x, v4.x 버전 상관 없이 기본적으로 OpenvSwitch(OVS) 기반의 openshift-sdn cni plugin을 사용한다.
고객사에서 Application 지연 부분이 생기면, OpenShift 플랫폼 상의 문제가 있지 않느냐라는 이슈 제기를 좀 하는데,
SDN의 대부분은 VXLAN 기반이므로 성능상의 이슈가 있을수는 있겠지만, 크게 크리티컬한건 별로 못 봄.

Application 부분과 네트워크 단에서 문제가 발생하는 상황이 대부분이었고, 이를 책임 전가하는 부분이 너무 많았음.
그래서, 네트워크 흐름도를 만들었고 니네 구성이 개판이라 발생한 것이고 그걸 까기 위한 내용을 공유 한다.

1. OpenShift 네트워크 흐름도

실제 데이터 요청은 아래와 같은 흐름을 통해 전달 된다.

@ruo91
ruo91 / ocp4-ingress-controller-access-log.md
Last active July 17, 2022 09:35
OpenShift v4.x - Ingress Controller 접근 로그(access log) 설정

OpenShift 환경에서 Ingress Controller에 Access Log를 설정하는 방법에 대해서 정리한다.

1. 개요

Kubernetes 환경에서 Ingress Controller의 주 역할은 내부/외부에서
Application Pod 접근에 사용되는 Software L4, L7 기능을 담당한다고 보면 된다.

OpenShift의 경우 HAProxy 기반으로 제공되는 Router Pod가 이 역할을 담당하고 있으며,
OpenShift v4.x 버전부터는 Ingress Controller Operator라는 이름으로 CRD(Custom Resource Definition)에서 제공하는
기능으로만 제어가 가능하도록 변경 되었다.

@ruo91
ruo91 / gentoo-enable-audio-hp-elite-dragonfly-max.md
Last active June 12, 2022 14:51
Gentoo Linux - Enable Audio on HP Elite Dragonfly Max

Gentoo Linux - Enable Audio on HP Elite Dragonfly Max

HP Elite Dragonfly Max 노트북에 Gentoo Linux 설치 이후 지문인식과 마이크가 안되던 문제가 해결됐다.

1. 마이크 지원 (Microphone)

HP 노트북에서 지원하는 내장 사운드 장치는 Realtek ALC285 사용한다.
이 장치를 사용하기 위해서는 linux kernel 단에서 사용되는 HDA 모듈을 활성화 해야한다.
이와 관련 된 Realtek High Definition Audio 모듈 변수는 SND_HDA_CODEC_REALTEK을 사용한다.

이 변수를 사용하면 기본적으로 Realtek Codec을 통해서 사운드 출력을 지원 해주고

@ruo91
ruo91 / ocp4-etcd-backup-restore.md
Created June 7, 2022 05:07
OpenShift v4.x - ETCD 백업 및 복구 방법

OpenShift v4.x - ETCD 백업 및 복구 방법

본 글은 OpenShift 환경에서 클러스터가 정상적이지 않거나 사용자에 의해
object resource가 손상되었을 경우를 대비해 백업 및 복구하는 방법에 대해서 작성 되었다.

1. ETCD 백업

etcd는 kubernetes에서 사용되는 모든 정보들이 저장되어 있는 key/value 기반의 database 이다.
etcd 백업은 크게 2가지 방법으로 수행이 가능하다.

1.1. 스크립트 백업

OpenShift에서 Control Plane(Master Nodes)에서만 제공되는 "cluster-backup.sh" 스크립트를 통해 가능하다.

@ruo91
ruo91 / ocp4-aws-permission-for-iam-user.json
Created June 5, 2021 05:58
OpenShift v4x - Required AWS permissions for the IAM user
/*
- RefURL
https://docs.openshift.com/container-platform/4.7/installing/installing_aws/installing-aws-account.html#installation-aws-permissions_installing-aws-account
- Required EC2 permissions for installation
file: ocp4-ec2-permissions.json
*/
{
"Version": "2012-10-17",
"Statement": [