SharePoint 2013 Pre Requisites Downloader

SharePoint 2013 Pre Requisites Downloader

Update:

SharePoint 2013 has RTM’d. If you are still working off Public Beta bits please check the section of Public Beta as the Pre reqs that get downloaded are different.

RTM Edition

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
###############SharePoint 2013 Pre Requisite Software Downloader############
############################################################################
###Author: Aben Samuel####Date:27/10/2012###################################
##########Version:2#########################################################

#####URL#####EDIT IF Microsoft Makes Changes to the URL#####################
$UrlList = ("http://download.microsoft.com/download/1/E/3/1E3220BD-1D17-4EE7-8D7F-333422D1BA4B/enu_netfx/x64/netfx_full_x64.msi", # Microsoft .NET Framework 4.5
"http://download.microsoft.com/download/5/2/B/52B59966-3009-4F39-A99E-3732717BBE2A/Windows6.1-KB2506143-x64.msu", # Windows Management Framework 3.0 (CTP2)
"http://download.microsoft.com/download/9/1/3/9138773A-505D-43E2-AC08-9A77E1E0490B/1033/x64/sqlncli.msi", #Microsoft SQL Server 2008 r2 Native Client
"http://download.microsoft.com/download/D/7/2/D72FD747-69B6-40B7-875B-C2B40A6B2BDD/Windows6.1-KB974405-x64.msu", #Windows Identity Foundation (KB974405)
"http://download.microsoft.com/download/E/0/0/E0060D8F-2354-4871-9596-DC78538799CC/Synchronization.msi", # Microsoft Sync Framework Runtime v1.0 SP1 (x64)
"http://download.microsoft.com/download/A/6/7/A678AB47-496B-4907-B3D4-0A2D280A13C0/WindowsServerAppFabricSetup_x64.exe", #Windows Server AppFabric
"http://download.microsoft.com/download/0/1/D/01D06854-CA0C-46F1-ADBA-EBF86010DCC6/r2/MicrosoftIdentityExtensions-64.msi", # Windows Identity Extensions
"http://download.microsoft.com/download/9/1/D/91DA8796-BE1D-46AF-8489-663AB7811517/setup_msipc_x64.msi", # Microsoft Information Protection and Control Client
"http://download.microsoft.com/download/8/F/9/8F93DBBD-896B-4760-AC81-646F61363A6D/WcfDataServices.exe", # Microsoft WCF Data Services 5.0
"http://download.microsoft.com/download/7/B/5/7B51D8D1-20FD-4BF0-87C7-4714F5A1C313/AppFabric1.1-RTM-KB2671763-x64-ENU.exe" # CU Package 1 for Microsoft AppFabric 1.1 for Windows Server (KB2671763)
)
####Destination Directory for the files to be downloaded######################
$DestPath = "C:\SP2013B2"

######################################DO NOT EDIT BELOW THIS LINE##################################################
###################################################################################################################

Write-Warning "Executing Script"
##Importing Bits Module######
Import-Module BitsTransfer
Write-Host

######HouseKeeping#################################################################################################
###################################################################################################################
Remove-Item $DestPath -recurse -erroraction SilentlyContinue
New-Item $DestPath -type directory -erroraction SilentlyContinue
"Folder Created"
Write-Host
## Check that the path entered is valid
If (Test-Path "$DestPath" -Verbose)
{
## If destination path is valid, create folder if it doesn't already exist
$DestFolder = "$DestPath\PrerequisiteInstallerFiles"
New-Item -ItemType Directory $DestFolder -ErrorAction SilentlyContinue
}
Else
{
Write-Warning " - Destination path appears to be invalid."
## Pause
Write-Host " - Please check the path, and try running the script again."
Write-Host "- Press any key to exit..."
$null = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown")
break
}

#########Downloading#################################################################################################
#####################################################################################################################

ForEach ($Url in $UrlList)
{

$DestFileName = $Url.Split('/')[-1]
Try
{

If (!(Test-Path "$DestFolder\$DestFileName"))
{
## Start the download process
Start-BitsTransfer -Source $Url -Destination $DestFolder\$DestFileName -DisplayName "Downloading `'$DestFileName`' to $DestFolder" -Priority High -Description "From $Url..." -ErrorVariable err
If ($err) {Throw ""}
}
Else
{
Write-Host " - File $DestFileName already exists, skipping..."
}
}
Catch
{
Write-Warning " - An error occurred downloading `'$DestFileName`'. Check whether Internet connectivity is enabled on this device"
break
}
}

Write-Host "- Downloads completed"
Invoke-Item $DestFolder
Write-Warning "Press any key to exit"
$null = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown")

Public Beta

