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 when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10 #373

Open
danie-dejager opened this issue Jun 4, 2024 · 0 comments

Comments

@danie-dejager
Copy link

I am unable to import Apache logs from an ubuntu host running ubuntu 20.04.06 x86_64 with python 3.8. The output I get importing the log file is:

0 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
Parsing log /var/log/apache2/access_matomo.log...
2024-06-04 19:06:16,798: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:16,798: [INFO] Retrying request, attempt number 2
2024-06-04 19:06:17,063: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:17,063: [INFO] Retrying request, attempt number 2
2024-06-04 19:06:17,124: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:17,124: [INFO] Retrying request, attempt number 2
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2024-06-04 19:06:27,198: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:27,198: [INFO] Retrying request, attempt number 3
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2024-06-04 19:06:27,637: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:27,637: [INFO] Retrying request, attempt number 3
2024-06-04 19:06:27,753: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:27,753: [INFO] Retrying request, attempt number 3
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2400 lines parsed, 0 lines recorded, 0 records/sec (avg), 0 records/sec (current)
2024-06-04 19:06:37,517: [INFO] Error when connecting to Matomo: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte
2024-06-04 19:06:37,517: [INFO] Max number of attempts reached, server is unreachable!
Fatal error: 'utf-8' codec can't decode byte 0x80 in position 10: invalid start byte

If I import using the described Apache method my logs are imported.

matomo-log-analytics/import_logs.py is the latest version from git.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant