MM won't start automatically after modules update
-
I think, but I don’t know anything about linux and how\where it should be configured…
-
Anyone? It broke after 2.25 upgrade…
-
I found an official way to autostart MM, but I installed it with your script… how can I be sure that mixing your script and official script won’t break something?
https://docs.magicmirror.builders/configuration/autostart.html#using-pm2
-
but I installed it with your script…
What’s this script ?
-
The one that was in your wiki some time ago…
-
This old installer using sdetweil installer (official) and just add an cloning of GA suite
It will do nothing morepm2 is an app like MagicMirror
Just check if installed.
If not… Install it
If any pm2 respond of some commands: verify if starting script of MagicMirrror is in installer folder (mm.sh file)
I can’t help better without informations/logs -
I had no info about the old installer was nothing special… you always said to use only your installers so I’m scared about using info found elsewhere to mod\fix my mirror
pm2 is installed
mm.sh script is present in installed folder, with this text:#!/bin/bash
This file is still here to keep PM2 working on older installations.
cd ~/MagicMirror
DISPLAY=:0 npm startIs this still ok?
I don’t know where to find logs when MM is not started (I have very little knowloedge of linux systems)
-
Still broken and can’t find what to do to re-enable autostart
-
try this in a terminal, maybe it will help:
bash -c "$(curl -sL https://raw.githubusercontent.com/sdetweil/MagicMirror_scripts/master/fixuppm2.sh)"
-
ok, now I have two logs and if I understand well, it seems fixed:
pm2_setup.log
pm2 setup starting - Thu Nov 9 09:58:58 CET 2023 using parameter bash system is Linux magicmirror 5.15.84-v7+ #1613 SMP Thu Jan 5 11:59:48 GMT 2023 armv7l GNU/Linux the os is Distributor ID: Raspbian Description: Raspbian GNU/Linux 11 (bullseye) Release: 11 Codename: bullseye node version v20.8.0 force installing latest npm version via npm npm version 10.1.0 pm2 installed get the pm2 platform specific startup command startup command = sudo env PATH=$PATH:/usr/bin /usr/lib/node_modules/pm2/bin/pm2 startup systemd -u pi --hp /home/pi [PM2] Init System found: systemd Platform systemd Template [Unit] Description=PM2 process manager Documentation=https://pm2.keymetrics.io/ After=network.target [Service] Type=forking User=pi LimitNOFILE=infinity LimitNPROC=infinity LimitCORE=infinity Environment=PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games:/usr/bin:/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin Environment=PM2_HOME=/home/pi/.pm2 PIDFile=/home/pi/.pm2/pm2.pid Restart=on-failure ExecStart=/usr/lib/node_modules/pm2/bin/pm2 resurrect ExecReload=/usr/lib/node_modules/pm2/bin/pm2 reload all ExecStop=/usr/lib/node_modules/pm2/bin/pm2 kill [Install] WantedBy=multi-user.target Target path /etc/systemd/system/pm2-pi.service Command list [ 'systemctl enable pm2-pi' ] [PM2] Writing init configuration in /etc/systemd/system/pm2-pi.service [PM2] Making script booting at startup... [PM2] [-] Executing: systemctl enable pm2-pi... [PM2] [v] Command successfully executed. +---------------------------------------+ [PM2] Freeze a process list on reboot via: $ pm2 save [PM2] Remove init script via: $ pm2 unstartup systemd pm2 startup command done configure the pm2 config file for MagicMirror start MagicMirror via pm2 now save MagicMirror pm2 config now pm2 setup completed - Thu Nov 9 09:59:23 CET 2023
dump.pm2:
[ { "namespace": "default", "kill_retry_time": 100, "windowsHide": true, "username": "pi", "treekill": true, "automation": true, "pmx": true, "instance_var": "NODE_APP_INSTANCE", "watch": [ "/home/pi/MagicMirror/config/config.js" ], "autorestart": true, "vizion": true, "merge_logs": true, "env": { "MagicMirror": "{}", "PM2_HOME": "/home/pi/.pm2", "PM2_JSON_PROCESSING": "true", "PM2_USAGE": "CLI", "_": "/usr/bin/pm2", "OLDPWD": "/home/pi", "TEXTDOMAIN": "Linux-PAM", "DBUS_SESSION_BUS_ADDRESS": "unix:path=/run/user/1000/bus", "SAL_USE_VCLPLUGIN": "gtk3", "GDMSESSION": "lightdm-xsession", "PATH": "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games", "XDG_DATA_DIRS": "/usr/share/fkms:/usr/local/share:/usr/share/raspi-ui-overrides:/usr/share:/usr/share/gdm:/var/lib/menu-xdg", "XDG_RUNTIME_DIR": "/run/user/1000", "XDG_SESSION_ID": "3", "XDG_VTNR": "7", "SHLVL": "2", "DISPLAY": ":0", "USER": "pi", "TERM": "xterm-256color", "XDG_SESSION_CLASS": "user", "XDG_SEAT_PATH": "/org/freedesktop/DisplayManager/Seat0", "VTE_VERSION": "6203", "XDG_CURRENT_DESKTOP": "LXDE", "LS_COLORS": "rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:", "LANG": "en_GB.UTF-8", "HOME": "/home/pi", "XDG_GREETER_DATA_DIR": "/var/lib/lightdm/data/pi", "XAUTHORITY": "/home/pi/.Xauthority", "GPG_AGENT_INFO": "/run/user/1000/gnupg/S.gpg-agent:0:1", "XDG_SESSION_TYPE": "x11", "QT_QPA_PLATFORMTHEME": "qt5ct", "LOGNAME": "pi", "XDG_SESSION_DESKTOP": "lightdm-xsession", "PWD": "/home/pi/MagicMirror", "XDG_SEAT": "seat0", "NO_AT_BRIDGE": "1", "SSH_AGENT_PID": "921", "DESKTOP_SESSION": "LXDE-pi", "XDG_CONFIG_HOME": "/home/pi/.config", "SSH_AUTH_SOCK": "/tmp/ssh-ksGYgH0iT76z/agent.795", "_LXSESSION_PID": "795", "XDG_MENU_PREFIX": "lxde-pi-", "XDG_SESSION_PATH": "/org/freedesktop/DisplayManager/Session0", "XDG_CONFIG_DIRS": "/etc/xdg", "COLORTERM": "truecolor", "SHELL": "/bin/bash", "unique_id": "c3c96e8f-53b9-4512-8533-49c5ff51602c" }, "name": "MagicMirror", "node_args": [], "pm_exec_path": "/home/pi/MagicMirror/installers/mm.sh", "pm_cwd": "/home/pi/MagicMirror", "exec_interpreter": "bash", "exec_mode": "fork_mode", "pm_out_log_path": "/home/pi/.pm2/logs/MagicMirror-out.log", "pm_err_log_path": "/home/pi/.pm2/logs/MagicMirror-error.log", "pm_pid_path": "/home/pi/.pm2/pids/MagicMirror-0.pid", "km_link": false, "vizion_running": false, "NODE_APP_INSTANCE": 0, "MagicMirror": "{}", "PM2_HOME": "/home/pi/.pm2", "PM2_JSON_PROCESSING": "true", "PM2_USAGE": "CLI", "_": "/usr/bin/pm2", "OLDPWD": "/home/pi", "TEXTDOMAIN": "Linux-PAM", "DBUS_SESSION_BUS_ADDRESS": "unix:path=/run/user/1000/bus", "SAL_USE_VCLPLUGIN": "gtk3", "GDMSESSION": "lightdm-xsession", "PATH": "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games", "XDG_DATA_DIRS": "/usr/share/fkms:/usr/local/share:/usr/share/raspi-ui-overrides:/usr/share:/usr/share/gdm:/var/lib/menu-xdg", "XDG_RUNTIME_DIR": "/run/user/1000", "XDG_SESSION_ID": "3", "XDG_VTNR": "7", "SHLVL": "2", "DISPLAY": ":0", "USER": "pi", "TERM": "xterm-256color", "XDG_SESSION_CLASS": "user", "XDG_SEAT_PATH": "/org/freedesktop/DisplayManager/Seat0", "VTE_VERSION": "6203", "XDG_CURRENT_DESKTOP": "LXDE", "LS_COLORS": "rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arc=01;31:*.arj=01;31:*.taz=01;31:*.lha=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.tlz=01;31:*.txz=01;31:*.tzo=01;31:*.t7z=01;31:*.zip=01;31:*.z=01;31:*.dz=01;31:*.gz=01;31:*.lrz=01;31:*.lz=01;31:*.lzo=01;31:*.xz=01;31:*.zst=01;31:*.tzst=01;31:*.bz2=01;31:*.bz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.war=01;31:*.ear=01;31:*.sar=01;31:*.rar=01;31:*.alz=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.cab=01;31:*.wim=01;31:*.swm=01;31:*.dwm=01;31:*.esd=01;31:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:", "LANG": "en_GB.UTF-8", "HOME": "/home/pi", "XDG_GREETER_DATA_DIR": "/var/lib/lightdm/data/pi", "XAUTHORITY": "/home/pi/.Xauthority", "GPG_AGENT_INFO": "/run/user/1000/gnupg/S.gpg-agent:0:1", "XDG_SESSION_TYPE": "x11", "QT_QPA_PLATFORMTHEME": "qt5ct", "LOGNAME": "pi", "XDG_SESSION_DESKTOP": "lightdm-xsession", "PWD": "/home/pi/MagicMirror", "XDG_SEAT": "seat0", "NO_AT_BRIDGE": "1", "SSH_AGENT_PID": "921", "DESKTOP_SESSION": "LXDE-pi", "XDG_CONFIG_HOME": "/home/pi/.config", "SSH_AUTH_SOCK": "/tmp/ssh-ksGYgH0iT76z/agent.795", "_LXSESSION_PID": "795", "XDG_MENU_PREFIX": "lxde-pi-", "XDG_SESSION_PATH": "/org/freedesktop/DisplayManager/Session0", "XDG_CONFIG_DIRS": "/etc/xdg", "COLORTERM": "truecolor", "SHELL": "/bin/bash", "unique_id": "c3c96e8f-53b9-4512-8533-49c5ff51602c", "status": "online", "pm_uptime": 1699520359901, "axm_actions": [], "axm_monitor": {}, "axm_options": {}, "axm_dynamic": {}, "created_at": 1699520359901, "restart_time": 0, "unstable_restarts": 0, "version": "2.25.0", "versioning": { "type": "git", "url": "https://github.com/MichMich/MagicMirror.git", "revision": "343e7de7bd295a69e68e4ee520552e0785a99e1c", "comment": "Release v2.25.0 (#3214)\n\n## [2.25.0] - 2023-10-01\r\n\r\nThanks to: @bugsounet, @dgoth, @dependabot, @kenzal, @Knapoc,\r\n@KristjanESPERANTO, @martingron, @NolanKingdon, @Paranoid93,\r\n@TeddyStarinvest and @Ybbet.\r\n\r\nSpecial thanks to @khassel, @rejas and @sdetweil for taking over most\r\n(if not all) of the work on this release as project collaborators. This\r\nversion would not be there without their effort. Thank you guys! You are\r\nawesome!\r\n\r\n> ⚠️ This release needs nodejs version >= `v18`, older releases have\r\nreached end of life and will not work!\r\n\r\n### Added\r\n\r\n- Added UV Index support to OpenWeatherMap\r\n- Added 'hideDuplicates' flag to the calendar module\r\n- Added `allowOverrideNotification` to weather module to enable sending\r\ncurrent weather objects with the `CURRENT_WEATHER_OVERRIDE` notification\r\nto supplement/replace the current weather displayed\r\n- Added optional AnimateCSS animate for `hide()`, `show()`,\r\n`updateDom()`\r\n- Added AnimateIn and animateOut in module config definition\r\n- Apply AnimateIn rules on the first start\r\n- Added automatic client page reload when server was restarted by\r\nsetting `reloadAfterServerRestart: true` in `config.js`, per default\r\n`false` (#3105)\r\n- Added eventClass option for customEvents on the default calendar\r\n- Added AnimateCSS integration in tests suite (#3206)\r\n- Added npm dependabot [Reserved to developer] (#3210)\r\n- Added improved logging for calendar (#3110)\r\n\r\n### Removed\r\n\r\n- **Breaking Change**: Removed `digest` authentication method from\r\ncalendar module (which was already broken since release `2.15.0`)\r\n\r\n### Updated\r\n\r\n- Update roboto fonts to version v5\r\n- Update issue template\r\n- Update dev/dependencies incl. electron to v26\r\n- Replace pretty-quick by lint-staged\r\n(<https://github.com/azz/pretty-quick/issues/164>)\r\n- Update engine node >=18. v16 reached it's end of life. (#3170)\r\n- Update typescript definition for modules\r\n- Cleaned up nunjuck templates\r\n- Replace `node-fetch` with internal fetch (#2649) and remove\r\n`digest-fetch`\r\n- Update the French translation according to the English file.\r\n- Update dependabot incl. vendor/fonts (monthly check)\r\n- Renew `package-lock.json` for release\r\n\r\n### Fixed\r\n\r\n- Fix engine check on npm install (#3135)\r\n- Fix undefined formatTime method in clock module (#3143)\r\n- Fix clientonly startup fails after async added (#3151)\r\n- Fix electron width/heigth when using xrandr under bullseye\r\n- Fix time issue with certain recurring events in calendar module\r\n- Fix ipWhiteList test (#3179)\r\n- Fix newsfeed: Convert HTML entities, codes and tag in description\r\n(#3191)\r\n- Respect width/height (no fullscreen) if set in electronOptions\r\n(together with `fullscreen: false`) in `config.js` (#3174)\r\n- Fix: AnimateCSS merge hide() and show() animated css class when we do\r\nmultiple call\r\n- Fix `Uncaught SyntaxError: Identifier 'getCorsUrl' has already been\r\ndeclared (at utils.js:1:1)` when using `clock` and `weather` module\r\n(#3204)\r\n- Fix overriding `config.js` when running tests (#3201)\r\n- Fix issue in weathergov provider with probability of precipitation not\r\nshowing up on hourly or daily forecast\r\n\r\n---------\r\n\r\nSigned-off-by: naveen <172697+naveensrinivasan@users.noreply.github.com>\r\nSigned-off-by: dependabot[bot] <support@github.com>\r\nCo-authored-by: Karsten Hassel <hassel@gmx.de>\r\nCo-authored-by: Malte Hallström <46646495+SkySails@users.noreply.github.com>\r\nCo-authored-by: Veeck <github@veeck.de>\r\nCo-authored-by: veeck <michael@veeck.de>\r\nCo-authored-by: dWoolridge <dwoolridge@charter.net>\r\nCo-authored-by: Johan <jojjepersson@yahoo.se>\r\nCo-authored-by: Dario Mratovich <dario_mratovich@hotmail.com>\r\nCo-authored-by: Dario Mratovich <dario.mratovich@outlook.com>\r\nCo-authored-by: Magnus <34011212+MagMar94@users.noreply.github.com>\r\nCo-authored-by: Naveen <172697+naveensrinivasan@users.noreply.github.com>\r\nCo-authored-by: buxxi <buxxi@omfilm.net>\r\nCo-authored-by: Thomas Hirschberger <47733292+Tom-Hirschberger@users.noreply.github.com>\r\nCo-authored-by: Kristjan ESPERANTO <35647502+KristjanESPERANTO@users.noreply.github.com>\r\nCo-authored-by: Andrés Vanegas Jiménez <142350+angeldeejay@users.noreply.github.com>\r\nCo-authored-by: Dave Child <dave@addedbytes.com>\r\nCo-authored-by: grenagit <46225780+grenagit@users.noreply.github.com>\r\nCo-authored-by: Grena <grena@grenabox.fr>\r\nCo-authored-by: Magnus Marthinsen <magmar@online.no>\r\nCo-authored-by: Patrick <psieg@users.noreply.github.com>\r\nCo-authored-by: Piotr Rajnisz <56397164+rajniszp@users.noreply.github.com>\r\nCo-authored-by: Suthep Yonphimai <tomzt@users.noreply.github.com>\r\nCo-authored-by: CarJem Generations (Carter Wallace) <cwallacecs@gmail.com>\r\nCo-authored-by: Nicholas Fogal <nfogal.misc@gmail.com>\r\nCo-authored-by: JakeBinney <126349119+JakeBinney@users.noreply.github.com>\r\nCo-authored-by: OWL4C <124401812+OWL4C@users.noreply.github.com>\r\nCo-authored-by: Oscar Björkman <17575446+oscarb@users.noreply.github.com>\r\nCo-authored-by: Ismar Slomic <ismar@slomic.no>\r\nCo-authored-by: Jørgen Veum-Wahlberg <jorgen.wahlberg@amedia.no>\r\nCo-authored-by: Eddie Hung <6740044+eddiehung@users.noreply.github.com>\r\nCo-authored-by: Bugsounet - Cédric <github@bugsounet.fr>\r\nCo-authored-by: bugsounet <bugsounet@bugsounet.fr>\r\nCo-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>\r\nCo-authored-by: Knapoc <Knapoc@users.noreply.github.com>\r\nCo-authored-by: sam detweiler <sdetweil@gmail.com>\r\nCo-authored-by: veeck <michael.veeck@nebenan.de>\r\nCo-authored-by: Paranoid93 <6515818+Paranoid93@users.noreply.github.com>\r\nCo-authored-by: NolanKingdon <27908974+NolanKingdon@users.noreply.github.com>\r\nCo-authored-by: J. Kenzal Hunter <kenzal.hunter@gmail.com>\r\nCo-authored-by: Teddy <teddy.payet@gmail.com>\r\nCo-authored-by: TeddyStarinvest <teddy.payet@starinvest.com>\r\nCo-authored-by: martingron <61826403+martingron@users.noreply.github.com>\r\nCo-authored-by: dgoth <132394363+dgoth@users.noreply.github.com>", "unstaged": true, "branch": "master", "remotes": [ "origin" ], "remote": "origin", "branch_exists_on_remote": true, "ahead": false, "next_rev": null, "prev_rev": "e87f50e64aeaf3a8587f4855f4679c3223959fd0", "update_time": "2023-11-09T08:59:21.037Z", "tags": [ "v2.23.0", "v2.24.0", "v2.25.0" ], "repo_path": "/home/pi/MagicMirror" } } ]
I’ll check if it works again… thank you so so much for now!