Comments (9)
I had this problem as well, because I had one of the modules installed but an older version. Updating them in reverse order as below allowed me to get through the module check (if you try to update CloudConnect first, it tries to update MSOnline but not with -allowclobber so it fails).
install-module -name MSOnline -force -allowclobber
install-module -name AzureAD -force -allowclobber
install-module -name cloudconnect -force -allowclobber
from sparrow.
Here's the results of trying to to use the install-module command...
PS C:\scripts> install-module -name MSOnline -force -allowclobber
install-module : The term 'install-module' is not recognized as the name of a cmdlet, function, script file, or
operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try
again.
At line:1 char:1
- install-module -name MSOnline -force -allowclobber
-
+ CategoryInfo : ObjectNotFound: (install-module:String) [], CommandNotFoundException + FullyQualifiedErrorId : CommandNotFoundException
from sparrow.
@DudeLooksLikeASupportTech What version of PowerShell are you running? $PSVersionTable
from sparrow.
I had to set TLS 1.2 - https://devblogs.microsoft.com/powershell/powershell-gallery-tls-support/
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
from sparrow.
PS C:\scripts> $PSVersionTable
Name Value
PSVersion 4.0
WSManStackVersion 3.0
SerializationVersion 1.1.0.1
CLRVersion 4.0.30319.42000
BuildVersion 6.3.9600.19170
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0}
PSRemotingProtocolVersion 2.2
Ran the command below, which seemed to complete just fine...
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
Re-ran one of the install-module commands again, and got the below error...
PS C:\scripts> install-module -name MSOnline -force -allowclobber
install-module : The term 'install-module' is not recognized as the name of a cmdlet, function, script file, or
operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try
again.
At line:1 char:1
- install-module -name MSOnline -force -allowclobber
-
+ CategoryInfo : ObjectNotFound: (install-module:String) [], CommandNotFoundException + FullyQualifiedErrorId : CommandNotFoundException
from sparrow.
Try upgrading: https://www.microsoft.com/en-us/download/details.aspx?id=54616
from sparrow.
Upgraded yesterday before going home, and scheduled a reboot of the server overnight. This morning confirmed that the PSVersion is v5.1.
Ran the command below in an admin-level PS shell, and got the included output...
_PS C:\scripts> install-module -name MSOnline -force
NuGet provider is required to continue
PowerShellGet requires NuGet provider version '2.8.5.201' or newer to interact with NuGet-based repositories. The NuGet
provider must be available in 'C:\Program Files\PackageManagement\ProviderAssemblies' or
'C:\Users\netfrank.KISH\AppData\Local\PackageManagement\ProviderAssemblies'. You can also install the NuGet provider by
running 'Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force'. Do you want PowerShellGet to install
and import the NuGet provider now?
[Y] Yes [N] No [S] Suspend [?] Help (default is "Y"):
WARNING: Unable to download from URI 'https://go.microsoft.com/fwlink/?LinkID=627338&clcid=0x409' to ''.
WARNING: Unable to download the list of available providers. Check your internet connection.
PackageManagement\Install-PackageProvider : No match was found for the specified search criteria for the provider
'NuGet'. The package provider requires 'PackageManagement' and 'Provider' tags. Please check if the specified package
has the tags.
At C:\Program Files\WindowsPowerShell\Modules\PowerShellGet\1.0.0.1\PSModule.psm1:7405 char:21_
I put the failed url into a web browser (https://go.microsoft.com/fwlink/?LinkID=627338&clcid=0x409) , and it seemed to retrieve it just fine...
<!--
This swidtag is a Discovery Feed that has pointers to the SWIDTAGs for
the providers that the bootstrapper can download.
-->
<Link href="https://onegetcdn.azureedge.net/providers/nuget-2.8.5.208.package.swidtag" type="application/swid-tag+xml" rel="package" discovery:name="nuget" discovery:latest="true" discovery:version="2.8.5.208" media="(OS:windows)" />
<Link href="https://onegetcdn.azureedge.net/providers/ChocolateyPrototype-2.8.5.130.package.swidtag" type="application/swid-tag+xml" rel="package" discovery:name="chocolatey" discovery:latest="true" discovery:version="2.8.5.130" media="(OS:windows)" />
<Link href="https://onegetcdn.azureedge.net/providers/nugetv2.feed.swidtag" type="application/swid-tag+xml" rel="feed" discovery:name="nuget" media="(OS:windows)" />
<Link href="https://onegetcdn.azureedge.net/providers/psl.feed.swidtag" type="application/swid-tag+xml" rel="feed" discovery:name="nuget" media="(OS:windows)" />
<Link href="https://onegetcdn.azureedge.net/providers/chocolateyprototype.feed.swidtag" type="application/swid-tag+xml" rel="feed" discovery:name="chocolatey" media="(OS:windows)" />
from sparrow.
Give this a shot. Based on my googling it appears this is a TLS issue: https://stackoverflow.com/a/61246161
from sparrow.
Yeah, sorry, I found that myself shortly before your answer. I reran the command below, which made everything start working...
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
Thanks for the help everyone. Every time I have to deal with powershell I remember why no one does it unless they have to. It always ends in having to fix 15 other problems just to get one script to run.
from sparrow.
Related Issues (20)
- Audit Log search error HOT 2
- Choose your Azure Environment [AzureCloud] HOT 17
- Not Getting output to CSV when Sparrow is run HOT 1
- Expand Script to use Azure AD Logs and Azure Activity logs instead of Unified Audit Log
- What exactly is the expected powershell output? HOT 7
- Readme Update - Explicit Export Information HOT 1
- "Choose Your Environment" comes up blank if AzureADPreview is installed instead of AzureAD module HOT 1
- Add docs on how to setup/retreive credentials HOT 2
- New-ExoPSSession : Access is denied HOT 3
- AppId's in PSLogin_Operations_Export query not in results HOT 5
- Issue while running sparrow.ps1 HOT 1
- Aviary dashboard that works with live o365 data in Splunk
- Run via Taskmanager HOT 1
- Delete
- Having issues running the script for Sparrow ps1
- Error running in GCC High
- Errors connecting to Exchange environment
- How to Upload Dashboard HOT 3
- How do I ingest the csv files into the dashboard? HOT 2
- One more time
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sparrow.