Linux 14

tip : disk full

1. finding big-size folders (많은 용량을 차지하고 있는 폴더 찾기) sudo du -cm --max-depth=1 /home/nutanix/ | sort -n 여기서 /home/nutanix/data 폴더가 많은 용량을 차지하고 있을 경우 sudo du -cm --max-depth=1 /home/nutanix/data/ | sort -n 2. /home/nutanix/data 폴더 내에서 10MB 이상 크기의 파일 찾기 sudo find /home/nutanix/data -xdev -size +10M -printf ‘%k %M %n %u %g %TY-%Tm-%Td %TH:%TM:%TS %p\n’ | sort -nr -k 1,1

IT/linux 2022.06.10

creating over 2TB partition on linux

- fdisk : msdos partition 사용, 최대 2TB의 파티션, 최대 4TB까지의 디스크만 사용 가능 - 이 이상의 대용량 사용을 위해서는 GPT Partition을 사용해야 함 1. check GPT enabled (GPT 사용 가능 여부 확인) # cat /boot/config-3.10.0–327.el7.x86_64 | grep EFI CONFIG_EFI_PARTITION=y CONFIG_EFI=y CONFIG_FB_EFI=y CONFIG_EFI_VARS=y 위 4개가 “y”로 enable 되어 있어야 함 2. allocating disks and check them using ‘fdisk’ (1) 용량 확인 # fdisk -l Disk /dev/sdb: 2254.9 GB, 2254857..

IT/linux 2022.06.10

alternatives 설정 (java 설치 후 기존 버전 선택 시)

Java 1.7 설치 후 1.8 설치하면 기본이 1.8로 설정되고 1.7 사용이 불가능해짐 alternatives 설정으로 기본 버전을 관리할 수 있음 Java의 경우 java, javac 두 자기 그룹 설정이 있음 (jre --java, jdk --javac) 1. 사용법 # alternatives --help 사용법: alternatives --install [ --initscript ] [ --slave ]* alternatives --remove alternatives --auto alternatives --config alternatives --display alternatives --set alternatives --list 2. Java 설정 # alternatives --config jav..

IT/linux 2022.06.10

CentOS 6에 JBoss, NGINX 설치 및 기본 연동

1. ftp 설치 - 패키지 설치 # yum list vsftpd # yum install vsftpd # yum install ftp - ftp config 설정 # vi /etc/vsftpd/vsftpd.conf anonymous_enable=NO local_umask=022 dirmessage_enable=YES - root login enable 설정 # vi ftpusers #root --> comment out # vi user_list #root --> comment out - 서비스 재가동 및 reboot 후 자동 실행 # service vsftpd restart # chkconfig vsftpd on # chkconfig --list | grep vsftpd vsftpd 0:off 1:o..

IT/linux 2015.09.12

RedHat에서 CentOS로 yum repository 변경하기

출처 : http://yoga82.tistory.com/90 레드햇 Enterprise 6 의 yum repository를 셋팅한다 /etc/yum.conf 에 추가한다 [base] name=CentOS-$releasever - Base baseurl=http://ftp.daum.net/centos/6/os/$basearch/ gpgcheck=1 gpgkey=http://ftp.daum.net/centos/RPM-GPG-KEY-CentOS-6 [updates] name=CentOS-$releasever - Updates baseurl=http://ftp.daum.net/centos/6/updates/$basearch gpgcheck=1 gpgkey=http://ftp.daum.net/centos/RPM-..

IT/linux 2015.08.20

login.def 와 chage 사용법

1. 신규 사용자의 암호 사용 기간 설정 - /etc/login.defs 파일 변경 PASS_MAX_DAYS 99999 PASS_MIN_DAYS 0 PASS_MIN_LEN 8 PASS_WARN_AGE 10 2. 기존 사용자의 암호 사용 설정 변경 - chage root@ubuntu:~# chage Usage: chage [options] LOGIN Options: -d, --lastday LAST_DAY set date of last password change to LAST_DAY -E, --expiredate EXPIRE_DATE set account expiration date to EXPIRE_DATE -h, --help display this help message and exit -I, --i..

IT/linux 2015.04.07