Messages logged by a router can make troubleshooting problems substantially easier. However, the default size of most Cisco routers is 4096 bytes which typically accommodates fewer than 60 messages. While this may help in many situations, adding some additional space can save the day when a router generates frequent error messages as when an interface state cycles up and down. This tech-recipe describes the simple configuration to increase the size of the router log.
To increase the router log size to 24000 bytes, use the following commands (from enable mode):
logging buffered 24000
To check the current log size, use this command:
Log Buffer (24000 bytes)
It should be noted that memory you dedicate to the log is memory the router cannot use for routing. Larger routers with lots of memory can typically make do with less available memory. Smaller routers with less memory to spare can experience problems if the log size is too big.