Reputation: 10753
Is there a simple way to log message greater than 2048 char using syslog? e.g raw response of a curl request.
// msg is a string > 2048 char. This truncates message to 2048 chars
syslog(LOG_DEBUG, msg);
Upvotes: 4
Views: 1653
Reputation: 574
The 2K limit might come from rsyslog, too (it's the default limit). You should be able to change it with something like:
$MaxMessageSize 10k
And put it somewhere at the beginning of the config:
Centralized rsyslog : max size of message
Upvotes: 4