Configure monitor input for the Splunk Add-on for Squid Proxy
You need to configure the Splunk platform to monitor the access log file generated by the Squid Proxy server. You can use either Splunk Web to create the monitor input or configure inputs.conf
directly.
Configure Monitoring through Splunk Web
Configure a file monitoring input on your data collection node for the Squid Proxy server access.log
file.
- Log into Splunk Web.
- Select Settings > Data inputs > Files & directories.
- Click New.
- Click Browse next to File or Directory.
- Navigate to the
access.log
file generated by the Squid Proxy server and click Next. The default location foraccess.log
is/usr/local/squid/var/logs/access.log
. - Next to Source type, click Select to select the source type definition provided in the add-on.
- Click Select Source Type and select Network & Security.
- Enter the sourcetype based on the logformat configured in your Squid environment.
- If you configured the default squid logformat, type
squid:access
. - If you configured Splunk's recommended custom format
splunk_recommended_squid
logformat, typesquid:access:recommended
.
- If you configured the default squid logformat, type
- Click Review.
- After you review the information, click Submit.
Configure inputs.conf
You can create an inputs.conf
file and configure the monitor input in this file instead of using Splunk Web.
1. Using a text editor, create a file named inputs.conf
in the $SPLUNK_HOME/etc/apps/Splunk_TA_squid/local
folder.
2. Add the following stanza and lines, replacing <path>
with the actual path to access.log
depending on the logformat configured in your squid environment, and save the file.
- If you configured the default
squid
logformat, add the following stanza:
[monitor://<path>] sourcetype=squid:access disabled = 0
- If you configured Splunk's recommended custom format splunk_recommended_squid logformat, add the following stanza:
[monitor://<path>] sourcetype=squid:access:recommended disabled = 0
Note: The default location of access.log
is /usr/local/squid/var/logs/access.log
.
3. Restart the Splunk platform for the new input to take effect.
Validate data collection
After you configure monitoring, run this search to check that you are ingesting the data that you expect.
sourcetype=squid:access*
Configure Squid Proxy access log | Troubleshoot the Splunk Add-on for Squid Proxy |
This documentation applies to the following versions of Splunk® Supported Add-ons: released
Feedback submitted, thanks!