Processing math: 100%
kubernetes reset 하기
Software활용 2021. 3. 7. 00:41

k8s를 사용하다보면 여러가지 사유로 끊기거나 service가 잘 시작 안될때가 있다. 이때는 kubeadm reset 명령어를 통해서 새롭게 시작할 수 있다. 아래 로그를 보면 node가 이미 클러스터에 등록된 것으로 확인 된다. 이 오류를 해결하기 위해서 reset을 통해 초기화 시키고 node를 클러스터에 등록하는 것을 확인 할 수 있다. ubuntu@node:~$ kubeadm join 192.168.241.92:6443 --token cn1jrh.nmkfl966puecshrz \ > --discovery-token-ca-cert-hash sha256:9bb6bcec1f1649d04908fa2987ec7d918de0a939df247cb5eb5fb25fe6349c05 [preflight] Runni..

kubernetes install on ubuntus with Hyper-V
Software활용 2021. 3. 4. 23:07

쿠버네티스를 Hyper-V를 사용해서 install 하고 1개의 master 그리고 2개의 node를 구성하는 환경을 만들어 보고자 한다. releases.ubuntu.com/20.10/ 여기에서 Desktop 환경은 불필요 해서 Server live를 선택 하였다. Hyper-V를 윈도우에서 enable하고 가상컴퓨터를 만들어 보자. 라고 하고 싶은데, 시간이 많이 걸리꺼 같아서 이부분은 google을 통해서 setup 완료 했다고 생각하고 진행 하겠다. 가상 컴퓨터 만들기 메모리는 2기가 이상이 무조건 있어야 한다. 기본 spec 범위이다. 더 필요 하면 나중에 추가 할 수 있다. default를 연결함으로써 인터넷을 바로 사용하게 하자 용량이 많이 필요 하지 않음으로 20G 3개의 가상컴퓨터를 만들..

Kubernetes Deployments No resources
Software활용 2021. 3. 1. 23:04

Kubernetes를 사용하는데 시키는데로 해도 안되는 경우가 있다. 가령 kubernetes.io/ko/docs/tutorials/hello-minikube/ Hello Minikube 이 튜토리얼에서는 Minikube와 Katacoda를 이용하여 쿠버네티스에서 샘플 애플리케이션을 어떻게 실행하는지 살펴본다. Katacode는 무료로 브라우저에서 쿠버네티스 환경을 제공한다. 참고: 로컬에서 kubernetes.io 에 따라서 기본 이미지를 실행 시켜도 deployments가 조회가 안되는 경우 같은거다. $ kubectl get deployments No resources found in default namespace. 이런 경우인데 namespace를 쿠버네티스에서 변경해 줘야 한다. kubectl..

ssh key를 이용한 github 접근
Software활용 2021. 3. 1. 15:11

github를 접근할 때 매번 패스워드를 사용하기 싫을 경우 아래와 같이 ssh key를 미리 등록 해 놓는 방법이 있다. (.pia-aws) ec2-user:~/environment/DevOps_Microservices (main) $ ssh-keygen -t rsa Generating public/private rsa key pair. 해당 명령어를 실행 하면 아래와 같이 특정 디렉토리에 ssh 키가 만들어진다. Enter file in which to save the key (/home/ec2-user/.ssh/id_rsa): Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has ..

Git branch 분리하기
Software활용 2021. 3. 1. 14:58

해결하고자 하는 것 하나의 프로젝트가 너무 크면 sub project 단위로 다시 분리 하고 싶을 때가 있다. 해결 방법 다음과 같이 git filter-branch를 사용하면 된다. 만약 Master Branch에 5개의 폴더가 있고 그중 3번째 폴더만 별도 git으로 뺀다고 생각해 보겠다. (.pia-aws) ec2-user:~/environment/DevOps_Microservices (master) $ git filter-branch --prune-empty --subdirectory-filter ./Lesson-3-Containerization/ master Rewrite 1d5fe1ddf5c5c07c4b1cf9df4eb532c01e0cb5bf (1/1) (0 seconds passed, rem..

tomcat install on centos
Software활용 2020. 3. 27. 16:38

tomca install 처리 하는 내용이지만 별 내용이 없어서... pass [root@localhost webapp]# yum list tomcat* Loaded plugins: fastestmirror, langpacks Loading mirror speeds from cached hostfile * base: centos.mirror.moack.net * extras: centos.mirror.moack.net * updates: centos.mirror.moack.net Installed Packages tomcat.noarch 7.0.76-9.el7_6 @updates tomcat-admin-webapps.noarch 7.0.76-9.el7_6 @updates tomcat-el-2.2-api...

Redis Config Explain
Software활용 2020. 3. 27. 16:38

Redis Config Section redis-cli를 통해서 redis console에 진입 할 경우 info명령어를 통해서 다음 section에 대한 정보를 획득 할 수있다. info server : 기본 정보 clients : client의 접속 정보 memory : 메모리 사용 관련 정보 persistence : RDB와 AOF(Append Only File) 관련 정보 AOF의 경우는 appendonly.aof 파일에 입력/수정/삭제 실행 명령 실행시 마다 기록 (조회 제외) Redis 서버 작동시 FLUSHALL명령을 사용한 경우 해당 파일을 이용해서 DB를 재 구축 할 수 있음 http://redisgate.kr/redis/configuration/persistence.php RDB의 경우..

Postgresql 11 installation on Centos7
Software활용 2020. 3. 27. 16:37

https://www.postgresql.org/download/linux/redhat/ Select version : 11 Select Platform : Redhat Enterprise Select Archtecture : x86_64 yum install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm yum install postgresql11 yum install postgresql11-server default db install /usr/pgsql-11/bin/postgresql-11-setup initdb change access control [root@l..

Pgmodeler install
Software활용 2020. 3. 27. 16:37

stevenui-MacBookPro:pgmodeler stevengit https://github.com/pgmodeler/pgmodeler.git git: 'https://github.com/pgmodeler/pgmodeler.git' is not a git command. See 'git --help'. stevenui-MacBookPro:pgmodeler steven git clone https://github.com/pgmodeler/pgmodeler.git Cloning into 'pgmodeler'... remote: Enumerating objects: 295, done. remote: Counting objects: 100% (295/295)..