[개발이야기#102] 스팀잇 검색엔진 유지보수 작업 일지 001
안녕하세요 가야태자 @talkit 입니다.
오늘은 출근이 예약 되어 있어서 미리 글을 작성 합니다.
음 마리아DB를 담당하는 서버의 하드 디스크가 일단 80%정도를 사용했습니다.
그래서 지난 번에 엘라스틱 서치 처럼 1TB 하드디스크를 할당하려고 하니다. ^^
저기 보이는 data라는 폴더에 용량을 더해 주려고 합니다.
그런데 사실을 먼저 이야기 하면 더해주는 것은 조금 어렵습니다.
그래서 다른 디스크를 추가하고 그 디스크에 data라는 폴더에 마운트하고 기존 data의 내용을 복사할 계획입니다.
data디스크가 약 21GB를 사용하고 있습니다. ^^
46G였는데 나머지는 리눅스 OS에 설치된 프로그램일 것 같습니다.
일단 오늘은 vmware상에 디스크를 붙여서 재부팅 해 두었습니다.
그것만 확인하고 자고 다음주에 실제 디스크는 붙여 보겠습니다.
오늘 밤을 새야 해서 일단 자려고 합니다. ㅎㅎㅎ
위와 같이 디스크가 잘 붙어 있습니다.
제가 사용하려고 하는 디스크는 /dev/sdb 입니다. ^^
sudo fdisk /dev/sdb
하드디스크에 포맷을 하기 전에 파티션을 나눠 주겠습니다.
그냥 편하게 1TB를 넣어 줄 계획입니다.
sudo fdisk /dev/sdb
Welcome to fdisk (util-linux 2.39.3).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Device does not contain a recognized partition table.
Created a new DOS (MBR) disklabel with disk identifier 0xf34c772e.
Command (m for help): p
Disk /dev/sdb: 1 TiB, 1099511627776 bytes, 2147483648 sectors
Disk model: VMware Virtual S
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xf34c772e
Command (m for help): n
Partition type
p primary (0 primary, 0 extended, 4 free)
e extended (container for logical partitions)
Select (default p): p
Partition number (1-4, default 1): 1
First sector (2048-2147483647, default 2048):
Last sector, +/-sectors or +/-size{K,M,G,T,P} (2048-2147483647, default 2147483647):
Created a new partition 1 of type 'Linux' and of size 1024 GiB.
Command (m for help): w
The partition table has been altered.
Calling ioctl() to re-read partition table.
Syncing disks.
디스크는 만들어 졌습니다.
포맷을 해보겠습니다.
sudo mkfs.ext4
sudo mkfs.ext4 /dev/sdb1
mke2fs 1.47.0 (5-Feb-2023)
Creating filesystem with 268435200 4k blocks and 67108864 inodes
Filesystem UUID: efc02436-9445-4173-9d5a-b170ed760a2a
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848
Allocating group tables: done
Writing inode tables: done
Creating journal (262144 blocks): done
Writing superblocks and filesystem accounting information: done
위와 같이 포맷도 완료 되었습니다.
mkdir data2
일단 오늘은 data2에 마운트하고 용량만 보겠습니다.
sudo mount /dev/sdb1 data2
df -h
파일 시스템 크기 사용 가용 사용% 마운트위치
tmpfs 1.7G 2.1M 1.7G 1% /run
/dev/sda2 59G 46G 11G 82% /
tmpfs 8.4G 0 8.4G 0% /dev/shm
tmpfs 5.0M 8.0K 5.0M 1% /run/lock
tmpfs 1.7G 92K 1.7G 1% /run/user/120
tmpfs 1.7G 80K 1.7G 1% /run/user/1000
/dev/sdb1 1007G 28K 956G 1% /home/talkit/mariadb/data2
디스크는 넉넉히 준비 되었습니다.
야근 모드가 끝나늗 대로 data2에 data를 옮기는 과정을 보여 드리겠습니다.
감사합니다.
검색엔진 주소
http://search.whd.kr:5000/advanced
Posted through the ECblog app (https://blog.etain.club)





가즈아~~~~!!
[booming-kr-auto]
@booming-kr이 보팅드렸습니다 🙌
(보팅받는 기준: 50% 이상 또는 65,000 Mrshares 이상으로 보팅)
요즘 파이썬 코드를 많이 봤더니 저 암호같은글자가 뭔지 1%정도는 감이오네요. ㅋㅋ
[booming-kr-auto]
@booming-kr이 보팅드렸습니다 🙌
(보팅받는 기준: 50% 이상 또는 65,000 Mrshares 이상으로 보팅)
Upvoted! Thank you for supporting witness @jswit.