YUMSERV
[MongoDB] Percona-toolkit 설치
LINUX/DB 2023. 1. 29. 17:36

https://docs.percona.com/percona-software-repositories/installing.html Percona Software Installation - Percona Software Repositories Installation on Debian and Ubuntu LinuxInstallation on Red Hat Enterprise Linux and compatible derivatives If you are running a DEB-based distribution, such as Debian or Ubuntu Linux, use the apt package manager to install the percona-release official pack docs.per..

article thumbnail
GSLB란
LINUX/DNS 2022. 12. 5. 07:49

1. GSLB란 Global Server Load Balancing 일반적으로 dns 서비스는 표준 DNS에 질의를 할 경우, DNS 서버는 로컬 데이터베이스의 IP 목록을 확인해서 그 중 하나를 반환 할 뿐, 네트워크 지연, 성능, 트래픽 유입, 서비스 실패 등은 전혀 고려하지 않는다. GSLB는 이러한 문제를 해결하기 위해 나온것이며, health check와 active/backup을 지정 가능하게 하여 재해 복구(DR), 지역적인 부하분산, 응답시간 중심의 서비스를 제공 가능하게 할 수 있습니다. 2. GSLB와 DNS와의 차이 1) 재해복구 기본적으로 dns는 서버의 상태를 확인할 수 없습니다. 서비스를 실패하는 유저가 생길 수 있습니다. GSLB는 서버의 상태를 모니터링하며, 실패한 서버는 I..

[MySQL] Mysql8 Audit 로그 설정
LINUX/DB 2022. 11. 25. 16:47

Audit 로그 (감사로그) Audit 로그는 보안 기능중에 하나로, DB에서 누가, 어떤 쿼리를 날렸는지 확인 할 수 있게, 로그 형태로 남기는 것을 말합니다. 1. AUDIT 로그 설치 * 환경 : Mysql 8.0.29 Percona 사이트에서 자신의 맞는 버전에 따라 다운로드 받습니다. https://www.percona.com/downloads/Percona-Server-LATEST/# Download Percona Server for MySQL 8.0 Software: -- Select Software Platform -- Debian GNU/Linux 10.0 ("buster")Debian GNU/Linux 11.0 ("bullseye")Linux - GenericRed Hat Enterpr..

[Nginx] Can't locate nginx.pm in @INC
LINUX/WEB 2022. 11. 12. 12:59

nginx 설치 오류 에러 : Can't locate nginx.pm in @INC perl_parse() failed: 2 Nov 9 10:26:17 localhost nginx: Starting nginx: Can't locate nginx.pm in @INC (@INC contains: /usr/loc al/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64 /perl5 /usr/share/perl5 .). Nov 9 10:26:17 localhost nginx: BEGIN failed--compilation aborted. Nov 9 10:26:17 localhos..

article thumbnail
[AWS-RDS] MYSQL you *might* want to use the less safe log_bin_trust_function_creators variable
LINUX/DB 2022. 10. 24. 21:39

RDS 내에서 함수(function)를 쓰려니, 아래와 같은 에러가 발생하였습니다. ERROR 1418: This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA in its declaration and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable) 권한을 확인해보니, 현재 모든 권한이 존재하고 있었습니다. SHOW GRANTS FOR 'test_user'@'%'; Grants for test_user@% GRANT USAGE ON *.* TO 'test'@'%' GRANT ALL PRIVILEGES..

article thumbnail
PM2 - nodejs 실행
LINUX 2022. 9. 4. 22:48

0. PM2란 nodejs 프로세스 매니져 기본적으로 nodejs는 싱글스레드입니다. nodejs 애플리케이션은 단일 CPU코어에서 실행되기 때문에 CPU 멀티코어 시스템은 사용할 수 없습니다. 클러스터 모듈을 통해 단일 프로세스를 멀티 프로세스(Worker)로 늘릴 수 있는 방법을 제공합니다. 개발자분들은 이 클러스터 모듈을 사용해서 마스터 프로세스에서 CPU 코어 수 만큼 워커 프로세스를 생성해서 모든 코어를 사용하게끔 개발하면 됩니다. PM2 공식 사이트 : https://pm2.keymetrics.io/ PM2 - Home Advanced process manager for production Node.js applications. Load balancer, logs facility, startu..

[MSSQL] (Backup, Restore) Database 진행률 확인 쿼리
LINUX/DB 2022. 8. 30. 20:16

BACKUP DATABASE 진행률 확인 쿼리 SELECT session_id as SPID, command, a.text AS Query, start_time, percent_complete, DATEADD(second,estimated_completion_time/1000, GETDATE()) AS estimated_completion_time FROM sys.dm_exec_requests r CROSS APPLY sys.dm_exec_sql_text(r.sql_handle) a WHERE r.command = 'BACKUP DATABASE' RESTORE Database 진행률 확인 쿼리 SELECT session_id as SPID, command, a.text AS Query, start_tim..

SSL 인증서 관련 내용 정리
LINUX/WEB 2022. 8. 19. 08:17

* 필요한 내용은 계속 추가할 예정입니다. 1. 인증서 타입별 매칭 확인법 생성한 CSR, KEY와 발급 받은 인증서(CRT)의 쌍이 맞는지 확인하는 방법 [CSR] openssl req -in test_co_kr.csr -modulus -noout | openssl md5 [KEY] openssl rsa -in test_co_kr.key -modulus -noout | openssl md5 [CRT] openssl x509 -in test_co_kr.crt -modulus -noout | openssl md5 같은 MD5 값을 가질 경우 한쌍(사용가능) 2. crt, key 인증서 파일 pem으로 변환 # key 변경 openssl rsa -in server.key -text > private.pem ..

article thumbnail
[MSSQL] 제일 많은 빈도수 쿼리 조회 스크립트
LINUX/DB 2022. 7. 19. 20:11

원래는 MSSQL PROFILER 를 이용해서 모니터링 하면서 조회할 수 있지만, 부하를 일으킬 수 있어, 문제가 된다. 쿼리를 이용해서 제일 많은 빈도수 쿼리를 조회할 수 있습니다. select top 10 db_name(st.dbid) as dbname, cp.objtype, qs.total_elapsed_time, creation_time, last_execution_time, qs.execution_count, text from sys.dm_exec_query_stats qs cross apply sys.dm_exec_sql_text(qs.plan_handle)st join sys.dm_exec_cached_plans cp on qs.plan_handle = cp.plan_handle where ..

[Tomcat] org.apache.catalina.LifecycleException: Protocol handler start failed
LINUX/WEB 2022. 5. 25. 17:57

13-Jan-2022 14:37:35.458 SEVERE [main] org.apache.catalina.core.StandardService.startInternal Failed to start connector [Connector[AJP/1.3-8009]] org.apache.catalina.LifecycleException: Protocol handler start failed at org.apache.catalina.connector.Connector.startInternal(Connector.java:1101) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.Stan..