I would appreciate some assistance installing particle-cli on Windows 7? I am instructor in a high school engineering and robotics shop and we would like to install particle-cli on 22 identical Windows 7 computers. I have installed it on Linux with reasonable success and somehow I got it installed last year on my own Windows 7 machine (I know, I should have taken notes), but I cannot install it on any of the other computers this year. The main problem is that the install errors are in no way consistent and seem to multiply.
Using the Windows Installer (which I run as administrator) never works, but does provide the only consistent error which is that it hangs on “Downloading and installing CLI dependencies” I even had our tech in here to help and he can find no useful info about why it hangs.
I was recently able to get node v10.14.1 and npm v6.4.1 installed and then install particle-cli completely. But then when I tried to use the CLI it would hang after entering the password on particle login though other commands such as particle list would work correctly.
After attempting to reinstall particle-cli the installation now consistently fails with a gyp ERR, even after completely uninstalling Node and reinstalling.
If someone could give me just a starting point I would be happy to work through the problem. I am sure it is possible to install on a standard Windows 7. My engineering students and I would be very grateful!
Node-gyp is a typical frustration that seems to come up in Windows installations at times. It's a frustrating error that Node doesn't always elaborate correctly.
For starters, try running npm install --global --production windows-build-tools as specified below.
Option 1
Install all the required tools and configurations using Microsoft's windows-build-tools using npm install --global --production windows-build-tools from an elevated PowerShell or CMD.exe (run as Administrator).
I did this earlier today as administrator and in powershell. The install did not throw any errors, but I could not run windows-build-tools. I can check the exact error message tomorrow when I am back at school. I think it might have been a problem with the path, but as I investigated that error it seems the path was correct.
Do you have a proxy server on your network or some other sort of firewall that would prevent direct access to download binaries from within the installer? In addition to download the installer, the installer itself, via node.js, will attempt to download many more binaries.
I did just set up another Linux machine running the following as root from inside our school. These set of commands seem to work consistently on Linux.
@stk, I have a Win7x64 VM on my system. Not sure if it is Home or Pro. I will test using the latest CLI installer, NOT via installed node.js. One thing to note is that I will test installing with admin privileges.
If it saves you time @peekay123, I have Windows 7 Pro x64 on my work PC. I have enterprise admin rights and I ran the CLI installer using “Run as Administrator”. No errors. particle version returns “1.35.2”. node --version returns “v8.9.3”. I second @rickkas7’s concern that your firewall blocks the dependency downloads. I would say ping your IT department again but it would help if someone knows which sites/ports need to be open for this install.
It seems that the installer first goes to binaries.particle.io and downloads a file. Then it does a DNS lookup to registry.npmjs.org and does a quick handshake to that server. I cannot see the packet contents because it is encrypted (TLS v1.2 again). Immediately after the handshke to npmjs.org, it starts another download from binaries.particle.io. Doing the packet trace on several different install sessions, the IP address to binaries.particle.io changed several times. Best to white-list the domain rather than an IP address.
I found out (inadvertently) that if we wait long enough, (generally more than two hours) the Particle CLI exe installation will complete with no errors. The problem is that when I run particle from the command line I get
'particle' is not a recognized as an internal or external command,
operable program or batch file.
The same is true for node and npm. When I run particle under admin privileges it recognizes the command but hangs on installing plugins..
Any suggestions? Still waiting to hear back from network IT which is one person for our entire school district.