Bosh release of OMS Agent
Shell
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.final_builds
config
docs/omsview
jobs/omsagent
manifests
packages/omsagent
releases/oms-agent-for-linux
src
.gitignore
LICENSE
README.md

README.md

oms-agent-for-linux BOSH release

This release provides an OMS Agent job for sending VM operational data (Syslog, Performance, Alerts, Inventory) to Azure OMS Log Analytics.

Prerequisites

Create an OMS Workspace in Azure

Get started

To deploy the OMS agent, you will need to install BOSH CLI on your Ops Manager Director and target it. For how to setup it, please follow the document here.

1. Upload release

To use this bosh release, first upload it to your BOSH Director:

# BOSH CLI v1
bosh upload release https://github.com/Azure/oms-agent-for-linux-boshrelease/releases/download/v1.4.2-125/oms-agent-for-linux-1.4.2-125.tgz

# BOSH CLI v2
bosh2 upload-release https://github.com/Azure/oms-agent-for-linux-boshrelease/releases/download/v1.4.2-125/oms-agent-for-linux-1.4.2-125.tgz

2. Deploy as a BOSH addon

To deploy OMS Agent on all instances in your CloudFoundry deployment, specify the job as an addon in runtime config.

First, create a new file runtime.yml and paste all the following content into it.

# runtime.yml
---
releases:
- name: oms-agent-for-linux
  version: 1.4.2-125
addons:
- name: omsagent
  jobs:
  - name: omsagent
    release: oms-agent-for-linux
  exclude:
    stemcell:
    - os: windows2012R2
  properties:
    # Get the OMS workspace ID and key from OMS Portal
    oms:
      workspace_id: CHANGE_ME
      workspace_key: CHANGE_ME
    # Set the rsyslog config as needed, optional
    rsyslog:
      selector_list:
      - user.*
      - syslog.*
      port: 25224
      protocol_type: udp

After replace placeholders in the file with id and key of your OMS workspace, deploy the runtime config with the following commands.

# BOSH CLI v1
bosh update runtime-config runtime.yml
bosh deploy

# BOSH CLI v2
bosh update-runtime-config runtime.yml
bosh deploy

Tips

  • Recreate VMs when deploy then runtime-config will help to avoid potential problems.
  • DO NOT specify the job as part of your deployment manifest if you are using the runtime config.
  • If no rsyslog config is specified, the default rsyslog config of OMS Agent will be used.
  • Try delete leading spaces and input them by yourself if error Incorrect YAML structure occurs when updating runtime-config with runtime.yml copied from above.

View in OMS Portal

Import OMS View

Operators can use OMS portal to visualize the logs and metrics collected by OMS Agent. From the main OMS Overview page, go to View Designer -> Import -> Browse, select the Syslog and Perf.omsview file, and save the view. Now a Tile will be displayed on the main OMS Overview page. Click the Tile, it shows visualized metrics.

Operators can customize the view or create new views through View Designer.

Additional reference

To collect metrics and logs from the Loggregator Firehose to OMS Log Analytics, please refer to oms-log-analytics-firehose-nozzle.