Git Product home page Git Product logo

Comments (7)

virus2500 avatar virus2500 commented on August 25, 2024 1

Hi.... no you don't have to....

I have no idea why but it started working again.

I haven't changed anything since the last time i wrote but i had the service disabled since then.
Today, to go over all the steps again, i started it and..... it's working again o_O I didn't even try any steps from the troubleshooting guide.... it just works.

I honestly have no idea why.

Thanks for your help anyway :)

from checkmk-telegram-plus.

deexno avatar deexno commented on August 25, 2024

Can you please try the following (https://github.com/deexno/checkmk-telegram-plus/blob/main/TROUBLESHOOTING.md#faulty-program-start) and send me the output? If you have any privacy concerns about sending everything here, you can also contact me via telegram @deexno.

from checkmk-telegram-plus.

virus2500 avatar virus2500 commented on August 25, 2024

Hi,

└─╼ # omd_site_name=main
systemctl stop checkmk-telegram-plus-$omd_site_name.service

su - $omd_site_name
cd local/share/checkmk-telegram-plus
python3 telegram_bot.py
OMD[main]:~$ cd local/share/checkmk-telegram-plus
OMD[main]:~/local/share/checkmk-telegram-plus$ python3 telegram_bot.py
Killed
OMD[main]:~/local/share/checkmk-telegram-plus$

I didn't press CTRL + C or anything. It just gets killed by itself.

Here the complete config.ini output (replaced the api_token and allowed_users)

└─╼ # cat /opt/omd/sites/$omd_site_name/local/share/checkmk-telegram-plus/config.ini
[telegram_bot]
language = en
version = v3.1.0
api_token = 123456789:asdfasdfasdf-xyz8xyz
password_for_authentication = xyzi
allowed_users = Me (myId),
notifications_loud =
notifications_silent =

[check_mk]
site = main

[ai]
model = bard
token =

I doubt there is a problem since i regularly get the "I am back" messages and i can authenticate. So this seems to be ok

Just noticed it's the oom-killer that kills it

2023-09-28T10:50:58.309927+02:00 home kernel: [464116.324146] python3 invoked oom-killer: gfp_mask=0x100cca(GFP_HIGHUSER_MOVABLE), order=0, oom_score_adj=0

Memory isn't an problem

└─╼ # free -h
               total        used        free      shared  buff/cache   available
Mem:           4.0Gi       1.7Gi       2.1Gi        10Mi       154Mi       2.3Gi
Swap:          512Mi       512Mi          0B

but when i look at htop while starting the bot it eats up all the remaining ram (about 2Gb) and then gets obviously killed.

from checkmk-telegram-plus.

deexno avatar deexno commented on August 25, 2024

Okay, that's weird. You tried everything else in my troubleshooting guide, right? If so, I'll have to test it on a Debian 11 machine.

from checkmk-telegram-plus.

dricetea avatar dricetea commented on August 25, 2024

Hi Deexno

I have installed CheckMk on a dedicated hardware under Debian 12 and then installed Telegram_Plus.

Unfortunately, something doesn't seem to work properly... I only get the menu displayed from time to time - but there is never a response from the bot...

Sometimes I get the following message:
You are not authenticated! 🔐 When using the bot for the first time, you must authenticate yourself with a password. If you do not do this, the bot 🤖 will not respond to any of your further requests.

That would explain why nothing comes from the bot

There is also no response to the /authenticate function.

I also revoked the token and reistalled your script - still no success...

When I do the check from last time:
OMD[monitoring]:~$ python3 ~/local/share/checkmk-telegram-plus
/omd/sites/monitoring/bin/python3: can't find 'main' module in '/omd/sites/monitoring/local/share/checkmk-telegram-plus'

looks like a problem with _main-??

OMD[monitoring]:~$ python3 --version
Python 3.12.3

Checkmk Cloud Edition 2.3.0p1

Is this all related to the fact that the new installation of Checkmk monitoring site has the same name as the previous version? Should I or do I have to delete something?

Any help is apprechiated!

from checkmk-telegram-plus.

virus2500 avatar virus2500 commented on August 25, 2024

Hi, i don't know if @deexno is reading this anymore since the issue is closed. You should probably open a new one.

However the command you used seems wrong. From: https://github.com/deexno/checkmk-telegram-plus/blob/main/TROUBLESHOOTING.md#faulty-program-start

You should use

omd_site_name=<omd_site_name> # CHANGE <omd_site_name> to the name of your OMD site
systemctl stop checkmk-telegram-plus-$omd_site_name.service

su - $omd_site_name
cd local/share/checkmk-telegram-plus
python3 telegram_bot.py

You are runny python3 against an folder (~/local/share/checkmk-telegram-plus) instead of the script inside it (telegram_bot.py).
Follow the guide and put the output in your new issue.

br

from checkmk-telegram-plus.

deexno avatar deexno commented on August 25, 2024

The bot seems to be responding to you and seems to be working. It seems that you have configured the bot incorrectly using the page name 'main' (As already @virus2500 said) It's a bit hard to tell from your output. Have you already run through the troubleshooting guide and performed it exactly as described? https://github.com/deexno/checkmk-telegram-plus/blob/main/TROUBLESHOOTING.md#faulty-program-start

If everything described there does not work, please open a new issue with more details such as your process of installing with output from it. Thank you.

from checkmk-telegram-plus.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.