System/Linux 7

[Error] Job for sshd.service failed because the control process exited with error code. See "sysyemctl status sshd.service" and "journalctl -xe" for details.

😱 Error / 문제점 ssh 포트 번호 변경을 한 후 아래의 명령어를 사용하니까 에러메시지가 떴다. systemctl restart sshd Job for sshd.service failed because the control process exited with error code. See "sysyemctl status sshd.service" and "journalctl -xe" for details. 🔍 이유 및 해결방법 selinux가 active 되어 있어서 발생한 것이다. 1. selinux Permissive로 전환 및 확인 setenforce 0 getenforce 2. selinux를 disabled로 설정 vi /etc/sysconfig/selinux 3. systemctl rest..

System/Linux 2023.06.20

yum 을 이용해서 ssh 설정 및 ssh 포트 변경하기

⚙️ ssh 설치 확인 # which sshd /usr/sbin/sshd ⚙️ ssh 설정 # vi /etc/ssh/sshd_config Port 22 (주석 제거) ⚙️ 방화벽 설정 # firewall-cmd --zome=public --add-port=22/tcp --permanent success ⚙️ ssh 프로세스 실행 # systemctl start sshd # systemctl status sshd ⚙️ ssh 포트 변경 # vi /etc/ssh/sshd_config Port 2222 # vi /etc/services ssh 2222/tcp ssh 2222/udp services 파일은 건들면 안된다! * 작업하는 중에 아래와 같이 표시가 된적이 있는데 놔두면 계속 나타나기 때문에 지워준다...

System/Linux 2023.06.20

[Linux] yum repository 를 설정해서 yum 사용되게 설정하기

yum repository 확인 $ yum repolist yum repository 설정 위치 $ cd /etc/yum.repos.d/ $ ls CentOS-Base.repo yum repository 설정 $ vi CentOS-Base.repo SK브로드밴드, KT, LG 유플러스의 DNS, nameserver 설정 DNS (Domain Name System) 1. BIND 패키지 2. DNS 설정 파일 3. named 데몬 4. 방화벽 오픈 5. Chroot 구성 (설정, named-chroot 데몬) 6. 도메인 등록 현재 CentOs에 설정되어 있는 DNS 서버는 하나다. 이 서버를 이용할 수 없는 상황을 대비해 SK 브로드 밴드, KT, LG 유플러스 SK 브로드밴드 219.250.36.130..

System/Linux 2023.06.20

[Linux] root 전환 / 계정 생성 / 디렉터리 및 파일 / 압축 / history

터미널 실행: 마우스 우클릭 후 Open in Terminal 클릭 Q1. test0523 계정을 생성하고, /home에 있는 test0523 폴더 안에 test0523.txt 파일에 Hello 써서 저장 # 루트 계정 전환 su root # 계정 생성 useradd test0523 cd /home # 디렉토리 생성 및 이동 mkdir /home/test0523 cd /home/test0523 # 디렉토리 확인 pwd # 파일 생성 및 확인 echo "Hello" > test0523.txt cat test0523.txt Q2. /home/test0523 폴더를 /mnt 폴더 밑에 복사 mnt: 파일 시스템을 임시로 연결하는 디렉터리 # cp [옵션] [원본 파일] [옮길 파일] cp -r test0523..

System/Linux 2023.05.23

VirtualBox에 Linux CentOS 7 설치 및 초기 설정하기

⚙️ Cent OS 설치 1. https://www.centos.org/ 2. CentOs 또는 Download 3. x86_64 4. 아무거나 선택해도 된다. 5. CentOS-7-x86_64-DVD-2207-02.iso 다운로드 ⚙️ 가상 머신 만들기 1. 메모리 크기: 2048MB 2. 지금 새 가상 하드 디스크 만들기(C) 3. VDI (VirtualBox 디스크 이미지) 4. 동적 할당 5. 많이 준다고 실제로 생기는 게 아니니까 200.00GB ⚙️ 설정 1. [저장소] - [우측 CD 모양] - 다운로드한 iso파일 선택 2. [시스템] - [플로피 디스크] 선택 해제 3. 프로세서 2개 4. [네트워크] - [어댑터에 브리지] ⚙️ CentOS 시작 1. Install CentOS 7 선택..

System/Linux 2023.04.27

[Error] Mac(M1, M2)에서 VirtualBox 설치하기

😱 Error 요즘 homebrew로 간편하게 설치할 수 있는 것에 빠져있는 도중에 error를 만났다. brew install --cask virtualbox Error: Cask virtualbox depends on hardware architecture being one of [{:type=>:intel, :bits=>64}], but you are running {:type=>:arm, :bits=>64}. 🔍 이유 VirtualBox는 Mac의 경우 인텔 CPU(x86_64)에서만 작동한다. 애플 실리콘(M1, M2,...)은 사용 불가능하다. 그래서 나는 다운로드할 수가 없다. ㅠㅠ #20192 (Virtual Machine does not start on M1 Mac) – Oracle VM..

System/Linux 2023.04.26