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

moonraker not starting after update #352

Closed
tommyl2210 opened this issue Jan 30, 2022 · 46 comments
Closed

moonraker not starting after update #352

tommyl2210 opened this issue Jan 30, 2022 · 46 comments
Labels
bug Something isn't working resolved Issue is resolved

Comments

@tommyl2210
Copy link

tommyl2210 commented Jan 30, 2022

What happened

After updating klipper, moonraker and system packages today, moonraker doesn't start anymore. Log file shows that dbus is not available.

Tried to use "install-moonraker.sh" by
pi@mainsailos:~/moonraker $ sudo sh ./scripts/install-moonraker.sh

but it also fails with:
###### Installing python virtual environment... ERROR: Could not open requirements file: [Errno 2] No such file or directory: '//scripts/moonraker-requirements.txt'

I also added the two recommended [machine] section options:
`[machine]
provider: none

[update_manager]
enable_packagekit: False
`

Any idea to get it back up running?

Client

Mainsail

Browser

Firefox

How to reproduce

see in description

Additional information

_No response
moonraker.log
_

@tommyl2210 tommyl2210 added the bug Something isn't working label Jan 30, 2022
@Fredy12335
Copy link

Same!

@wissencat1
Copy link

It has to do with that and with Pip.
#349
Sadly we have to wait for an update.

@AnthoNYC1968
Copy link

Same!

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

This isn't related to #349, its related to an upstream bug introduced by pip. See #351.

Edit: wait, you also can't run the install script with sudo. However you will still run into the issue with pip.

Also, your log is showing a duplicate section error. Make sure you don't have a section in the config twice. For example, if you have [update_manager] in the config, move the enable_packagekit: False to that section.

@ckvsoft
Copy link

ckvsoft commented Jan 30, 2022

same here :(

@tommyl2210
Copy link
Author

This isn't related to #349, its related to an upstream bug introduced by pip. See #351.

Edit: wait, you also can't run the install script with sudo. However you will still run into the issue with pip.

Also, your log is showing a duplicate section error. Make sure you don't have a section in the config twice. For example, if you have [update_manager] in the config, move the enable_packagekit: False to that section.

thanks @Arksine ! I tried without sudo as well and now removed the extra sections completely. So I guess I/we have to wait until the upstream problem is fixed?

@ckvsoft
Copy link

ckvsoft commented Jan 30, 2022

how we can go back?

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

If you haven't run install-moonraker.sh -r you can try revert Moonraker with the following commands:

cd ~/moonraker
git reset --hard 9911b5c7dd2b8a8962a61e2cf9e98fa8fb1725c9
sudo service moonraker restart

If you ran the install script with the -r switch you deleted your old env and we can't get it back until we can reach pip. I'm checking to see if I can find a workaround for this.

@mdriverch
Copy link

same here

@tommyl2210
Copy link
Author

Thank you so much! This worked for me. I will follow the discussion here and update once pip is fixed.

@Fredy12335
Copy link

If you haven't run install-moonraker.sh -r you can try revert Moonraker with the following commands:

cd ~/moonraker
git reset --hard 9911b5c7dd2b8a8962a61e2cf9e98fa8fb1725c9
sudo service moonraker restart

If you ran the install script with the -r switch you deleted your old env and we can't get it back until we can reach pip. I'm checking to see if I can find a workaround for this.

In my case:
cd ~/moonraker
~/moonraker $ git reset --hard 9911b5c
HEAD is now at 9911b5c app: don't allow open redirects in '/server/redirect'

I dont remember run this before: "install-moonraker.sh -r"

@tommyl2210
Copy link
Author

If you haven't run install-moonraker.sh -r you can try revert Moonraker with the following commands:

cd ~/moonraker
git reset --hard 9911b5c7dd2b8a8962a61e2cf9e98fa8fb1725c9
sudo service moonraker restart

If you ran the install script with the -r switch you deleted your old env and we can't get it back until we can reach pip. I'm checking to see if I can find a workaround for this.

In my case: cd ~/moonraker ~/moonraker $ git reset --hard 9911b5c HEAD is now at 9911b5c app: don't allow open redirects in '/server/redirect'

I dont remember run this before: "install-moonraker.sh -r"

Same with me, restart the pi and it might work. Worked for me.

@turbotrix
Copy link

Thanx Arksine,temp fix worked for me

@toby5419
Copy link

it dont work for me please another solution...

@marchande
Copy link

having the exact same problem here... just comenting so I can follow for the solution.

@arwing123
Copy link

same problem

@caall99
Copy link

caall99 commented Jan 30, 2022

Same issue here, but doing the SSH commands listed above with a couple restarts got me back to printing.

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

Also, if you previously ran the install script with -f and are on FluiddPi/Mainsail OS you may need to slightly modify the options for the install script:

./scripts/install-moonraker.sh -r -f -c ~/klipper_config/moonraker.conf -l ~/klipper_logs/moonraker.log

@Xaos1990
Copy link

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

This worked for me, thanks!

@adrwhong
Copy link

Also, if you previously ran the install script with -f and are on FluiddPi/Mainsail OS you may need to slightly modify the options for the install script:

./scripts/install-moonraker.sh -r -f -c ~/klipper_config/moonraker.conf -l ~/klipper_logs/moonraker.log

Including the previous step, this part ultimately worked for me, thank you!

@agent462
Copy link

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

This also works for me.

@FrYakaTKoP
Copy link
Contributor

as already reported in discord seems to work fine 👍

eric the hero of the "invalid doctype sunday"

As i said before you need to make a kofi account or similar!

@tommyl2210
Copy link
Author

worked for me, too!! Thank you @Arksine for the fast support

@ckvsoft
Copy link

ckvsoft commented Jan 30, 2022

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

Thanks, It works ;-)

