DevOps & Cloud Engineering(229)
-
error "could be both a local file and a tracking branch."
개요git checkout을 하는 과정에서 github actions이나 git cli를 사용할 때 아래와 같은 에러가 발생하는 경우상황could be both a local file and a tracking branch.원인'git checkout'을 통해 branch를 변경할 경우 명시적인 명령어 'git switch' 를 추천한다참고https://git-scm.com/docs/git-switch
2025.03.07 -
gov-ncloud Cloud DB for PostgreSQL 데이터베이스 생성 하는 방법
개요어떤 철학과 무슨 의도를 갖고 만든 건지는 모르겠지만, gov-ncloud Cloud DB for PostgreSQL에서 최초 생성된 database 말고 추가적으로 database를 생성하는 방법은 정말 찾기 힘들었다. 방법아래와 같이 DB Service 상세보기를 누르면 나온다. 스크린샷
2025.02.26 -
PostgreSQL dump & restore
개요PostgreSQL dump & restore 관련 명령어 dump & restore# sudo dnf install -y https://download.postgresql.org/pub/repos/yum/14/redhat/rhel-8-x86_64/postgresql14-14.13-1PGDG.rhel8.x86_64.rpm# psql -h -p 5432 -U user -d Password for user user: psql (14.13, server 13.15)Type "help" for help.database=> \l List of databases Name | Owner | Encoding | Coll..
2025.02.26 -
Rocky Linux 8에 PostgreSQL client 설치 및 삭제 방법
개요Rocky Linux 8에 PostgreSQL client 설치 방법 설치 및 삭제 방법## PostreSQL Repository 추가# sudo dnf install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-x86_64/pgdg-redhat-repo-latest.noarch.rpm## 설치하려는 버전의 PostreSQL Module 활성화# sudo dnf module enable postgresql:12## 설치# sudo dnf install -y postgresql## 삭제# sudo dnf remove postgresql# sudo dnf module reset postgresql## 다른 버전 Module 활성화# s..
2025.02.26 -
MySQL Dump, Restore 관련 필요한 명령어
개요MySQL을 운영할 때 필요한 작업중에는 MySQL dump 및 restore 작업이 있다. 이에 관련된 명령어를 정리해봤다. 명령어## mysql database create 확인show create database ;## mysql table create 확인show create table ;## mysql schema dump 명령어 예시mysqldump -u -h -p \ --no-data --skip-comments \ --skip-set-charset \ --skip-add-drop-table \ --skip-add-locks \ --skip-disable-keys \ --skip-triggers \ --skip-routines \ --set-gtid-purged=OF..
2025.02.26 -
object storage object url (ncloud, AWS)
개요Amazon S3와 Naver Cloud Platform(NCP) Object Storage는 객체에 접근하기 위한 두 가지 URL 형식을 제공Path-Style과 Virtual Host-Style URL 형식• Amazon S3:Path-Style URL: https://s3.{region}.amazonaws.com/{bucket-name}/{object-key} Virtual Host-Style URL: https://{bucket-name}.s3.{region}.amazonaws.com/{object-key}• Naver Cloud Platform Object Storage:Path-Style URL: https://{region}.object.ncloudstorage.com/{bucket-na..
2025.02.17 -
AWS CloudWatch Logs insights query
개요AWS CloudWatch Logs insights query를 잘 사용하면 AWS CloudWatch Logs를 잘 사용할 수 있다. 쿼리1 >> 10초 이상 RDS slow queryfields @timestamp, @message| filter @message like /Query_time:/| parse @message /Query_time: (?\d+\.\d+)/| filter queryTime > 10| sort @timestamp desc| limit 20 비고적절히 만들어진 Query는 Saved queries를 통해 저장 해 놓으면 한번에 불러와서 사용 가능하다.
2025.02.12 -
AWS Web Console account 다중 로그인
개요AWS Web Console에서 account를 1개 이상 사용할 경우 브라우저를 다르게 하거나 시크릿 모드를 통해서 해야하는 불편함이 있었는데, 최근에 다중 로그인이 기능이 출시되면서 상당히 편해지고 좋아졌습니다. (2025년 1월 16일) 방법AWS Console을 로그인 한 후 우 상단의 Account의 드롭박스에서 "Turn on multi-session support"를 활성화한 후 Session 추가를 통해 1개 이상의 Account가 다중으로 로그인된 후 Switching을 통해 관리가 가능하다. 참고https://aws.amazon.com/ko/about-aws/whats-new/2025/01/aws-management-console-simultaneous-sign-in-multiple..
2025.01.21 -
telepresence를 이용한 터널링 방법
개요k8s context로 접속하기 위해 telepresence를 통해 접근하는 방법과 client vpn 없이 AWS VPC에 접근하는 방법 설치 (OSS)https://www.telepresence.io/docs/install/client 사용방법## telepresence 기존 세션 제거# telepresence quit## telepresence 접속# telepresence connect ## 현재 k8s context에 해당하는 VPC internal routing 추가 # sudo route add $(aws ec2 describe-vpcs --region $(kubectl config current-context | awk -F':' '{print $4}') --vpc-ids $(aws e..
2025.01.17 -
ArgoCD AutoSync interval
개요ArgoCD Application에서 AutoSync 기능을 enable 하면 기본값으로 180초 주기로 확인해서 Sync를 한다. 그 값을 확인하는 방법과 변경하는 방법에 대한 정리 확인 방법kubectl get configmap argocd-cm -n argocd -o jsonpath='{.data.timeout\.reconciliation}{"\n"}' 변경 방법kubectl patch configmap argocd-cm -n argocd --type merge -p '{"data":{"timeout.reconciliation":"60s"}}' 바로 적용하는 방법Application >> Refresh 버튼을 누르면 바로 Sync가 동작한다. 참고https://github.com/argoproj..
2024.12.31