Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error logs found in wazuh-dashboard #4133

Open
juliamagan opened this issue May 4, 2022 · 4 comments
Open

Error logs found in wazuh-dashboard #4133

juliamagan opened this issue May 4, 2022 · 4 comments
Labels
qa/known Issues that are already known by the QA team qa/report QA Team: Reporting possible bug

Comments

@juliamagan
Copy link
Member

juliamagan commented May 4, 2022

Wazuh version Install type Platform
v4.3.0-rc7 Wazuh Dashboard Demo evironment

In wazuh/wazuh-qa#2856 (comment) we have checked logs in /usr/share/wazuh-dashboard/data/wazuh/logs/wazuhapp.log and we could find the following logs:

{"date":"2022-05-03T16:48:32.479Z","level":"error","location":"monitoring:getApiInfo","message":"connect ECONNREFUSED 10.0.0.226:55000"}
{"date":"2022-05-03T16:48:55.348Z","level":"error","location":"monitoring:getApiInfo","message":"connect ECONNREFUSED 10.0.0.226:55000"}
{"date":"2022-05-03T17:10:01.102Z","level":"error","location":"cron-scheduler|SaveDocument","message":"resource_already_exists_exception"}
{"date":"2022-05-04T08:01:07.238Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Bad Request","detail":"Error in wazuhdb request: Cannot execute SQL query","remediation":"Make sure the request is correct","dapi_errors":{"master":{"error":"Error in wazuhdb request: Cannot execute SQL query"}},"error":2003}}
{"date":"2022-05-04T08:01:12.512Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Bad Request","detail":"Error in wazuhdb request: Cannot execute SQL query","remediation":"Make sure the request is correct","dapi_errors":{"master":{"error":"Error in wazuhdb request: Cannot execute SQL query"}},"error":2003}}
{"date":"2022-05-04T08:01:39.343Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Bad Request","detail":"Error in wazuhdb request: Cannot execute SQL query","remediation":"Make sure the request is correct","dapi_errors":{"master":{"error":"Error in wazuhdb request: Cannot execute SQL query"}},"error":2003}}
{"date":"2022-05-04T10:05:22.699Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Wazuh Internal Error","detail":"Timeout executing API request","dapi_errors":{"master":{"error":"Timeout executing API request","logfile":"WAZUH_HOME/logs/api.log"}},"error":3021}}

The only expected logs are:

{"date":"2022-05-04T08:01:07.238Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Bad Request","detail":"Error in wazuhdb request: Cannot execute SQL query","remediation":"Make sure the request is correct","dapi_errors":{"master":{"error":"Error in wazuhdb request: Cannot execute SQL query"}},"error":2003}}
{"date":"2022-05-04T08:01:12.512Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Bad Request","detail":"Error in wazuhdb request: Cannot execute SQL query","remediation":"Make sure the request is correct","dapi_errors":{"master":{"error":"Error in wazuhdb request: Cannot execute SQL query"}},"error":2003}}
{"date":"2022-05-04T08:01:39.343Z","level":"error","location":"wazuh-api:makeRequest","data":{"title":"Bad Request","detail":"Error in wazuhdb request: Cannot execute SQL query","remediation":"Make sure the request is correct","dapi_errors":{"master":{"error":"Error in wazuhdb request: Cannot execute SQL query"}},"error":2003}}

Due to #4088

You can see more logs here.

@juliamagan juliamagan added the qa/report QA Team: Reporting possible bug label May 4, 2022
@juliamagan juliamagan transferred this issue from wazuh/wazuh-packages May 5, 2022
@AlexRuiz7
Copy link
Member

We cannot see any problem with these logs. Please elaborate why these logs should not appear.

@juliamagan
Copy link
Member Author

We are getting connection errors and problems with the cron-scheduler. However, these errors have not been found in testing of later versions, if you don't consider it important you could close this issue.

@sara-hann
Copy link

@AlexRuiz7 @juliamagan I am receiving the cronjob error too. When I try to sign into wazuh, I enter my credentials, then it runs the checks and just hangs.

{"date":"2022-07-11T04:00:00.947Z","level":"error","location":"cron-scheduler|SaveDocument","message":"resource_already_exists_exception"}
{"date":"2022-07-18T04:00:00.735Z","level":"error","location":"cron-scheduler|SaveDocument","message":"resource_already_exists_exception"}
{"date":"2022-07-25T04:00:02.573Z","level":"error","location":"cron-scheduler|SaveDocument","message":"resource_already_exists_exception"}
{"date":"2022-07-29T21:07:09.543Z","level":"error","location":"wazuh-api:checkStoredAPI","message":"Request failed with status code 400"}
{"date":"2022-07-29T21:07:25.965Z","level":"error","location":"wazuh-api:makeRequest","message":"connect ECONNREFUSED 127.0.0.1:55000"}
{"date":"2022-07-29T21:23:42.557Z","level":"error","location":"wazuh-api:checkStoredAPI","message":"Request failed with status code 400"}
{"date":"2022-07-29T21:29:19.922Z","level":"error","location":"wazuh-api:checkStoredAPI","message":"Request failed with status code 400"}
{"date":"2022-07-29T21:29:27.351Z","level":"error","location":"wazuh-api:makeRequest","message":"connect ECONNREFUSED 127.0.0.1:55000"}
{"date":"2022-08-01T04:00:00.547Z","level":"error","location":"cron-scheduler|SaveDocument","message":"resource_already_exists_exception"}

image

@AlexRuiz7
Copy link
Member

Hello @juliamagan @sara-hann

The error error: 2022/06/06 8:46:0: cron-scheduler|SaveDocument: resource_already_exists_exception was fixed for Wazuh v4.3.5, in this issue #4203 (comment)

About the errors of the kind of ECONNREFUSED, they're common logs, as the app might encounter connection errors related to tons of different and external reasons, but we'll further investigate.

@sara-hann, please confirm that your version is prior to 4.3.5, so I can close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
qa/known Issues that are already known by the QA team qa/report QA Team: Reporting possible bug
Projects
No open projects
Status: Known issues
Development

No branches or pull requests

4 participants