Collect Agent Performance Logs
book
Article ID: 286081
calendar_today
Updated On:
Feedback
Subscribe
Products
Carbon Black App Control (formerly Cb Protection)
Show More
Show Less
Issue/Introduction
Steps to collect App Control Agent logs for performance cases.
Environment
App Control Agent: All Supported Versions Microsoft Windows: All Supported Versions macOS: All Supported Versions Linux: All Supported Versions
Resolution
Step 1: Gather Relevant Background Information Date/Time performance issue started occurring (did any change precede the start of it?) Actions being performed when performance is degraded Is the performance associated with a specific application? (If yes, what is the application name?). Does the vendor of the application have a recommended exclusion list and has it been implemented? Any paths/processes known to be associated with the application Are there any blocks seen locally or within the App Control console during the performance issue? Are results the same if the Agent is stopped and unloaded? What is the time difference with Agent stopped & unloaded vs fully operational (enabled)?
Step 2: Gather the Logs Windows Open an administrative command prompt Issue the commands:cd "C:\Program Files (x86)\Bit9\Parity Agent"
dascli password GlobalCLIPassword
dascli setconfigprop max_rolling_trace_size_mb=500 dascli setconfigprop max_rolled_trace_logs_to_keep=5
dascli resetcounters
dascli flushlogs
dascli tamperprotect 0 dascli debuglevel 6
dascli kerneltrace 4
dascli nettrace 1
dascli diagnostics +performanceImportant, if Agent 8.10.0+ also issue: dascli registerprotected 0 Start a Procmon capture . Collect 5-10 mins of data during the ongoing performance issue. Stop the Procmon capture and save "All Events" as a PML file. In the administrative command prompt execute the following commands to capture and reduce the logging levels to normal:dascli capture "%userprofile%\Desktop\%computername%-Performance.zip"
dascli password GlobalCLIPassword
dascli setconfigprop max_rolling_trace_size_mb=50 dascli setconfigprop max_rolled_trace_logs_to_keep=1
dascli debuglevel 0
dascli kerneltrace 2
dascli nettrace 0
dascli diagnostics -performanceIf Agent 8.10.0+ first issue: dascli registerprotected 1
dascli tamperprotect 1 Upload all collected data. macOS Open Terminal Issue the commands:cd /Applications/Bit9/Tools
./b9cli --password 'GlobalCLIPassword'
./b9cli --resetcounters
./b9cli --flushlogs
./b9cli --debuglevel 4
./b9cli --kerneltrace 4
./b9cli --nettrace 1 Open the macOS Activity Monitor (Applications > Utilities > Activity Monitor). Click View > Update Frequency > Often (2 sec) Collect 5-10 mins of data during the ongoing performance issue. Return to Activity Monitor, and double click the process with the performance issue. Click Sample. Once the Sample completes choose "Save" to export the results. In Terminal, capture the Agent Logs and return logging to defaults:./b9cli --capture ~/Desktop/`Hostname`-PerformanceLogs.zip
./b9cli --password 'GlobalCLIPassword'
./b9cli --debuglevel 0
./b9cli --kerneltrace 2
./b9cli --nettrace 0 Collect System Logssystem_profiler -detailLevel full > ~/Desktop/sysinfo.txt
tar -cvf ~/Desktop/`hostname`-DiagnosticReports.tar /Library/Logs/DiagnosticReports Upload all collected data. Linux Proper investigation into Agent Performance issues will require recreating the issue while capturing specific logs. Failure to capture the REQUIRED logs as outlined below will delay the investigation and require new log captures. While RECOMMENDED , the snapshot of b9daemon and the FAPREDEP are not required unless specifically asked for by Engineering.
REQUIRED Increase the Agent's Debug Levels and capture 5-10 minutes of the performance issueOpen Terminal and issue the following commands:cd /opt/bit9/bin
./b9cli --password GlobalCLIPassword
./b9cli --resetcounters
./b9cli --flushlogs
./b9cli --debuglevel 4
./b9cli --kerneltrace 4
./b9cli --nettrace 1
Recreate performance issue for 5-10 minutes While the performance issue is present, capture the output from TOPtop -b -c -w 512 -n 10 -d 5 >> /var/tmp/$HOSTNAME-top_output.txt
Capture the logs & reset the Debug Levelssudo ./b9cli --capture /var/tmp/$HOSTNAME-PerformanceLogs.zip
./b9cli --password GlobalCLIPassword
./b9cli --debuglevel 0
./b9cli --kerneltrace 2
./b9cli --nettrace 0 ./b9cli --flushlogs REQUIRED Use cbp-linux-sys-info.sh (attached at bottom of article) to collect system infoDownload the attached script to the endpoint. Extract and execute the script. Once completed, collect the resulting "/tmp/cbp-linux-sys-info.tgz" file. Recommended Snapshot b9daemon with gcore during the performance issueVerify gcore is present with the --version command, if missing install via Package Managergcore --version sudo dnf install gdb Disable the Agent's Tamper Protection and capture a core of the b9daemonThe resulting gcore file will be very large and the system may feel hung for several minutes while the capture takes place. Tamper Protection must first be disabled to allow gcore to properly pause the process and capture the memory. ./b9cli --tamperprotect 0 sudo gcore -o /var/tmp/$HOSTNAME_core `pidof b9daemon` Recommended Capture FAPREDEP while attempting to recreate the issue, and with the Agent is not runningStop & unload the Agent .Collect System Logs.sudo tar cvfz /var/tmp/$HOSTNAME-SystemLogs.tgz /var/log While the Agent is shutdown & unloaded, run the FAPREDEP script . Upload all collected data.
Feedback
thumb_up
Yes
thumb_down
No