Ubuntu

Install APM On Ubuntu

1. 개요 Ubuntu에 APM을 설치한다. 설치 순서 : Apache, MySQL, PHP 8.2   2. Install APM 1) Install Apache httpd # Install apache web server apt-get install -y apache2 # Set ownership chown -R www-data.www-data /var/www/html # config file /etc/apache2/apache2.conf # Data Directory /var/www # App Directory /usr/lib/apache2   2) MySQL 설치 # Install mysql […]

Continue Reading
Linux 공통 Raspbian Ubuntu

remove python2

1. Intro Delete python 2 (Default installed)   2. Command # check python2 version python –version # Delete python2 sudo apt purge python2.x-minimal # Install pip3 sudo apt install python3-pip # link python2 -> python3 sudo ln -s /usr/bin/python3 /usr/bin/python sudo ln -s /usr/bin/pip3 /usr/bin/pip # check python version python –version    

Continue Reading
Ubuntu

Clean unuse kernel

1. Intro If you have an old kernel that you are not using, you should delete it. Because it fill up the /boot capacity.   2. How to do? 2.1. check kernel # current kernel uname -a # list kernel sudo dpkg –list | grep linux-image 2.2. Delete old kernel sudo apt purge linux-image-[version]   […]

Continue Reading
Raspbian Ubuntu

Ubuntu SSH OTP

1. Intro I want to configure OTP to use SSH connection to Ubuntu server.   2. Setup 2.1. install google OTP sudo apt install libpam-google-authenticator 2.2. setup pam.d, sshd config # pam.d 맨 위에 추가시 Login ID → OTP code → PW 맨 아래 추가시 Login ID → PW → OTP code nullok : otp […]

Continue Reading
Ubuntu

Set up ip on Ubuntu 18

1. intro Since Ubuntu 18 LTS, ip configuration has changed to netplan.   2. How to set up? a. check interface ls /sys/class/net b. set ip sudo vi /etc/netplan/50-cloud-init.yaml network: ethernets: eth0: addresses: [IP/Subnet] gateway4: Gateway nameservers: addresses: [DNS IP1, DNS IP2] dhcp4: no version: 2 c. apply sudo netplan apply d. show ip ip […]

Continue Reading
Ubuntu

apt update 오류시

1. Intro Ubuntu에서 apt update시 Hash 오류가 나는 경우   2. Command sudo rm -rf /var/lib/apt/lists/* sudo apt-get update -o Acquire::CompressionTypes::Order::=gz sudo apt-get update && sudo apt-get upgrade  

Continue Reading
Ubuntu

phpmyadmin 접속 ip 설정

1. 개요 phpmyadmin은 mysql을 php를 통해 웹 상에서 제어할 수 있는 툴이다. 그런데 phpmyadmin의 외부 접속이 허용될 경우 악의적인 사용자에 의해 DB 무결성이 깨질 수 있으므로 특정 IP 또는 내부 IP만 허용하는 것이 좋다.   2.설정 방법 vi /etc/phpmyadmin/apache.conf <Directory /usr/share/phpmyadmin> Options FollowSymLinks DirectoryIndex index.php # ADD Allow, Deny IP Order deny,allow Deny from all […]

Continue Reading
Ubuntu

history timestamp

1. 개요 history에 명령어를 실행한 시간 남기기 작업 내역 분석시 용이   2. 명령어 vi /etc/profile HISTTIMEFORMAT=”[%F %T] ” HISTSIZE=10000 export HISTTIMEFORMAT source /etc/profile   3. 결과 화면  

Continue Reading
Back To Top