How to troubleshoot the Carbon Black EDR Yara components
systemctl status cb-yara-connector
systemctl status cb-yara-manager
#Restart services and check if the PID has changed after the restart
systemctl restart cb-yara-connector systemctl restart cb-yara-manager
Yara Manager is in the left menu column of EDR Console after cb.conf changes. Look for errors: less /var/log/cb/integrations/cb-yara-connector/yaraconnector.log less /var/log/cb/integrations/cb-yara-manager/cb-yara-manager.log
psql -d cb -p 5002 -c "select * from storefiles where md5hash='\x<hash>';"
select md5,last_scan_date from binarydetonationresult where md5="<hash>"
grep <hash> /var/cb/data/cb-yara-connector/feed.json
curl 'http://localhost:8080/solr/cbfeeds/select?q=id:"binary_<md5 hash lower case here>"'
/var/log/cb/integrations/cb-yara-connector/yaraconnector.log
journalctl -fexu cb-yara-connector
/var/log/cb/integrations/cb-yara-manager/cb-yara-manager.log
sqlite3 /var/cb/data/cb-yara-connector/feed_db/binary.db "select count(*) from binarydetonationresult;"
sqlite3 /var/cb/data/cb-yara-connector/feed_db/binary.db "select count(*) from binarydetonationresult where ‘binary_not_available’ and ‘score’>0;”
alliance_score_yara:*
psql -p 5002 cb -c “select md5hash,node_id from storefiles where present_locally=true and timestamp>=’2023-05-19 00:00:00’ order by timestamp desc;”
client-output-buffer-limit pubsub 0 0 0
URL: file://var/cb/data/cb-yara-connector/feed.json
systemctl stop cb-yara-manager
systemctl stop cb-yara-connector
cp /etc/cb/integrations/cb-yara-connector/yara_rules/.YARA_RULES* /etc/cb/integrations/cb-yara-connector/yara_rules/.YARA_RULES-bkup
rm /etc/cb/integrations/cb-yara-connector/yara_rules/.YARA_RULES*
rm /var/cb/data/cb-yara-connector/feed.json
rm /var/cb/data/cb-yara-connector/feed_db/binary*
systemctl start cb-yara-connector
systemctl start cb-yara-manager
log_level=DEBUG
curl 'http://localhost:8080/solr/cbfeeds/select?q=id:"binary_<md5 hash lower case here>"'
* Confirm the mode is set to 'standalone' (even in an EDR cluster on primary server)
* Confirm the token in the yara configuration has adequate permissions to access the binaries and the account is active.
* Check the Solr logs and yara-connector logs for errors.
* Consider resetting the yara-connector noted previously.