SharePoint 2013 Public Beta has been released and we are rushing to getting new VM’s provisioned and getting our hands dirty. Since a lot of us might have started scripting, this is my first release for SharePoint 2013 Pre Requisite Offline Installation Downloader

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
###############SharePoint 2013 Pre Requisite Software Downloader############
############################################################################
###Author: Aben Samuel####Date:20/07/2012###################################
##########Version:1#########################################################

#####URL#####EDIT IF Microsoft Makes Changes to the URL#####################
$UrlList = ("http://download.microsoft.com/download/D/3/0/D30186E3-C7E0-4FD2-8775-FC3B90062B49/dotNetFx45_Full_x86_x64.exe", # Microsoft .NET Framework 4.5
"http://download.microsoft.com/download/5/2/B/52B59966-3009-4F39-A99E-3732717BBE2A/Windows6.1-KB2506143-x64.msu", # Windows Management Framework 3.0 (CTP2)
"http://download.microsoft.com/download/9/1/3/9138773A-505D-43E2-AC08-9A77E1E0490B/1033/x64/sqlncli.msi", #Microsoft SQL Server 2008 r2 Native Client
"http://download.microsoft.com/download/D/7/2/D72FD747-69B6-40B7-875B-C2B40A6B2BDD/Windows6.1-KB974405-x64.msu", #Windows Identity Foundation (KB974405)
"http://download.microsoft.com/download/E/0/0/E0060D8F-2354-4871-9596-DC78538799CC/Synchronization.msi", # Microsoft Sync Framework Runtime v1.0 SP1 (x64)
"http://download.microsoft.com/download/A/6/7/A678AB47-496B-4907-B3D4-0A2D280A13C0/WindowsServerAppFabricSetup_x64.exe", #Windows Server AppFabric
"http://download.microsoft.com/download/0/1/D/01D06854-CA0C-46F1-ADBA-EBF86010DCC6/r2/MicrosoftIdentityExtensions-64.msi", # Windows Identity Extensions
"http://download.microsoft.com/download/9/1/D/91DA8796-BE1D-46AF-8489-663AB7811517/setup_msipc_x64.msi", # Microsoft Information Protection and Control Client
"http://download.microsoft.com/download/8/F/9/8F93DBBD-896B-4760-AC81-646F61363A6D/WcfDataServices.exe", # Microsoft WCF Data Services 5.0
"http://download.microsoft.com/download/7/B/5/7B51D8D1-20FD-4BF0-87C7-4714F5A1C313/AppFabric1.1-RTM-KB2671763-x64-ENU.exe" # CU Package 1 for Microsoft AppFabric 1.1 for Windows Server (KB2671763)
)
####Destination Directory for the files to be downloaded######################
$DestPath = "C:\SP2013B2"

######################################DO NOT EDIT BELOW THIS LINE##################################################
###################################################################################################################

Write-Warning "Executing Script"
##Importing Bits Module######
Import-Module BitsTransfer
Write-Host

######HouseKeeping#################################################################################################
###################################################################################################################
Remove-Item $DestPath -recurse -erroraction SilentlyContinue
New-Item $DestPath -type directory -erroraction SilentlyContinue
"Folder Created"
Write-Host
## Check that the path entered is valid
If (Test-Path "$DestPath" -Verbose)
{
## If destination path is valid, create folder if it doesn't already exist
$DestFolder = "$DestPath\PrerequisiteInstallerFiles"
New-Item -ItemType Directory $DestFolder -ErrorAction SilentlyContinue
}
Else
{
Write-Warning " - Destination path appears to be invalid."
## Pause
Write-Host " - Please check the path, and try running the script again."
Write-Host "- Press any key to exit..."
$null = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown")
break
}

#########Downloading#################################################################################################
#####################################################################################################################

ForEach ($Url in $UrlList)
{

$DestFileName = $Url.Split('/')[-1]
Try
{

If (!(Test-Path "$DestFolder\$DestFileName"))
{
## Start the download process
Start-BitsTransfer -Source $Url -Destination $DestFolder\$DestFileName -DisplayName "Downloading `'$DestFileName`' to $DestFolder" -Priority High -Description "From $Url..." -ErrorVariable err
If ($err) {Throw ""}
}
Else
{
Write-Host " - File $DestFileName already exists, skipping..."
}
}
Catch
{
Write-Warning " - An error occurred downloading `'$DestFileName`'. Check whether Internet connectivity is enabled on this device"
break
}
}

Write-Host "- Downloads completed"
Invoke-Item $DestFolder
Write-Warning "Press any key to exit"
$null = $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown")

 

Updated : 29/07/2012

You may have issues with Search if you do not have the following installed as well. This has been found to be an issue at least on Windows 2008 R2 Sp1 machines.

http://support.microsoft.com/kb/2554876

http://support.microsoft.com/kb/2708075

http://support.microsoft.com/kb/2472264

Cheeri0