Read the statement by Michael Teeuw here.
Can't Install: Segmentation Fault when Installing Fonts
-
I am trying to install MagicMirror on a Raspberry Pi virtual machine. I am using the Raspberry Pi distribution 2019-09-25-rpd-x86-buster.iso running with Oracle VirtualBox on a MacBook Pro running OS X 10.12.6.
The install fails when npm experiences a segmentation fault when installing fonts.
Here is the error output:We’ll remove from the repository the css/custom.css
This script apply git update-index --skip-worktree css/custom.css
rm ‘css/custom.css’
MagicMirror installation successful!magicmirror@2.9.0 install-fonts /home/pi/MagicMirror
cd fonts && npm installSegmentation fault.] \ extract:roboto-fontface: verb lock using /home/pi/.npm/
npm ERR! code ELIFECYCLE
npm ERR! errno 139
npm ERR! magicmirror@2.9.0 install-fonts:cd fonts && npm install
npm ERR! Exit status 139
npm ERR!
npm ERR! Failed at the magicmirror@2.9.0 install-fonts script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2019-12-27T23_47_49_618Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 139
npm ERR! magicmirror@2.9.0 postinstall:sh untrack-css.sh && sh installers/postinstall/postinstall.sh && npm run install-fonts
npm ERR! Exit status 139
npm ERR!
npm ERR! Failed at the magicmirror@2.9.0 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2019-12-27T23_47_49_670Z-debug.log
Unable to install dependencies!I am new to Magic Mirror and I’m not sure how to move past this failure. Any advice that you can offer would be greatly appreciated.
Thanks!
-
@mdub ok, not sure why the problem… can u try the updated installer…
see here https://forum.magicmirror.builders/topic/10171/anyone-want-to-try-updated-installer
this will be in the next version releaseyou will need to rename MagicMirror folder to something else
also I might suggest to rm -rf ~/.npm to clean up the npm folder
-
I’m having the exact same problem:
Segmentation fault.] \ extract:roboto-fontface: verb lock using /home/pi/.npm/_locks/staging-0ff2d9730ff2850b.lock for /home/pi/MagicMirror/fonts/node_modules/.stagi npm ERR! code ELIFECYCLE npm ERR! errno 139
…and so on.
I have a fresh new & updated RPI install into an ESXi VM, and I’m following the instructions on https://docs.magicmirror.builders/getting-started/installation.html#manual-installation
(plus: sudo apt-get -y install npm && sudo npm i -g npm).I have tried to remove and re-clone the MagicMirror dist, same effect.
Here’s a little more from the npm log, in case it is helpful…
28887 silly postinstall valid-url@1.0.9 28888 info lifecycle valid-url@1.0.9~postinstall: valid-url@1.0.9 28889 verbose unlock done using /home/pi/.npm/_locks/staging-f4a655787a5bf4d3.lock for /home/pi/MagicMirror/node_modules/.staging 28890 silly install runPostinstallTopLevelLifecycles 28891 silly build magicmirror@2.11.0 28892 info linkStuff magicmirror@2.11.0 28893 silly linkStuff magicmirror@2.11.0 has /home/pi as its parent node_modules 28894 verbose linkBins magicmirror@2.11.0 28895 verbose linkMans magicmirror@2.11.0 28896 silly install magicmirror@2.11.0 28897 info lifecycle magicmirror@2.11.0~install: magicmirror@2.11.0 28898 verbose lifecycle magicmirror@2.11.0~install: unsafe-perm in lifecycle true 28899 verbose lifecycle magicmirror@2.11.0~install: PATH: /usr/share/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/pi/MagicMirror/node_modules/.bin:/usr/local/sbi n:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games 28900 verbose lifecycle magicmirror@2.11.0~install: CWD: /home/pi/MagicMirror 28901 silly lifecycle magicmirror@2.11.0~install: Args: [ '-c', 28901 silly lifecycle 'echo "Installing vendor files ...\n" && cd vendor && npm install --loglevel=error' ] 28902 silly lifecycle magicmirror@2.11.0~install: Returned: code: 0 signal: null 28903 silly postinstall magicmirror@2.11.0 28904 info lifecycle magicmirror@2.11.0~postinstall: magicmirror@2.11.0 28905 verbose lifecycle magicmirror@2.11.0~postinstall: unsafe-perm in lifecycle true 28906 verbose lifecycle magicmirror@2.11.0~postinstall: PATH: /usr/share/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/pi/MagicMirror/node_modules/.bin:/usr/local /sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games 28907 verbose lifecycle magicmirror@2.11.0~postinstall: CWD: /home/pi/MagicMirror 28908 silly lifecycle magicmirror@2.11.0~postinstall: Args: [ '-c', 28908 silly lifecycle 'npm run install-fonts && echo "MagicMirror installation finished successfully! \n"' ] 28909 silly lifecycle magicmirror@2.11.0~postinstall: Returned: code: 139 signal: null 28910 info lifecycle magicmirror@2.11.0~postinstall: Failed to exec postinstall script 28911 verbose stack Error: magicmirror@2.11.0 postinstall: `npm run install-fonts && echo "MagicMirror installation finished successfully! 28911 verbose stack "` 28911 verbose stack Exit status 139 28911 verbose stack at EventEmitter.<anonymous> (/usr/share/npm/node_modules/npm-lifecycle/index.js:283:16) 28911 verbose stack at EventEmitter.emit (events.js:189:13) 28911 verbose stack at ChildProcess.<anonymous> (/usr/share/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14) 28911 verbose stack at ChildProcess.emit (events.js:189:13) 28911 verbose stack at maybeClose (internal/child_process.js:970:16) 28911 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:259:5) 28912 verbose pkgid magicmirror@2.11.0 28913 verbose cwd /home/pi/MagicMirror 28914 verbose Linux 4.19.0-8-amd64 28915 verbose argv "/usr/bin/node" "/usr/bin/npm" "install" 28916 verbose node v10.15.2 28917 verbose npm v5.8.0 28918 error code ELIFECYCLE 28919 error errno 139 28920 error magicmirror@2.11.0 postinstall: `npm run install-fonts && echo "MagicMirror installation finished successfully! 28920 error "` 28920 error Exit status 139 28921 error Failed at the magicmirror@2.11.0 postinstall script. 28921 error This is probably not a problem with npm. There is likely additional logging output above. 28922 verbose exit [ 139, true ]
–jg3
-
@sdetweil … I tried using the installer (it looks cool!) but it failed in the same place with apparently the same error.
I’m new to Magic Mirror and … i guess I’m glad I tried it on a VM before I ordered hardware? … any suggestions on what’s causing this would be obliged.
-
@jg3 can u show me the ~/install.log
I suspect its a downlevel npm problem… 6.13.4 is the latest on buster on my pi 3 and 4
so, u are running and arm (pi) virtual machine, on an intel box (esx)?
-
@sdetweil Hi Sam, thanks for the reply.
I’m running raspberry pi on an emulated x86 processor:
pi@raspberry:~ $ uname -a Linux raspberry 4.19.0-8-amd64 #1 SMP Debian 4.19.98-1 (2020-01-26) x86_64 GNU/Linux
Below is my ~/install.log. Because the error comes at the very, very end of the install things seem to work OK, but some MM modules will show the same error when they install. Also note that I had installed and updated npm before running the installer.
pi@raspberry:~ $ more install.log install starting - Sun Apr 5 02:03:49 EDT 2020 installing on x86_64 processor system the os is Distributor ID: Debian Description: Debian GNU/Linux 10 (buster) Release: 10 Codename: buster user stopped install on x86_64 hardware install starting - Sun Apr 5 02:10:26 EDT 2020 installing on x86_64 processor system the os is Distributor ID: Debian Description: Debian GNU/Linux 10 (buster) Release: 10 Codename: buster Updating packages ... Hit:1 http://security.debian.org buster/updates InRelease Hit:2 https://deb.nodesource.com/node_10.x buster InRelease Hit:3 http://archive.ras pberrypi.org/debian buster InRelease Hit:4 http://ftp.debian.org/debian buster InRelease Hit:5 http://ftp.debian.org/debian buster-updates InR elease Reading package lists... apt-get update completed ok apt-get upgrade started apt upgrade result =rc=0 Reading package lists... Building dependency tree... Reading state information... Calculating upgrade... 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Installing helper tools ... Reading package lists... Building dependency tree... Reading state information... build-essential is already the newest version (12.6). git is already the newest version (1:2.20.1-2+deb10u1). unzip is already the newest version (6.0-23+deb10u1). wget is already the newest version (1.20.1-1.1). wget set to manually installed. curl is already the newest version (7.64.0-4+deb10u1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Check current Node installation ... Node currently installed. Checking version number. Minimum Node version: v10.1.0 Installed Node version: v10.15.2 No Node.js upgrade necessary. Check current NPM installation ... NPM currently installed. Checking version number. Minimum npm version: V6.0.0 Installed npm version: V6.14.4 No npm upgrade necessary. Cloning MagicMirror ... Cloning MagicMirror Done! Installing dependencies ... Unable to install dependencies! install starting - Sun Apr 5 02:11:06 EDT 2020 installing on x86_64 processor system the os is Distributor ID: Debian Description: Debian GNU/Linux 10 (buster) Release: 10 Codename: buster Updating packages ... Hit:1 http://security.debian.org buster/updates InRelease Hit:2 https://deb.nodesource.com/node_10.x buster InRelease Hit:3 http://archive.ras pberrypi.org/debian buster InRelease Hit:4 http://ftp.debian.org/debian buster InRelease Hit:5 http://ftp.debian.org/debian buster-updates InR elease Reading package lists... apt-get update completed ok apt-get upgrade started apt upgrade result =rc=0 Reading package lists... Building dependency tree... Reading state information... Calculating upgrade... 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Installing helper tools ... Reading package lists... Building dependency tree... Reading state information... build-essential is already the newest version (12.6). git is already the newest version (1:2.20.1-2+deb10u1). unzip is already the newest version (6.0-23+deb10u1). wget is already the newest version (1.20.1-1.1). curl is already the newest version (7.64.0-4+deb10u1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Check current Node installation ... Node currently installed. Checking version number. Minimum Node version: v10.1.0 Installed Node version: v10.15.2 No Node.js upgrade necessary. Check current NPM installation ... NPM currently installed. Checking version number. Minimum npm version: V6.0.0 Installed npm version: V6.14.4 No npm upgrade necessary. It seems like MagicMirror is already installed. To prevent overwriting, the installer will be aborted. Please rename the ~/MagicMirror folder and try again. If you want to upgrade your installation run upgrade-script from the ~/MagicMirror/installers directory. install starting - Sun Apr 5 02:11:40 EDT 2020 installing on x86_64 processor system the os is Distributor ID: Debian Description: Debian GNU/Linux 10 (buster) Release: 10 Codename: buster Updating packages ... Hit:1 http://security.debian.org buster/updates InRelease Hit:2 https://deb.nodesource.com/node_10.x buster InRelease Hit:3 http://archive.ras pberrypi.org/debian buster InRelease Hit:4 http://ftp.debian.org/debian buster InRelease Hit:5 http://ftp.debian.org/debian buster-updates InR elease Reading package lists... apt-get update completed ok apt-get upgrade started apt upgrade result =rc=0 Reading package lists... Building dependency tree... Reading state information... Calculating upgrade... 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Installing helper tools ... Reading package lists... Building dependency tree... Reading state information... build-essential is already the newest version (12.6). git is already the newest version (1:2.20.1-2+deb10u1). unzip is already the newest version (6.0-23+deb10u1). wget is already the newest version (1.20.1-1.1). curl is already the newest version (7.64.0-4+deb10u1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Check current Node installation ... Node currently installed. Checking version number. Minimum Node version: v10.1.0 Installed Node version: v10.15.2 No Node.js upgrade necessary. Check current NPM installation ... NPM currently installed. Checking version number. Minimum npm version: V6.0.0 Installed npm version: V6.14.4 No npm upgrade necessary. Cloning MagicMirror ... Cloning MagicMirror Done! Installing dependencies ... Unable to install dependencies! pi@raspberry:~ $
-
@jg3 hm… i would erase the ~/.npm folder (rm -rf ~/.npm) and try install again
-
@sdetweil Because you’d recommended that to the OP I gave that a try but it didn’t make a difference.
Like I said, the MM is running now but I’d be a lot more comfortable if I could get to the bottom of this and a couple of other small things.
Thank you kindly for the replies.
-
@jg3 k, tell me how you set that up so I can try to recreate…
i have virtualbox, and vmware Workstation… no esx around tho
I run macOS catalina, Ubuntu 19.04, and Zorin vms and install MM on all of them without problem
(VMs under vmware). my vmware host is either windows 10 or Ubuntu Mate 18.04 (dual boot)ah, i see raspian for x86… downloading now
-
@jg3 ok, this is a bug in the installer for the roboto-fontface package
if u edit the ~/MagicMirror/fonts/package.json, and change
"dependencies": { "roboto-fontface": "^0.8.0" }
to
"dependencies": { "roboto-fontface": "latest" }
it will work…