Merge branch 'master' into repo_sync_working_branch

This commit is contained in:
Gary Moore
2021-01-04 15:49:57 -08:00
committed by GitHub
6 changed files with 185 additions and 27 deletions

View File

@ -302,6 +302,7 @@
##### [Troubleshoot installation issues](microsoft-defender-atp/linux-support-install.md) ##### [Troubleshoot installation issues](microsoft-defender-atp/linux-support-install.md)
##### [Troubleshoot cloud connectivity issues](microsoft-defender-atp/linux-support-connectivity.md) ##### [Troubleshoot cloud connectivity issues](microsoft-defender-atp/linux-support-connectivity.md)
##### [Troubleshoot performance issues](microsoft-defender-atp/linux-support-perf.md) ##### [Troubleshoot performance issues](microsoft-defender-atp/linux-support-perf.md)
##### [Troubleshoot missing events issues](microsoft-defender-atp/linux-support-events.md)
#### [Privacy](microsoft-defender-atp/linux-privacy.md) #### [Privacy](microsoft-defender-atp/linux-privacy.md)

View File

@ -49,7 +49,7 @@ You can assign users with one of the following levels of permissions:
> [!NOTE] > [!NOTE]
> You need to run the PowerShell cmdlets in an elevated command-line. > You need to run the PowerShell cmdlets in an elevated command-line.
- Connect to your Azure Active Directory. For more information, see, [Connect-MsolService](https://docs.microsoft.com/powershell/module/msonline/connect-msolservice?view=azureadps-1.0). - Connect to your Azure Active Directory. For more information, see [Connect-MsolService](https://docs.microsoft.com/powershell/module/msonline/connect-msolservice?view=azureadps-1.0).
**Full access** <br> **Full access** <br>
Users with full access can log in, view all system information and resolve alerts, submit files for deep analysis, and download the onboarding package. Users with full access can log in, view all system information and resolve alerts, submit files for deep analysis, and download the onboarding package.

View File

@ -24,7 +24,6 @@ ms.topic: conceptual
[!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)] [!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)]
**Applies to:** **Applies to:**
- [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md) - [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md)
@ -37,8 +36,29 @@ To test if Defender for Endpoint for Linux can communicate to the cloud with the
mdatp connectivity test mdatp connectivity test
``` ```
expected output:
```output
Testing connection with https://cdn.x.cp.wd.microsoft.com/ping ... [OK]
Testing connection with https://eu-cdn.x.cp.wd.microsoft.com/ping ... [OK]
Testing connection with https://wu-cdn.x.cp.wd.microsoft.com/ping ... [OK]
Testing connection with https://x.cp.wd.microsoft.com/api/report ... [OK]
Testing connection with https://winatp-gw-cus.microsoft.com/test ... [OK]
Testing connection with https://winatp-gw-eus.microsoft.com/test ... [OK]
Testing connection with https://winatp-gw-weu.microsoft.com/test ... [OK]
Testing connection with https://winatp-gw-neu.microsoft.com/test ... [OK]
Testing connection with https://winatp-gw-ukw.microsoft.com/test ... [OK]
Testing connection with https://winatp-gw-uks.microsoft.com/test ... [OK]
Testing connection with https://eu-v20.events.data.microsoft.com/ping ... [OK]
Testing connection with https://us-v20.events.data.microsoft.com/ping ... [OK]
Testing connection with https://uk-v20.events.data.microsoft.com/ping ... [OK]
Testing connection with https://v20.events.data.microsoft.com/ping ... [OK]
```
If the connectivity test fails, check if the device has Internet access and if [any of the endpoints required by the product](microsoft-defender-atp-linux.md#network-connections) are blocked by a proxy or firewall. If the connectivity test fails, check if the device has Internet access and if [any of the endpoints required by the product](microsoft-defender-atp-linux.md#network-connections) are blocked by a proxy or firewall.
Failures with curl error 35 or 60, indicate certificate pinning rejection. Please check if the connection is under SSL or HTTPS inspection. If so, add Microsoft Defender for Endpoint to the allow list.
## Troubleshooting steps for environments without proxy or with transparent proxy ## Troubleshooting steps for environments without proxy or with transparent proxy
To test that a connection is not blocked in an environment without a proxy or with a transparent proxy, run the following command in the terminal: To test that a connection is not blocked in an environment without a proxy or with a transparent proxy, run the following command in the terminal:

View File

@ -0,0 +1,94 @@
---
title: Troubleshoot missing events or alerts issues for Microsoft Defender ATP for Linux
description: Troubleshoot missing events or alerts issues in Microsoft Defender ATP for Linux.
keywords: microsoft, defender, atp, linux, events
search.product: eADQiWindows 10XVcnh
search.appverid: met150
ms.prod: w10
ms.mktglfcycl: deploy
ms.sitesec: library
ms.pagetype: security
ms.author: dansimp
author: dansimp
ms.localizationpriority: medium
manager: dansimp
audience: ITPro
mms.collection:
- m365-security-compliance
- m365initiative-defender-endpoint
ms.topic: conceptual
---
# Troubleshoot missing events or alerts issues for Microsoft Defender for Endpoint for Linux
[!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)]
**Applies to:**
- [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md)
This article provides some general steps to mitigate missing events or alerts in the [security center](https://securitycenter.windows.com/) portal.
Once Microsoft Defender for Endpoint has been installed properly on a device, a device page will be generated in the portal and _File_, _Process_, _Network_ and other events should appear in the timeline and advanced hunting pages.
In case events are not appearing or some types of events are missing, that could indicate some problem.
## Missing network and login events
Microsoft Defender for Endpoint utilized `audit` framework from linux to track network and login activity.
1. Make sure audit framework is working.
```bash
service auditd status
```
expected output:
```output
● auditd.service - Security Auditing Service
Loaded: loaded (/usr/lib/systemd/system/auditd.service; enabled; vendor preset: enabled)
Active: active (running) since Mon 2020-12-21 10:48:02 IST; 2 weeks 0 days ago
Docs: man:auditd(8)
https://github.com/linux-audit/audit-documentation
Process: 16689 ExecStartPost=/sbin/augenrules --load (code=exited, status=1/FAILURE)
Process: 16665 ExecStart=/sbin/auditd (code=exited, status=0/SUCCESS)
Main PID: 16666 (auditd)
Tasks: 25
CGroup: /system.slice/auditd.service
├─16666 /sbin/auditd
├─16668 /sbin/audispd
├─16670 /usr/sbin/sedispatch
└─16671 /opt/microsoft/mdatp/sbin/mdatp_audisp_plugin -d
```
2. If auditd is stopped, please start it.
```bash
service auditd start
```
**On SLES15** systems, SYSCALL auditing in `auditd` is disabled by default and can explain missing events.
1. To validate that SYSCALL auditing is not disabeld, list the current audit rules:
```bash
sudo auditctl -l
```
if the following line is present, please remove it or edit it to enable Microsoft Defender for Endpoint to track specific SYSCALLs.
```output
-a task, never
```
audit rules are located at `/etc/audit/rules.d/audit.rules`.
## Missing file events
File events are collected with `fanotify` framework. In case some or all file events are missing please make sure fanotify is enabled on the device and that the file system is [supported](microsoft-defender-atp-linux.md#system-requirements).
List the filesystems on the machine with:
```bash
df -Th
```

View File

@ -24,7 +24,6 @@ ms.topic: conceptual
[!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)] [!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)]
**Applies to:** **Applies to:**
- [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md) - [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md)
@ -36,9 +35,11 @@ An error in installation may or may not result in a meaningful error message by
```bash ```bash
sudo journalctl | grep 'microsoft-mdatp' > installation.log sudo journalctl | grep 'microsoft-mdatp' > installation.log
``` ```
```bash ```bash
grep 'postinstall end' installation.log grep 'postinstall end' installation.log
``` ```
```Output ```Output
microsoft-mdatp-installer[102243]: postinstall end [2020-03-26 07:04:43OURCE +0000] 102216 microsoft-mdatp-installer[102243]: postinstall end [2020-03-26 07:04:43OURCE +0000] 102216
``` ```
@ -47,6 +48,20 @@ An output from the previous command with correct date and time of installation i
Also check the [Client configuration](linux-install-manually.md#client-configuration) to verify the health of the product and detect the EICAR text file. Also check the [Client configuration](linux-install-manually.md#client-configuration) to verify the health of the product and detect the EICAR text file.
## Make sure you have the correct package
Please mind that the package you are installing is matching the host distribution and version.
| package | distribution |
|-------------------------------|------------------------------------------|
| mdatp-rhel8.Linux.x86_64.rpm | Oracle, RHEL and CentOS 8.x |
| mdatp-sles12.Linux.x86_64.rpm | SuSE Linux Enterprise Server 12.x |
| mdatp-sles15.Linux.x86_64.rpm | SuSE Linux Enterprise Server 15.x |
| mdatp.Linux.x86_64.rpm | Oracle, RHEL and CentOS 7.x |
| mdatp.Linux.x86_64.deb | Debian and Ubuntu 16.04, 18.04 and 20.04 |
For [manual deployment](linux-install-manually.md), make sure the correct distro and version had been chosen.
## Installation failed ## Installation failed
Check if the mdatp service is running: Check if the mdatp service is running:
@ -54,6 +69,7 @@ Check if the mdatp service is running:
```bash ```bash
systemctl status mdatp systemctl status mdatp
``` ```
```Output ```Output
● mdatp.service - Microsoft Defender for Endpoint ● mdatp.service - Microsoft Defender for Endpoint
Loaded: loaded (/lib/systemd/system/mdatp.service; enabled; vendor preset: enabled) Loaded: loaded (/lib/systemd/system/mdatp.service; enabled; vendor preset: enabled)
@ -69,26 +85,33 @@ systemctl status mdatp
## Steps to troubleshoot if mdatp service isn't running ## Steps to troubleshoot if mdatp service isn't running
1. Check if "mdatp" user exists: 1. Check if "mdatp" user exists:
```bash ```bash
id "mdatp" id "mdatp"
``` ```
If theres no output, run If theres no output, run
```bash ```bash
sudo useradd --system --no-create-home --user-group --shell /usr/sbin/nologin mdatp sudo useradd --system --no-create-home --user-group --shell /usr/sbin/nologin mdatp
``` ```
2. Try enabling and restarting the service using: 2. Try enabling and restarting the service using:
```bash ```bash
sudo systemctl enable mdatp sudo systemctl enable mdatp
``` ```
```bash ```bash
sudo systemctl restart mdatp sudo systemctl restart mdatp
``` ```
3. If mdatp.service isn't found upon running the previous command, run: 3. If mdatp.service isn't found upon running the previous command, run:
```bash ```bash
sudo cp /opt/microsoft/mdatp/conf/mdatp.service <systemd_path> sudo cp /opt/microsoft/mdatp/conf/mdatp.service <systemd_path>
``` ```
where ```<systemd_path>``` is where ```<systemd_path>``` is
```/lib/systemd/system``` for Ubuntu and Debian distributions and ```/lib/systemd/system``` for Ubuntu and Debian distributions and
```/usr/lib/systemd/system``` for Rhel, CentOS, Oracle and SLES. ```/usr/lib/systemd/system``` for Rhel, CentOS, Oracle and SLES.
@ -100,16 +123,21 @@ Now try restarting the mdatp service using step 2. Revert the configuration chan
5. If `/opt` directory is a symbolic link, create a bind mount for `/opt/microsoft`. 5. If `/opt` directory is a symbolic link, create a bind mount for `/opt/microsoft`.
6. Ensure that the daemon has executable permission. 6. Ensure that the daemon has executable permission.
```bash ```bash
ls -l /opt/microsoft/mdatp/sbin/wdavdaemon ls -l /opt/microsoft/mdatp/sbin/wdavdaemon
``` ```
```Output ```Output
-rwxr-xr-x 2 root root 15502160 Mar 3 04:47 /opt/microsoft/mdatp/sbin/wdavdaemon -rwxr-xr-x 2 root root 15502160 Mar 3 04:47 /opt/microsoft/mdatp/sbin/wdavdaemon
``` ```
If the daemon doesn't have executable permissions, make it executable using: If the daemon doesn't have executable permissions, make it executable using:
```bash ```bash
sudo chmod 0755 /opt/microsoft/mdatp/sbin/wdavdaemon sudo chmod 0755 /opt/microsoft/mdatp/sbin/wdavdaemon
``` ```
and retry running step 2. and retry running step 2.
7. Ensure that the file system containing wdavdaemon isn't mounted with "noexec". 7. Ensure that the file system containing wdavdaemon isn't mounted with "noexec".
@ -117,24 +145,31 @@ Now try restarting the mdatp service using step 2. Revert the configuration chan
## If mdatp service is running, but EICAR text file detection doesn't work ## If mdatp service is running, but EICAR text file detection doesn't work
1. Check the file system type using: 1. Check the file system type using:
```bash ```bash
findmnt -T <path_of_EICAR_file> findmnt -T <path_of_EICAR_file>
``` ```
Currently supported file systems for on-access activity are listed [here](microsoft-defender-atp-linux.md#system-requirements). Any files outside these file systems won't be scanned. Currently supported file systems for on-access activity are listed [here](microsoft-defender-atp-linux.md#system-requirements). Any files outside these file systems won't be scanned.
## Command-line tool “mdatp” isn't working ## Command-line tool “mdatp” isn't working
1. If running the command-line tool `mdatp` gives an error `command not found`, run the following command: 1. If running the command-line tool `mdatp` gives an error `command not found`, run the following command:
```bash ```bash
sudo ln -sf /opt/microsoft/mdatp/sbin/wdavdaemonclient /usr/bin/mdatp sudo ln -sf /opt/microsoft/mdatp/sbin/wdavdaemonclient /usr/bin/mdatp
``` ```
and try again. and try again.
If none of the above steps help, collect the diagnostic logs: If none of the above steps help, collect the diagnostic logs:
```bash ```bash
sudo mdatp diagnostic create sudo mdatp diagnostic create
``` ```
```Output ```Output
Diagnostic file created: <path to file> Diagnostic file created: <path to file>
``` ```
Path to a zip file that contains the logs will be displayed as an output. Reach out to our customer support with these logs. Path to a zip file that contains the logs will be displayed as an output. Reach out to our customer support with these logs.

View File

@ -23,7 +23,6 @@ ms.topic: conceptual
[!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)] [!INCLUDE [Microsoft 365 Defender rebranding](../../includes/microsoft-defender.md)]
**Applies to:** **Applies to:**
- [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md) - [Microsoft Defender for Endpoint for Linux](microsoft-defender-atp-linux.md)
@ -34,6 +33,8 @@ Real-time protection (RTP) is a feature of Defender for Endpoint for Linux that
Depending on the applications that you are running and your device characteristics, you may experience suboptimal performance when running Defender for Endpoint for Linux. In particular, applications or system processes that access many resources over a short timespan can lead to performance issues in Defender for Endpoint for Linux. Depending on the applications that you are running and your device characteristics, you may experience suboptimal performance when running Defender for Endpoint for Linux. In particular, applications or system processes that access many resources over a short timespan can lead to performance issues in Defender for Endpoint for Linux.
Before starting, **please make sure that other security products are not currenly running on the device**. Multilpe security products may conflict and impact the host performance.
The following steps can be used to troubleshoot and mitigate these issues: The following steps can be used to troubleshoot and mitigate these issues:
1. Disable real-time protection using one of the following methods and observe whether the performance improves. This approach helps narrow down whether Defender for Endpoint for Linux is contributing to the performance issues. 1. Disable real-time protection using one of the following methods and observe whether the performance improves. This approach helps narrow down whether Defender for Endpoint for Linux is contributing to the performance issues.
@ -43,12 +44,15 @@ The following steps can be used to troubleshoot and mitigate these issues:
```bash ```bash
mdatp config real-time-protection --value disabled mdatp config real-time-protection --value disabled
``` ```
```Output ```Output
Configuration property updated Configuration property updated
``` ```
If your device is managed by your organization, real-time protection can be disabled by your administrator using the instructions in [Set preferences for Defender for Endpoint for Linux](linux-preferences.md). If your device is managed by your organization, real-time protection can be disabled by your administrator using the instructions in [Set preferences for Defender for Endpoint for Linux](linux-preferences.md).
If the performance problem persists while real-time protection is off, the origin of the problem could be the endpoint detection and response component. In this case please contact customer support for further instructions and mitigation.
2. To find the applications that are triggering the most scans, you can use real-time statistics gathered by Defender for Endpoint for Linux. 2. To find the applications that are triggering the most scans, you can use real-time statistics gathered by Defender for Endpoint for Linux.
> [!NOTE] > [!NOTE]
@ -71,6 +75,7 @@ The following steps can be used to troubleshoot and mitigate these issues:
```bash ```bash
mdatp config real-time-protection --value enabled mdatp config real-time-protection --value enabled
``` ```
```Output ```Output
Configuration property updated Configuration property updated
``` ```
@ -80,6 +85,7 @@ The following steps can be used to troubleshoot and mitigate these issues:
```bash ```bash
mdatp diagnostic real-time-protection-statistics --output json > real_time_protection.json mdatp diagnostic real-time-protection-statistics --output json > real_time_protection.json
``` ```
> [!NOTE] > [!NOTE]
> Using ```--output json``` (note the double dash) ensures that the output format is ready for parsing. > Using ```--output json``` (note the double dash) ensures that the output format is ready for parsing.
@ -90,6 +96,7 @@ The following steps can be used to troubleshoot and mitigate these issues:
```bash ```bash
wget -c https://raw.githubusercontent.com/microsoft/mdatp-xplat/master/linux/diagnostic/high_cpu_parser.py wget -c https://raw.githubusercontent.com/microsoft/mdatp-xplat/master/linux/diagnostic/high_cpu_parser.py
``` ```
The output of this command should be similar to the following: The output of this command should be similar to the following:
```Output ```Output
@ -102,10 +109,13 @@ The following steps can be used to troubleshoot and mitigate these issues:
100%[===========================================>] 1,020 --.-K/s in 0s 100%[===========================================>] 1,020 --.-K/s in 0s
``` ```
4. Next, type the following commands: 4. Next, type the following commands:
```bash ```bash
chmod +x high_cpu_parser.py chmod +x high_cpu_parser.py
``` ```
```bash ```bash
cat real_time_protection.json | python high_cpu_parser.py > real_time_protection.log cat real_time_protection.json | python high_cpu_parser.py > real_time_protection.log
``` ```
@ -127,7 +137,7 @@ The following steps can be used to troubleshoot and mitigate these issues:
4764 None 228 4764 None 228
125  CrashPlanService 164 125  CrashPlanService 164
``` ```
 
To improve the performance of Defender for Endpoint for Linux, locate the one with the highest number under the `Total files scanned` row and add an exclusion for it. For more information, see [Configure and validate exclusions for Defender for Endpoint for Linux](linux-exclusions.md). To improve the performance of Defender for Endpoint for Linux, locate the one with the highest number under the `Total files scanned` row and add an exclusion for it. For more information, see [Configure and validate exclusions for Defender for Endpoint for Linux](linux-exclusions.md).
>[!NOTE] >[!NOTE]
@ -136,5 +146,3 @@ The following steps can be used to troubleshoot and mitigate these issues:
5. Configure Microsoft Defender ATP for Linux with exclusions for the processes or disk locations that contribute to the performance issues and re-enable real-time protection. 5. Configure Microsoft Defender ATP for Linux with exclusions for the processes or disk locations that contribute to the performance issues and re-enable real-time protection.
For more information, see [Configure and validate exclusions for Microsoft Defender ATP for Linux](linux-exclusions.md). For more information, see [Configure and validate exclusions for Microsoft Defender ATP for Linux](linux-exclusions.md).