Code Monkey home page Code Monkey logo

Comments (11)

ctrlaltca avatar ctrlaltca commented on June 16, 2024 6

I had the same error on Ubuntu 22.04 (using nodejs 12) and fixed it by installing nodejs version 20.

npm install -g n
n lts
node --version

I had to edit /etc/systemd/system/meshcentral.service changing /usr/bin/node to the new path /usr/local/bin/node for the new version of nodejs to be picked up.

systemctl stop meshcentral.service
nano /etc/systemd/system/meshcentral.service
systemctl daemon-reload
systemctl start meshcentral.service
systemctl status meshcentral.service

from meshcentral.

meh324 avatar meh324 commented on June 16, 2024

Restored to 1.1.0 and the service worked fine. I updated to 1.1.22 from 1.1.0 and the service stops working. I'm going to use 1.1.0 until the issue is fixed. Happy to help if I can.

from meshcentral.

si458 avatar si458 commented on June 16, 2024

this seems to be related to the archiver module which @Ylianst updated the other day,
not sure why its crashing, will have to look into it

from meshcentral.

quizhead avatar quizhead commented on June 16, 2024

How can I restore back? I can't run the server with node meshcentral command.
Getting Permission denided errror

[Error: EACCES: permission denied, open '/home/quizhead/meshcentral/meshcentral-data/meshcentral-power.db'] {
  errno: -13,
  code: 'EACCES',
  syscall: 'open',
  path: '/home/quizhead/meshcentral/meshcentral-data/meshcentral-power.db'
}

Node.js v20.11.1

    at ChildProcess.exithandler (node:child_process:422:12)
    at ChildProcess.emit (node:events:530:35)
    at maybeClose (node:internal/child_process:1105:16)
    at Socket.<anonymous> (node:internal/child_process:457:11)
    at Socket.emit (node:events:518:28)
    at Pipe.<anonymous> (node:net:337:12) {
  code: 1,
  killed: false,
  signal: null,
  cmd: '/usr/local/bin/node /home/quizhead/meshcentral/node_modules/meshcentral --launch 5789'
}
ERROR: MeshCentral failed with critical error, check mesherrors.txt. Restarting in 5 seconds...

The meshcentral.service is configured as needed

from meshcentral.

si458 avatar si458 commented on June 16, 2024

@quizhead the error is right there...
[Error: EACCES: permission denied, open '/home/quizhead/meshcentral/meshcentral-data/meshcentral-power.db']

the file meshcentral-power.db ISNT the same as whats inside your meshcentral.service OR whatever user you are using to RUN node with, so make sure they all match

from meshcentral.

quizhead avatar quizhead commented on June 16, 2024

@quizhead the error is right there... [Error: EACCES: permission denied, open '/home/quizhead/meshcentral/meshcentral-data/meshcentral-power.db']

the file meshcentral-power.db ISNT the same as whats inside your meshcentral.service OR whatever user you are using to RUN node with, so make sure they all match
It's configured as needed. Should I delete the Node_Modules folder and reinstall?

from meshcentral.

si458 avatar si458 commented on June 16, 2024

@quizhead please open an issue in the 'discussions' this thread is about the archiver bug

from meshcentral.

si458 avatar si458 commented on June 16, 2024

@meh324 just looked into this,
it appears minimatch which is a dependency for archiver now required node 16 or above,
you say you are using node 21 which might be the case when running node node_modules/meshcentral
can you check your startup scripts are using the correct node version?

from meshcentral.

meh324 avatar meh324 commented on June 16, 2024

You were correct, it says it's running 12.22.9.

How do I update that node that the services use?

from meshcentral.

si458 avatar si458 commented on June 16, 2024

@ctrlaltca yes the min requirement for meshcentral was 12 but im guessing the archiver now means we need to upgrade it now to 16 at least,
but really people should be using at least the LTS version (20)

from meshcentral.

meh324 avatar meh324 commented on June 16, 2024

That fixed it, thanks so much!

I had the same error on Ubuntu 22.04 (using nodejs 12) and fixed it by installing nodejs version 20.

npm install -g n
n lts
node --version

I had to edit /etc/systemd/system/meshcentral.service changing /usr/bin/node to the new path /usr/local/bin/node for the new version of nodejs to be picked up.

systemctl stop meshcentral.service
nano /etc/systemd/system/meshcentral.service
systemctl daemon-reload
systemctl start meshcentral.service
systemctl status meshcentral.service

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.