본문 바로가기

HANA/System Administration

SAP HANA DB Log Volume Full

728x90

SAP HANA Log Volumes

Each log volume contains the file logsegment__directory.dat and one or more log segment files (logsegment__.dat). Currently only one log partition is supported for each service, so the default file names are logsegment_000_directory.dat and logsegment_000_00000000.dat, logsegment_000_00000001.dat, logsegment_000_00000002.dat and so on. Log segment files are cyclically overwritten depending on the log mode. The log mode determines how logs are backed up. Log volumes only grow if there are no more segment files available for overwriting. Log segment files that are available for overwriting have been backed up and are not required for a database restart. If necessary you can remove these files to free up space in your file system by executing the SQL statement ALTER SYSTEM RECLAIM LOG. Note that new log segment files will need to be created later and this will affect performance. You can monitor disk usage in SAP HANA cockpit using the Disk Usage and Performance Monitor apps. In SAP HANA studio you can monitor disk usage, volume size, and other disk activity statistics on the Volumes tab of the Administration editor. See Monitoring Disk Space and Monitoring in SAP HANA Cockpit for details.

< SAP HANA Administration Guide >

 

SAP HANA Log 볼륨은 logsegment_<partition_ID>_directory.dat 파일과 하나 이상의 로그가 포함되어 있습니다. 기본적으로 logsegment_<patition_ID>_<segment_number>.dat 파일이 하나 생성되며 이후 ~00000001.dat , ~00000002.dat 로 생성됩니다.

더 이상 덮어쓸 수 있는 세그먼트 파일이 없을 경우 log segment는 자동으로 늘어나게 됩니다. log mode가 nomal 으로 설정하고 로그 백업을 진행하지 못하였을 경우가 대표적이며 over write 모드이더라도 대량의 로그를 한번에 발생시킬 경우도 발생합니다.

 

장애 발생 조치

Solution 1 . 로그 공간의 디스크를 증설하여 여유 공간을 확보합니다.

 

Solution 2. 평상시에 로그 공간에 dumy 파일 1G를 3~개를 만들어 사용하고, 장애 발생 시 해당 파일을 지워서 여유 공간을 확보합니다. ( 가장 추천하는 방법 )

 

Solutioni 3. 현재의 로그 공간 확보가 어렵다면 다른 공간에 공간을 확보하고 심볼릭 링크를 연결하고 기존 파일들을 이동합니다.

SymbolicLink

728x90