Linux sinfo 5.4.0-135-generic #152-Ubuntu SMP Wed Nov 23 20:19:22 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
1.1
1. swap(2,048) -> 10,000
2. /boot(100) -> 2,000
3. /(3,072) -> 12,000
4. /usr(8,192) -> 70,000
5. /usr2(90,000)-> 90,000
6. /var(4,096) -> 12,000
7. /tmp(4,096) -> 12,000
8. /data(70,000)-> 70,000
9. /home(2,000) -> 2,000
10. /web(나머지 부분을 할당, 체크)
2.1
sudo passwd root
3.2
userdel sinfo
groupadd other
useradd -d /usr2/sinfo -s /bin/bash -g other -m sinfo
passwd sinfo
4.1
$apt install telnetd -y
$systemctl status inetd
5.1
$apt-get install vsftpd
$systemctl restart vsftpd
$vi /etc/vsftpd.conf
/*------------------------------------
listen=NO
listen_ipv6=YES
anonymous_enable=NO
local_enable=YES
chroot_local_user=YES
allow_writeable_chroot=YES
local_root=/data/ftp/files
write_enable=YES
local_umask=022
dirmessage_enable=YES
userlist_enable=YES
userlist_file=/etc/vsftpd.userlist
userlist_deny=NO
------------------------------------*/
/*------------------------------------
write_enable=YES
write_enable=YES
write_enable=YES
write_enable=YES
------------------------------------*/
$systemctl restart vsftpd
6.1
$gcc --version
$apt update
$apt install build-essential
7. 원하는 버전의 gcc 설치
$apt -y install gcc-7 g++-7 gcc-8 g++-8 gcc-9 g++-9
8. gcc default 설정 (명령어 뒤 700, 800, 900은 임의 숫자 적용)
$update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 700
$update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-7 700
$update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 800
$update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 800
$update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 900
$update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-9 900
9. default 설정 확인 및 변경
$update-alternatives --config gcc
$update-alternatives --config g++
root@sinfo:~# update-alternatives --config gcc
There are 3 choices for the alternative gcc (providing /usr/bin/gcc).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/gcc-9 900 auto mode
1 /usr/bin/gcc-7 700 manual mode
2 /usr/bin/gcc-8 800 manual mode
3 /usr/bin/gcc-9 900 manual mode
Press <enter> to keep the current choice[*], or type selection number: 1
update-alternatives: using /usr/bin/gcc-7 to provide /usr/bin/gcc (gcc) in manual mode
root@sinfo:~# update-alternatives --config g++
There are 3 choices for the alternative g++ (providing /usr/bin/g++).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/g++-9 900 auto mode
1 /usr/bin/g++-7 700 manual mode
2 /usr/bin/g++-8 800 manual mode
3 /usr/bin/g++-9 900 manual mode
Press <enter> to keep the current choice[*], or type selection number: 1
update-alternatives: using /usr/bin/g++-7 to provide /usr/bin/g++ (g++) in manual mode
10.
source ~/.bash_profile
source ~/.bashrc
'리눅스 > Ubuntu 18.04.5 LTS' 카테고리의 다른 글
[sed] 파일내의 STANDBY -> ACTIVE 로 변경,ㅡㅡ,ㅡㅡ (0) | 2023.01.05 |
---|---|
우분투 NTP 시간 동기화 설정/우분투 NTP 시간 동기화 설정/우분투 NTP 시간 동기화 설정 (0) | 2022.12.31 |
update-alternatives --config g++ (0) | 2022.11.06 |
ubuntu alias command(create & delete) (0) | 2022.02.19 |
.bashrc 와 .bash_profile 의 차이 (0) | 2022.01.20 |