@toby5419
Copy link

it works nice for the support----

@Arksine Arksine added the resolved Issue is resolved label Jan 30, 2022
@stephbellemare
Copy link

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

This worked for me as well, also, pip just got updated, which i upgraded as well. Unsure if it helped or not.
Thanks @Arksine

@wissencat1
Copy link

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

Saldy doesnt work for me

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

@stephbellemare Thanks. FWIW, pip 22.0.1 might cause issues the next time Moonraker needs to install a dependency. I believe that 22.0.2 when released will resolve it, so keep an eye out for it and upgrade pip again when it is released.

Previously Moonraker always updated pip before fetching dependencies, however I have disabled that functionality for the time being.

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

@wissencat1 Was an error produced during the install process? What is the output from:

sudo journalctl -xe -u moonraker

@wissencat1
Copy link

I had to run it two times now it is working :)

@stephbellemare
Copy link

@stephbellemare Thanks. FWIW, pip 22.0.1 might cause issues the next time Moonraker needs to install a dependency. I believe that 22.0.2 when released will resolve it, so keep an eye out for it and upgrade pip again when it is released.

Previously Moonraker always updated pip before fetching dependencies, however I have disabled that functionality for the time being.

@Arksine I also just found out pip 22.0 also breaks Klipperscreen.
KlipperScreen/KlipperScreen#483

Quite a fun weekend

@JWRu
Copy link

JWRu commented Jan 30, 2022

cd ~/moonraker
git reset --hard 9911b5c
sudo service moonraker restart

Worked for me.

@semicuda
Copy link

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

Worked for me! Thank you :)

@marchande
Copy link

sadly, none of this has worked for me... I have completely removed moonraker, removed the directory, then let kiauh re install moonraker tried
did a pull in the moonraker dir, and pulled the extra scripts that weren there before, installed with -r and all reported back good...
ran ./scripts/set-policykit-rules.sh after re installing... and still getting connection refused when trying to go to the page and klipper screen is still trying to connect the printer....

@Arksine
Copy link
Owner

Arksine commented Jan 30, 2022

@marchande If Moonraker is running then its likely an unrelated issue. To keep it separate from this thread, you may open up a new issue with a description, klippy.log, and moonraker.log.

To all:
It looks like pip 22.0.1 does fix the issue. I'll keep the hotfix in install-moonraker.sh until 22.0.2 is released and I can test it, at which point I think it will be safe to revert it.

@marchande
Copy link

@marchande If Moonraker is running then its likely an unrelated issue. To keep it separate from this thread, you may open up a new issue with a description, klippy.log, and moonraker.log.

To all: It looks like pip 22.0.1 does fix the issue. I'll keep the hotfix in install-moonraker.sh until 22.0.2 is released and I can test it, at which point I think it will be safe to revert it.

@Arksine, ultimatly after getting moonkraker working again, I had to remove and re install mainsali and that fixed my problems, wich is as you said a diferent problem but figured added an update here just incase any one else ends up with the same problem I did..

@64bittuning
Copy link

64bittuning commented Feb 8, 2022

Checking in.
Just updated to 0.7.1-356 and got he ominous wall of text that Moonraker went stupid.

Ran the data above through SSH
cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

Issue was resolved. Rolled me back to -310.
FWIW, this install was done on mainsailOS and updates are done through the Update Manager in Mainsail. No additional scripts are run outside of that.

@Arksine
Copy link
Owner

Arksine commented Feb 8, 2022

It shouldn't have been necessary to roll back. The warnings were due an underlying change in Moonraker, see #349 for details.. The next time you update the warnings will return and you will have to take action to resolve them. Alternatively you can stay at 0.7.1-310 if you would prefer.

@64bittuning
Copy link

#349 Solved my issue, thanks.

@Arksine
Copy link
Owner

Arksine commented Feb 15, 2022

I want to thank everyone for their feedback in this issue. The pip issue has been resolved upstream, and going forward most users are going to face #349. I'm going go ahead and close this issue to give bump 349 and give it more visibility.

@Arksine Arksine closed this as completed Feb 15, 2022
@JoeDiesAtTheEnd
Copy link

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

### this worked for me

@DarrenLindsey
Copy link

Very nice @JoeDiesAtTheEnd

@switz-3d
Copy link

switz-3d commented Jan 22, 2023

I'm the only one who this update has deinstalled/messed up pyton3?

I've fixed it with:
sudo apt --fix-broken install

@TadasMit
Copy link

TadasMit commented Feb 8, 2023

Oh thank you! It was driving me crazy. This fixed my issue with moonraker too!

@Xcion54
Copy link

Xcion54 commented May 29, 2024

I believe I have a workaround. SSH into your machine and run the following:

cd ~/moonraker
git pull
./scripts/install-moonraker.sh -r

See the post below if you previously ran install-moonraker.sh -f

If you haven't installed the policykit rules you may want to go ahead and do so now:

./scripts/set-policykit-rules.sh

Please respond with feedback if this worked for you. Thanks, and I apologize for the downtime here.

I had a mental breakdown trying to fix this, thank you so much

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working resolved Issue is resolved
Projects
None yet
Development

No branches or pull requests