You can install the New Relic Nozzle for VMware Tanzu as a tile in Ops Manager, or push it as a regular application.
Change the following settings to configure the nozzle tile:
YOUR-NEW-RELIC-RPM-ACCOUNT
US
or EU
. Choose EU if your RPM URL contains .euYOUR-NEW-RELIC-INSIGHTS-INSERT-KEY
newrelic.firehose
)proxy server address:port
Under New Relic Firehose Nozzle tile > Settings > LogMessage Filters tab:
Note: include logic is processed before exclude logic. If specified, include filters will only generate New Relic events if the include filter is matched. Exclude filters will exclude matches
The following properties can be obtained either from the VMware Tanzu Application Service or from New Relic:
newrelic.firehose
)true
.ValueMetric
CounterEvent
ContainerMetric
HttpStartStop
LogMessage
https://insights.newrelic.com/accounts/RPM-ID/...
)https://insights.newrelic.com/accounts/RPM-ID/manage/api_keys
.Ops Manager -> VMware Tanzu Application Service -> Credentials -> Job -> UAA -> Opentsdb Nozzle Credentials -> Link to Credential -> identity
Ops Manager -> VMware Tanzu Application Service -> Credentials -> Job -> UAA -> Opentsdb Nozzle Credentials -> Link to Credential -> password
https://api.YOUR-PCF-DOMAIN
– cf curl /v2/info
https://uaa.YOUR-PCF-DOMAIN
– cf curl /v2/info
Ops Manager -> VMware Tanzu Application Service -> Credentials -> Job -> UAA -> Admin Credentials -> Link to Credential -> identity
Ops Manager -> VMware Tanzu Application Service -> Credentials -> Job -> UAA -> Admin Credentials -> Link to Credential -> password
To obtain the properties:
When pushing New Relic Nozzle for VMware Tanzu as an application, you must have a manifest with the following properties:
applications:
- name: newrelic-firehose-nozzle
memory: 512M
disk_quota: 256M
instances: 2
health-check-type: http
health-check-http-endpoint: /health
host: cf-firehose-nozzle-${random-word}
buildpacks:
- binary_buildpack
path: dist
command: ./nr-fh-nozzle
env:
NRF_CF_CLIENT_ID: "Ops Mgr -> Elastic Runtime -> Credentials -> Job -> UAA -> Opentsdb Nozzle Credentials -> Link to Credential -> identity"
NRF_CF_CLIENT_SECRET: "Ops Mgr -> Elastic Runtime -> Credentials -> Job -> UAA -> Opentsdb Nozzle Credentials -> Link to Credential -> password"
NRF_CF_API_UAA_URL: "run cf curl /v2/info to get the url"
NRF_CF_API_URL: "run cf curl /v2/info to get the url"
NRF_FIREHOSE_ID: newrelic.firehose
NRF_CF_SKIP_SSL: true
NRF_ENABLED_ENVELOPE_TYPES: ValueMetric,CounterEvent,LogMessage,ContainerMetric,HttpStartStop
NRF_CF_API_USERNAME: "Ops Mgr -> Elastic Runtime -> Credentials -> Job -> UAA -> Admin Credentials -> Link to Credential -> identity"
NRF_CF_API_PASSWORD: "Ops Mgr -> Elastic Runtime -> Credentials -> Job -> UAA -> Admin Credentials -> Link to Credential -> password"
NRF_NEWRELIC_ACCOUNT_ID: New Relic Account ID
NRF_NEWRELIC_INSERT_KEY: New Relic Insights Insert Key
# # Optional Settings (with their default values listed). Uncomment the setting to change.
# # New Relic account region. Choose EU if RPM URL includes .eu.
# NRF_NEWRELIC_ACCOUNT_REGION: US or EU
# # How often accumulated metric events are sent. Recommended: 29s, 59s, 89s, or 129s
# NRF_NEWRELIC_DRAIN_INTERVAL: 59s
# # Number of minutes before the HTTP connection to the RLP Gateway is considered hung and restarted. The RLP Gateway should force a new connection every 14 minutes. This is only applicable if the connection hangs.
# NRF_FIREHOSE_HTTP_TIMEOUT_MINS: 16
# # Number of consecutive seconds with no messages before the nozzle is automatically restarted. Set per environment based on normal message load.
# NRF_FIREHOSE_RESTART_THRESH_SECS: 15
# # Number of messages the nozzle buffer can hold while processing. Also the number of messages that will be dropped if the buffer fills. Recommended minimum is 6000.
# NRF_FIREHOSE_DIODE_BUFFER: 8192
# # Log level (INFO or DEBUG)
# NRF_LOG_LEVEL: INFO
# # Trace level logging (extremely verbose)
# NRF_TRACER: false
# # Send HttpStartStop envelopes to New Relic Logs
# NRF_LOGS_HTTP: false
# # Send LogMessage envelopes to New Relic Logs
# NRF_LOGS_LOGMESSAGE: false
# # LogMessage filters (| separated values)
# NRF_LOGMESSAGE_SOURCE_INCLUDE: ""
# NRF_LOGMESSAGE_SOURCE_EXCLUDE: ""
# NRF_LOGMESSAGE_MESSAGE_INCLUDE: ""
# NRF_LOGMESSAGE_MESSAGE_EXCLUDE: ""
# # if proxy used in your environment
# http_proxy: <proxy server address:port>
# no_proxy: <comma separated list of servers to bypass proxy>
Note: In order to automate the cf push
deployment process as much as possible, create an application manifest.yml
file. Update the manifest as required for your environment. Make sure to assign proper values to all required environment variables. Any property values within angle brackets must be changed to the correct values for your environment.
Note: Make sure to build the nozzle binary in dist
subdirectory (using the build command below), so that when you push the app, the source and rest of the unnecessary files/folders do not get pushed into the container.
This example creates a new client and grants the necessary UAA permissions. A default client is used when the nozzle is deployed as a tile and these steps are not necessary. The OpenTSDB Nozzle Credentials can also be retrieved and used instead of creating a custom client.
uaac target https://uaa.[your cf system domain]
uaac token client get admin -s [your admin-secret]
uaac client add firehose-to-newrelic \
--name firehose-to-newrelic \
--secret [your_client_secret] \
--authorized_grant_types client_credentials,refresh_token \
--authorities doppler.firehose,cloud_controller.admin_read_only
--scope doppler.firehose
firehose-to-newrelic
--secret
If you make any changes to the code, or would like to run on other operating systems, you can clone the code from GitHub and follow the building and deploy steps from the README file.
If you need to use a proxy server in your environment, use the following environment variables:
http_proxy
no_proxy
You can specify the values for these properties during the setup of the tile in Ops Manager. If you use the app version of the nozzle, you can set these environment variables at the end of the manifest.yml
in the env section, or set them directly by running cf set-env
.
http_proxy
to your proxy server address and port (for example, http://my_proxyserver:my_proxy_port
).no_proxy
to any address that you need to bypass. For the nozzle to work properly with proxies, you must bypass the doppler
server (doppler.YOUR-VMware Tanzu-DOMAIN.com
). Make sure not to include the protocol and the port for no_proxy
; just add the server name.