Introduction
VMware Aria Operations for Logs is a part of the VMware Cloud suite of services. Use this service to develop sophisticated analytics that aid in rapid troubleshooting of your SDDC or VMware Cloud on AWS environment..
As part of the VMware Cloud suite of services, VMware Aria Operations for Logs (formerly known as vRealize Log Insight Cloud) provides a fully managed and integrated log analytics and troubleshooting service.
VMware Aria Operations for Logs includes VMware-authored SDDC (ESXi, VC, NSX, and VSAN) insight for troubleshooting, a flexible and comprehensive query facility that supports troubleshooting for novice and experienced administrators, built-in SDDC and custom alerting capability, flexible notification mechanisms, and centralized support for local or federated authentication.
TASKS
- From your VDI Desktop, open the browser and log into your VMC on AWS SDDC
https://vmc.vmware.com/console/sddcs- Username: vmcexpert#[email protected]
- Password: VMware1!
- On your SDDC Tile Click View Details
- Select Open NSX Manager (next to Open vCenter)
- Select the blue box Access Via the Internet
- Click the Security Tab
- Modify the Distributed Firewall
- Click Add Policy
- Name the Policy Class Log Test
- Check the box next to the policy you created, Add Rule is now available
- Select Add Rule
- Name the Rule Allow All HTML
- Under Sources click the pencil, select RFC1918, click Apply
- Under Destination click the pencil, select RFC1918, click Apply
- Under Services click the pencil, filter for http, select HTTP and HTTPS, click Apply
- Under Actions leave Allow selected, the rule should be enabled by default
- Publish the DFW rule by clicking the blue Publish button
- Select the Gear in the far right side of the Allow All HTML rule
- Move the slider next to logging to enable logging
- Set the Log Label to vmcexpert#-##_Test (using your Student ID)
- Click Apply
- Click Publish
- Click Open vCenter from the SDDC Console
- Click Show Credentials
- Copy the Password and Click Open vCenter
- Log into vCenter as:
- [email protected]
- {Paste in the copied Password}
- In vCenter, Click the frontend VM and record its IP address
- Select the Ubuntu-DT VM and click Open Console
- Enter the Password of VMware1! if prompted
- Launch the Firefox browser in the Ubunt-DT VM and type in {the address of your Frontend VM} for the Cats & Dogs Application
- Click the Gato & Cachorro buttons multiple times until the image that appears is a hedgehog.
- When this image (hedgehog) appears an error is generated and logged with log-insight and captured by vRealize Operations. You are also performing this step to generate some firewall logs
- In a new Browser tab, go to VMware.com and one or more public websites
- Click the stacked squares in the upper right-hand corner
- Right-Click VMware Aria Operations for Logs
- Click Open link in new tab
- If Collapsed, Click the double arrows to expand the left pane
- Expand the Configuration Section
- Click Subscriptions
- Notice we are using the PERPETUAL Subscription. This subscription comes with VMC on AWS and only allows you to view Audit logs and Firewall Logs.
To view other types of logs (Application logs, non-SDDC logs, etc..) the subscription must be upgraded.
- Click Dashboards to view the available dashboards
- In the Search Bar, type Gateway Firewall
- Select Gateway Firewall - Traffic (latest version)
- Review the Pie Graphs for Top Sources and Top Destinations
You'll see an aggregated and processed view of all network traffic leaving the SDDC in the past 5 mins. - In the Upper right corner note that you can increase the time scale to review date beyond the last 5 mins
All NSX related log events must first be enabled before those log messages will be sent to Log Insight. E.G. If you want to see DHCP, NAT or VPN related log messages then you must enable logging for those services as we did in task 1 for our firewall rule.
- Select Dashboards in the left column
- Click on All Dashboards:
- Select NSX-T events for VMware Cloud SDDC v6.0
- Select Distributed Firewall - Traffic
- Observe the traffic, you may have to change the time window by selecting 30M or 1H to see relevant data
- From the left hand navigation pane, select Home
- In the search bar, type vmcexpert* to see traffic that has PASSed the DFW rule. You may need to change the time period to 30M or 1H.
- HINT: Use your full student account name (vmcexpert#-##) to see events for your SDDC only.
- Return to the VMware Cloud on AWS SDDC console tab in your browser, ensuring that you are in your SDDC
- Select Networking & Security
- Select Distributed Firewall under Security
- Open the Class Log Test policy to see the Allow All HTML rule
- Change Allow to Reject under Action
- Publish the rule change
- Return to the Ubuntu Desktop Console window, relaunch from vCenter if it has timed out.
- Open Firefox and connect to your FrontEnd VM IP address recorded earlier making sure to use http.
- This should result in an immediate unable to connect message
- If the DFW rule had been set to DROP, you would have to wait for the http timeout to see the failed message
- From the Firefox web browser access vmware.com, try google.com. That access isn't blocked by the DFW.
- Return to your open Aria Operations for Logs browser tab, or start a new Aria Operations for Logs session if closed
- From the left hand navigation pane, select Home
- In the search bar, type vmcexpert* to see traffic that has been REJECTed by the DFW rule. You may need to change the time period to 30M or 1H.
- HINT: Use your full student account name (vmcexpert#-##) to see events for your SDDC only.
- From the Aria Operations for Logs navigation pane, select Dashboards
- Click the All Dashboards drop down
- Select NSX-T events for VMware Cloud SDDC V6.0
- Select Distributed Firewall - Traffic
- Observe Application Ports Denied, there should be entries from the REJECT rule. You might need to adjust the time band to 30M or 1H
- When finished, return to the SDDC console, updating the DFW setting back to ALLOW from REJECT and PUBLISH the rule.
- You can Verify that the DFW is set correctly by accessing the Cats & Dogs app from your Ubuntu Desktop
- Click Alerts in the left hand navigation pane
- Click Alert --> Alert Definitions to review the built-in alerts
- In the search bar type vcenter and hit return to see the Alert definitions
- Select the Audit Events for VMware Cloud SDDC | User Session Login Alert
- Review the settings and notice there is currently no notification set when this alert is triggered, the rule is also disabled by default.
- In the upper right hand, click the edit Icon, close any warning for partitions if present.
- Under Trigger Condition 1, click Choose Notification and Input Your Email address in the notify field, then click the +
- Move the slider to enable the alert
- Click Save
- If logged into vCenter, logout. Login to your vCenter server. You should receive both user and application login notifications.
- After verifying incoming email notifications, Disable the alert by moving the slider, edit the alert and remove your email address by clicking the 'x' and then Save.
Note: You can also create custom alerts.
- In the left pane, click Content Packs to review the available content packs for Log Insight Cloud
- Notice that not all content packs are enabled. Enabling a content pack allows Log Insight to begin processing log messages for the system
- If Disabled, Enable the content packs for:
- Audit Events for VMware Cloud SDDC (v2)
- General
- Select Public, then Applications
- NOTE: You may need to clear the search bar in order to see the desired results
- Enable Apache - HTTP Server and Nginx
- Select Others
- Enable the Linux and Linux - Systemd Content Packs, if not already enabled
- Click on Dashboards. In the search bar type the name of one of the content packs you enabled (Linux, Nginx etc). You'll now notice additional dashboards (Activity, Alerts, etc...)
- In the log Insight cloud interface expand Configuration
- Click Cloud Proxy
If there are any existing inactive Proxies, click Delete and confirm the deletion to remove them - Click ADD Proxy
- Click Existing
- Select the Aria Automation Proxy you deployed earlier
- Click Add
- In the left pane under the Configuration section, click Operations for Log Agents
- Under Agent Configuration clink New next to File Logs, add configuration settings for the following. Note: hit Save as you complete each section.
- MongoDB
- Directory: /var/log/mongodb
- include files: *.log
- syslog
- Directory: /var/log
- Include files: *.log
- docker
- Directory: /var/lib/docker/containers
- Include files: *.log
- MongoDB
- At the top of the page, in the Agents search field, click the drop-down and select Create New Group
- Name the Group Linux_XX (Linux_01) matching your student number
- Click OK
- Configure the Group as follows:
- Filter
- OS
- Starts with
- Ubuntu*
- Filter
- Under the Agent Configuration section add the following configuration settings:
- Under General Click New, and add the general section logging
- Set the logging level to verbose
- Click Save
- Under Common Click New, and add the section global
- Click Save
- Under General Click New, and add the general section logging
- In the Agent Configuration section, Under Parsers, Let's create and define 4 parsers:
- Next to Parsers Click New, name the section syslog_appname_parser
- Set the Parser to use/extend to CLF (default Common Log Format)
- Set Format to:
- Next to Parsers Click New, name the section syslog_appname_parser
<p>%{appname}i[%{thread_id}i]</p>
Click Save
- Next to Parsers Click New, name the section syslog_parser
- Set the Parser to use/extend to CLF (default Common Log Format)
- Decode Field click Add
- set the field to appname
- set the value to syslog_appname_parser
- Set Format to:
<p>%t %i %{appname}i: %M</p>
Click Save
- Next to Parsers Click New, name the section auth_Parser_sles
- Set the Parser to use/extend to CLF (default Common Log Format)
- Set Next Parser to syslog_parser
- Set Format to:
- Set the Parser to use/extend to CLF (default Common Log Format)
<p>%t %i %{appname}i[%{thread_id}i]: password changed - account=%{linux_user}i, uid=%{uid}i, %i</p>
Click Save
- Net to Parsers Click New, name the section auth_Parser
- Set the Parser to use/extend to CLF (default Common Log Format)
- Set Next Parser to syslog_parser
- Set Format to:
- Set the Parser to use/extend to CLF (default Common Log Format)
<p>%t %i %{appname}i[%{thread_id}i]: password changed - account=%{linux_user}i, uid=%{uid}i, %i</p>
Click Save
- In the Agent Configuration section, Under File Logs, Let's create and define 4 log configurations:
- Next to File Log Click New, name the section auth
- Set the Directory to: /var/log
- Set Include files to: auth.log;auth.log.?
- Tag Field click New Tag
- set the field to vmc_cp
- set the value to linux
- Set Parse fields by to: auth_parser
- Next to File Log Click New, name the section auth
Click Save
- Next to File Log Click New, name the section messages
- Set the Directory to: /var/log
- Set Include files to: messages;messages.?
- Tag Field click New Tag
- set the field to vmc_cp
- set the value to linux
- Set Parse fields by to: syslog_parser
Click Save
- Next to File Log Click New, name the section syslog
- Set the Directory to: /var/log
- Set Include files to: syslog;syslog.?
- Tag Field click New Tag
- set the field to vmc_cp
- set the value to linux
- Set Parse fields by to: syslog_parser
Click Save
- Next to File Log Click New, name the section docker
- Set the Directory to: /var/log
- Set Include files to: docker
- Tag Field click New Tag
- set the field to vmc_cp
- set the value to linux
- Set Parse fields by to: syslog_parser
Click Save
- At the top of the VMware Aria Operations for Logs Agents page choose All Agents in the search field
You should now see the agents from your Cats & Dog application, there would also be more than 10 events recorded. Click on the Status field to sort by Active if you see multiple Disconnected agents.
Return to the Aria Operations for Logs Explore Logs and observe a change in the data stream. You can adjust the time band as necessary, 5M - 30M - 1H etc.
0 Comments
Add your comment