Linux 488

jenkins install centos 8

centos8 환경에서 설치. JAVA 설치 # dnf install java-1.8.0-openjdk-devel Jenkins Repo 생성 # vi /etc/yum.repos.d/jenkins.repo [jenkins] name=Jenkins-stable baseurl=http://pkg.jenkins.io/redhat-stable gpgcheck=1 저장 Jenkins Key 저장 # rpm --import https://pkg.jenkins.io/redhat/jenkins.io.key Jenkins 설치 # dnf install jenkins 만약에 특정 버전을 설치를 해야 한다면 yum install jenkins-2.263.4 이런식으로 하면 된다. 서비스 시작 # systemctl start..

Linux 2022.03.14

/usr/bin/ld: cannot find -lm /usr/bin/ld: cannot find -lc

/usr/bin/ld: cannot find -lm /usr/bin/ld: cannot find -lc collect2: error: ld returned 1 exit status 컴파일 할때 위와 같이 에러가 발생을 한다면 # yum install glibc-static libstdc++-static -y 설치 하면 된다. 이렇게 설치 했는대도 동일한 에러가 발생 된다면 컴파일 환경이 32bit 로 만들어 진것이다. 32bit 패키지 설치 해주면 된다. # yum install glibc-static.i686 libstdc++-static.i686 -y

Linux 2022.03.11

centos 9 stream repository, epel repository

centos 9 stream 은 rrepository 정식 사이트는 아직 없는듯 하다. 찾은건 중국사이트 ... [baseos] name=CentOS Stream $releasever - BaseOS #metalink=https://mirrors.centos.org/metalink?repo=centos-baseos-$stream&arch=$basearch&protocol=https,http baseurl=https://mirrors.tuna.tsinghua.edu.cn/centos-stream/9-stream/BaseOS/$basearch/os/ gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial gpgcheck=1 repo_gpgcheck=0 meta..

Linux 2022.02.14

프로세스 체크 후 구동 스크립트

# vi servicechek.sh #/bin/sh program=programsname check=`ps -ef | grep $program | wc | awk '{print $1}'` if [ $check -gt 1 ] then echo "$program RUNNING" else echo "$program service restart" service $program restart fi 실행 권한을 주고 # chmod 777 servicecheck.sh 5분에 한번씩 체크 하게 설정 # crontab -e */5 * * * * /home/sc/servicecheck.sh 구동확인 vi /var/log/cron Jan 10 14:15:01 test CROND[5956]: (root) CMD (/home/..

Linux 2022.01.10

google otp 메일 발송 스크립트

스크립트를 잘 하지 못하니.. 대충 나만의 방식으로 작성 우선 구글 otp 생성 관련 명령은 google-authenticator -t -d --label TEST_Sever --issuer $USER -r 3 -R 30 -s ~/.google_authenticator 이걸 스크립트로 짜서 해당 경로에 데이터가 있는지 확인하는걸 만들면 google-auth-check.sh 로 만든다. #!/bin/bash if [ ! -f ~/.google_authenticator ]; then printf 'y\ny\n' | google-authenticator -t -d --label TEST_Sever --issuer $USER -r 3 -R 30 -s ~/.google_authenticator fi 자 이제 추가..

Linux 2021.12.22

apache2 httpd 응답페이지 변경하기

page not found 이렇게 출력 되는 부분을 변경을 하고 싶다면 apache2.conf 나 httpd.conf 를 아래와 같이 수정 해주면 된다. ErrorDocument 500 /index.html ErrorDocument 500 /index.html ErrorDocument 500 /index.html ErrorDocument 404 /index.html ErrorDocument 401 /index.html ErrorDocument 403 /index.html 아파치 재시작 해주면 index.html 이나 내가 보여주고 싶은 페이지를 설정 하면 해당 페이지로 가진다.

Linux 2021.10.26
728x90