Code Monkey home page Code Monkey logo

Comments (6)

sheshko-as avatar sheshko-as commented on July 3, 2024 1

hmm very strange its crashing when u ask meshcentral for a list of nodes, and a device has rdp credentials BUT its crashing because the user doesnt have a id assigned to it? can u replicate the issue? like a certain admin logging in with certain browsers or using meshctrl?

I will try to reproduce the problem and write to you in detail

from meshcentral.

si458 avatar si458 commented on July 3, 2024

hmm very strange
its crashing when u ask meshcentral for a list of nodes, and a device has rdp credentials
BUT its crashing because the user doesnt have a id assigned to it?
can u replicate the issue? like a certain admin logging in with certain browsers or using meshctrl?

from meshcentral.

sheshko-as avatar sheshko-as commented on July 3, 2024

hmm very strange its crashing when u ask meshcentral for a list of nodes, and a device has rdp credentials BUT its crashing because the user doesnt have a id assigned to it? can u replicate the issue? like a certain admin logging in with certain browsers or using meshctrl?

I can't reproduce the problem in any way, there is no pattern. It can work two or three times without errors, the last two days, every day an error, restarting the MeshCentral service:
-------- 6/4/2024, 2:46:08 PM ---- 1.1.24 --------

/root/meshcentral/node_modules/meshcentral/meshuser.js:792
if ((docs[i].rdp != null) && (docs[i].rdp[obj.user._id] != null)) { docs[i].rdp = 1; } else { delete docs[i].rdp; }
^

TypeError: Cannot read properties of undefined (reading '_id')
at /root/meshcentral/node_modules/meshcentral/meshuser.js:792:80
at /root/meshcentral/node_modules/meshcentral/db.js:2571:54
at /root/meshcentral/node_modules/mongodb/lib/utils.js:349:28
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Node.js v18.20.2

I tried to change the VPS, restore from backup on a completely new installation, increase the power of the VPS

from meshcentral.

si458 avatar si458 commented on July 3, 2024

if you are comfortable,
change obj.user._id to user._id, restart meshcentral, then keep an eye out and see if it crashes again

the commit for this line hasnt changed in 2 years - 753b6c2#diff-534d32533813bb72f2e9474b37160f11b5a292ff14ba57f1483044c092bd5b57R751

BUT when checking the commit the is lots of user._id and only that the rdp and ssh lines showing obj.user._id

and after checking it here obj.user seems to match user, so it might be ur setup isnt setting obj.user somewhere?

from meshcentral.

Related Issues (20)

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.