날짜: 03-29-2023 04:50 PM
시스템 메모리는 장비의 중요한 component 로서 장비 운영 중 메모리 할당이 증가되고 메모리 누수로 서비스 임팩이 발생할 수 있기에 주기적인 점검이 필요 됩니다.
해당 문서에서는 Catalyst 9K 시리즈의 메모리 health 상태 확인과 트러블 슈팅 방법을 소개하도록 하겠습니다.
본 문서에서는 17.x 버전 위주로 common 버그 리스트를 공유 드립니다.
아래와 같이 DRAM 메모리 사용 율을 확인하실 수 있습니다.
#show platform resources
**State Acronym: H - Healthy, W - Warning, C - Critical
Resource Usage Max Warning Critical State
----------------------------------------------------------------------------------------------------
Control Processor 1.08% 100% 90% 95% H
DRAM 3606MB(47%) 7575MB 85% 90% H <<<
TMPFS 1001MB(13%) 7575MB 40% 50% H
설명:
DRAM(Dynamic Random Access Memory)은 모든 플랫폼에서 제한된 리소스이며 사용율을 확인하기 위해 제어하거나 모니터링해야 합니다.
#show memory statistics
Tracekey : 1#7d349a90369f7b51ceb9a1dcd01c5069
Head Total(b) Used(b) Free(b) Lowest(b) Largest(b)
Processor 7FCC86AD7048 1363095804 313870268 1049225536 1046673580 1048039920 <<<
reserve P 7FCC86AD70A0 102404 92 102312 102312 102312
lsmpi_io 7FCC84A2A1A8 6295128 6294304 824 824 412
IOSd를 실행 하기 위한 풀이고 각 프로세스가 메모리를 할당 받는 풀 입니다.
Processor 풀의 메모리가 고갈되면 기기의 메인 프로세스(Exec, TTY 등)이reserve P 풀의 메모리 영역을 이용하게 됩니다.
lsmpi_io Pool은 forwarding processor에서 route processor로 패킷을 전달하는 데 사용됩니다.
lsmpi_io Pool은 장비가 Boot up 될 때 일정하게 할당되고 장비 기동 후에 이용되는 양은 일정하게 유지하기에 여유 메모리가 적어 보여도 특별히 걱정하실 필요는 없습니다.
daily로 각 프로세스의 holding된 값을 확인합니다.
#show process memory sorted
Processor Pool Total: 1363095804 Used: 313907616 Free: 1049188188
reserve P Pool Total: 102404 Used: 88 Free: 102316
lsmpi_io Pool Total: 6295128 Used: 6294296 Free: 832
PID TTY Allocated Freed Holding Getbufs Retbufs Process
0 0 297122824 50011752 227281600 0 0 *Init*
4 0 25327048 1547176 22525256 0 0 RF Slave Main Th
83 0 33509720 3121096 17166088 0 0 IOSD ipc task
0 0 343987824 331028264 7609768 24110359 1233588 *Dead*
502 0 4362208 280032 4124120 849828 0 EEM ED Syslog
148 0 12131929656 12093379000 2103944 0 0 SAMsgThread
523 0 2059512 158960 1931064 0 0 EEM Server
(참고: 만약 *Init* 프로세가2~3G 좌우의 메모리가 홀딩이 되고 장비 리부팅으로도 메모리 release 안되는 경우가 있습니다.이럴 경우 ‘logging buffered’ 설정 확인이 필요합니다. ‘logging buffered’ 사이즈가 클수록 *Init* 프로세스가 더 많이 홀딩 될 수 있습니다.)
------------------ show running-config ------------------
logging buffered 2147483647 <<<
Cisco IOS XE 시스템에서 실행 중인 단일 프로세스에 대한 시스템 메모리 사용량을 표시합니다.
#show processes memory platform sorted
System memory: 7757628K total, 3701252K used, 4056376K free,
Lowest: 4051560K
Pid Text Data Stack Dynamic RSS Name
----------------------------------------------------------------------
14595 241685 897512 136 400 897512 linux_iosd-imag
13993 191 255584 136 90736 255584 fed main event
28117 285 216388 136 3980 216388 dbm
29239 82 180416 136 3480 180416 pubd
22193 175 162716 136 6096 162716 sessmgrd
linux_iosd-imag – IOSd
fed main event – FED
sessmgrd – SMD
fman_rp – Forwarding Manager
위 카운트에서 주로 RSS 값을 확인 합니다.RSS(Resident Set Size)는 각 프로세스의 메모리 사용량을 표시하는데 VSZ (Virtual Set Size) 로 표시됩니다. Rss 값을 daily로 모니터링 하고 어느 프로세스에서 rss 값이 계속 증가되는지 확인합니다. 계속 증가될 경우 해당 프로세스가memory leak에 해당 될 가능성이 높습니다.
Cisco IOS XE 시스템에서 실행 중인 단일 프로세스가 캐시된 메모리를 확인합니다.
# show platform software process list switch active R0 sort memory (9200/9300/9500)
# show platform software process list r0 sort memory (9400/9600)
Name Pid PPid Group Id Status Priority Size
------------------------------------------------------------------------------
linux_iosd-imag 14595 14422 14595 S 20 896808
fed main event 13993 12716 13993 S 20 253192
dbm 28117 27866 28117 S 20 216384
pubd 29239 28948 29239 S 20 180204
sessmgrd 22193 21212 22193 S 20 162348
CSCvn30230 Catalyst 3k/9k: Slow memory leak in linux_iosd-imag https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvn30230 Fixed version:16.3.9 16.6.7 16.9.4 16.12.1 … |
CSCvv33873 Crimson Database Memory Leak In “/tmp/rp/tdldb/0/IOS_PRIV_OPER_DB" Due to "platform_property_value" https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvv33873 Fixed version: 16.12.6 17.3.4 17.4.1 …
|
CSCvv16874 Catalyst Switch: SISF Crash due to a memory leak Fixed version: 16.12.5, 17.3.2 and 17.4.1 ... |
CSCvw17512 %CRIMSON-3-DATABASE_MEMLEAK: Database memory leak detected in /tmp/rp/tdldb/0/IOS_PRIV_OPER_DB https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvw17512 Fixed version: 17.5.1 17.6.1 17.7.1 … |
CSCvx70044 Memory leak in Crimson Databse in the tbl_platform_properties_record https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvx70044 Fixed version: 17.3.6 17.6.1 17.7.1 … |
CSCvx94276 %CRIMSON-3-DATABASE_MEMLEAK: Database memory leak detected in /tmp/rp/tdldb/0/IOS_PRIV_OPER_DB https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvx94276 Fix on 17.3.5 17.6.1 17.7.1 ... |
CSCwb25610 IPv6: Switch may reload due to a memory allocation error by SISF (CSCwb86091— duplicate of CSCwb25610) https://bst.cloudapps.cisco.com/bugsearch/bug/CSCwb25610 Fixed version: 17.3.6 17.6.4, 17.9.1 |
(참고: linux_iosd-imag 즉 iosd 쪽 메모리가 증가될 경우 ‘show processes memory platform detailed name iosd smaps’ 코만드를 daily로 수집하고 rss를 비교함으로 어떤 db에서 계속 증가되는지 확인 가능합니다.)
#show processes memory platform detailed name iosd smaps
smaps for process 12772:
address perms offset dev inode pathname
6080000000-6080671000 rw-s 00000000 00:29 77260 /tmp/rp/tdldb/0/IOS_CONF_DB
Size: 6596 kB
KernelPageSize: 4 kB
MMUPageSize: 4 kB
Rss: 1460 kB <<<
Pss: 636 kB
Shared_Clean: 0 kB
CSCvx91242 Crash due to memory leak under "sessmgrd" process https://bst.cloudapps.cisco.com/bugsearch/bug/CSCvx91242 Fixed version: 17.3.4, 17.6.1 17.7.1 …
|
상단의 검색창에 키워드, 문구, 또는 질문을 입력하여 궁금한 내용을 찾아보세요.
이곳에서의 여러분의 여정이 훌륭하기를 바랍니다! 시스코 커뮤니티에 빠르게 익숙해지는 데 도움이 되는 몇 가지 링크를 준비했습니다.