Asked by:
WEBpicmd /offline download failed PHP72x64

Question
-
User290465418 posted
I need to make an offline package of php and drivers
WPI 5.0, Windows serwer 2019, 11s 10.
command
WebpiCmd /offline /products:PHP72x64,SQLDriver53PHP72IISx64 /path:C:\WPIOffline
ends with errors below
but
WebpiCmd /install /products:PHP72x64,SQLDriver53PHP72IISx64
works fine.
Any idea?
Marcin
Microsoft Windows [Version 10.0.17763.1397]
(c) 2018 Microsoft Corporation. All rights reserved.C:\Users\Administrator>WebpiCmd /offline /products:PHP72x64,SQLDriver53PHP72IISx64 /path:C:\Pirxon\WPIOffline
The software that you obtain using the Web Platform Installer Command Line Tool is licensed to you by its owner. Microsoft grants you no rights for third party software.
Loading products in online feeds ...Loading products in offline feeds...
Creating offline cache for following products:
PHP72x64
IISManagementConsole
WASConfigurationAPI
NetFx4Extended-ASPNET45
CGI
UrlRewrite2
StaticContent
WASProcessModel
UrlRewrite2Beta
UrlRewrite
FastCGIUpdate
FastCGIBackport
VC14Redist_X64
setx
runphp
PHPManager
PHP53
IIS60
FastCGIIIS6
IIS51
VC9Redist
DefaultDocument
DirectoryBrowse
HTTPErrors
HTTPLogging
LoggingTools
RequestMonitor
RequestFiltering
StaticContentCompression
SQLDriverPHP53IIS
SQLNativeClient
SQLNativeClient_11_0
WinCache53
PHP54
SQLDriverPHP54IIS
MSODBC11
WinCache54
WinCache72x64
SQLDriver53PHP72IISx64
MSODBC17Processing feed: 'https://webpifeed.blob.core.windows.net/webpifeed/EnterpriseProductList.xml'
Processing feed: 'https://webpifeed.blob.core.windows.net/webpifeed/MediaProductList.xml'
Processing feed: 'https://webpifeed.blob.core.windows.net/webpifeed/ToolsProductList.xml'
Processing feed: 'https://webgallery.microsoft.com/feed/webapplicationlist.xml'
Processing feed: 'https://webpifeed.blob.core.windows.net/webpifeed/WebProductList.xml'
Processing resources ...
Processing product entries ...Processing new entries to the offline cache...
Processing product entry: 'UrlRewrite2'.
Url 'http://download.microsoft.com/download/C/9/E/C9E8180D-4E51-40A6-A9BF-776990D8BCA9/rewrite_amd64.msi' returned HTTP status code: 404
The remote server returned an error: (404) Not Found.
Failed to download file: 'http://download.microsoft.com/download/C/9/E/C9E8180D-4E51-40A6-A9BF-776990D8BCA9/rewrite_amd64.msi'.
Download of product 'UrlRewrite2 failed. Failed to download file: 'http://download.microsoft.com/download/C/9/E/C9E8180D-4E51-40A6-A9BF-776990D8BCA9/rewrite_amd64.msi'.
Processing product entry: 'FastCGIIIS6'.
Url 'http://download.microsoft.com/download/E/0/C/E0C0709A-66E5-4113-9A6C-A5F65BF6717D/fcgilicense_1.5_rtw.htm' returned HTTP status code: 404
The remote server returned an error: (404) Not Found.
Failed to download file: 'http://download.microsoft.com/download/E/0/C/E0C0709A-66E5-4113-9A6C-A5F65BF6717D/fcgilicense_1.5_rtw.htm'.
Download of product 'FastCGIIIS6 failed. Failed to download file: 'http://download.microsoft.com/download/E/0/C/E0C0709A-66E5-4113-9A6C-A5F65BF6717D/fcgilicense_1.5_rtw.htm'.
Processing product entry: 'SQLNativeClient_11_0'.
Url 'http://www.microsoft.com/web/webpi/eula/sqlservernativecli.htm' returned HTTP status code: 404
The remote server returned an error: (404) Not Found.
Failed to download file: 'http://www.microsoft.com/web/webpi/eula/sqlservernativecli.htm'.
Download of product 'SQLNativeClient_11_0 failed. Failed to download file: 'http://www.microsoft.com/web/webpi/eula/sqlservernativecli.htm'.
Processing product entry: 'MSODBC11'.
Url 'http://www.microsoft.com/web/webpi/eula/license_msodbcsql_enu.html' returned HTTP status code: 404
The remote server returned an error: (404) Not Found.
Failed to download file: 'http://www.microsoft.com/web/webpi/eula/license_msodbcsql_enu.html'.
Download of product 'MSODBC11 failed. Failed to download file: 'http://www.microsoft.com/web/webpi/eula/license_msodbcsql_enu.html'.
Processing product entry: 'MSODBC17'.Created snapshot '4' at 'C:\Pirxon\WPIOffline\feeds\v004'.
Updated latest snapshot at 'C:\Pirxon\WPIOffline\feeds\latest'.Some operations failed, see the detailed error messages for more information:
Download of product 'UrlRewrite2 failed. Failed to download file: 'http://download.microsoft.com/download/C/9/E/C9E8180D-4E51-40A6-A9BF-776990D8BCA9/rewrite_amd64.msi'.
Skipping download of product 'CGI': required dependency 'UrlRewrite2' failed.
Skipping download of product 'FastCGIBackport': required dependency 'UrlRewrite2' failed.
Skipping download of product 'PHP72x64': required dependency 'FastCGIBackport' failed.
Skipping download of product 'FastCGIUpdate': required dependency 'UrlRewrite2' failed.
Download of product 'FastCGIIIS6 failed. Failed to download file: 'http://download.microsoft.com/download/E/0/C/E0C0709A-66E5-4113-9A6C-A5F65BF6717D/fcgilicense_1.5_rtw.htm'.
Skipping download of product 'PHP53': required dependency 'FastCGIBackport' failed.
Skipping download of product 'PHP54': required dependency 'FastCGIBackport' failed.
Skipping download of product 'PHPManager': required dependency 'PHP54' failed.
Download of product 'SQLNativeClient_11_0 failed. Failed to download file: 'http://www.microsoft.com/web/webpi/eula/sqlservernativecli.htm'.
Skipping download of product 'SQLNativeClient': required dependency 'SQLNativeClient_11_0' failed.
Skipping download of product 'SQLDriverPHP53IIS': required dependency 'SQLNativeClient_11_0' failed.
Skipping download of product 'WinCache53': required dependency 'FastCGIBackport' failed.
Download of product 'MSODBC11 failed. Failed to download file: 'http://www.microsoft.com/web/webpi/eula/license_msodbcsql_enu.html'.
Skipping download of product 'SQLDriverPHP54IIS': required dependency 'MSODBC11' failed.
Skipping download of product 'WinCache54': required dependency 'FastCGIBackport' failed.
Skipping download of product 'WinCache72x64': required dependency 'FastCGIBackport' failed.
Skipping download of product 'SQLDriver53PHP72IISx64': required dependency 'FastCGIBackport' failed.
To use the new offline feed, please run the following from the command line:
WebPiCmd.exe /Install /Products:<products you want> /XML:<Offline main feed>
Done !Tuesday, October 20, 2020 11:27 AM
All replies
-
User-67176070 posted
Did you ever find a solution for this? I can't seem to install PHP74 either because of Urlrewrite2 not being found...
Monday, January 4, 2021 11:12 AM -
User290465418 posted
Unfortunately no.
Monday, January 4, 2021 11:19 AM -
User515338469 posted
From the output, you can see that WebPiCmd fetches the product feed from the URL:
https://webpifeed.blob.core.windows.net/webpifeed/WebProductList.xml
If you download this URL in the browser (give it some time, it is a huge file and very slow), you will see the following:
<feed> <webpiFile version="4.2.0.0"/> <title>Web Platform Installer 5.0 Feed</title> <link rel="enclosure" href="https://aka.ms/webapplicationlist"/> <link rel="enclosure" href="https://webpifeed.blob.core.windows.net/webpifeed/MediaProductList.xml"/> <link rel="enclosure" href="https://webpifeed.blob.core.windows.net/webpifeed/ToolsProductList.xml"/> <link rel="enclosure" href="https://webpifeed.blob.core.windows.net/webpifeed/EnterpriseProductList.xml"/> <link href="https://webpifeed.blob.core.windows.net/webpifeed/WebProductList.xml"/> <updated>2016-10-31T12:00:00.0000000Z</updated>
The feed has apparently not been updated since 2016, and thus most likely it contains download URLs that are no longer valid.
What's funny, though, is that 32-bit installers are downloaded just fine.
Also, funny: The offline cache IS created, and when you try to install from the offline cache, you get an error message "The product is already installed or not available on your platform" and an exit code of 0 (success). I'd say "already installed" and "not available on my platform" are two very different outcomes, but I didn't make this horribly broken product, so what do I know...
Online installation, though, does work, so there is hope...
Monday, March 15, 2021 1:23 PM -
User515338469 posted
Furthermore, if you try online installation, it will print:
The software that you obtain using the Web Platform Installer Command Line Tool is licensed to you by its owner. Microsoft grants you no rights for third party software. Successfully loaded primary feed: https://aka.ms/webpifeed51
If you open https://aka.ms/webpifeed51 in the browser, then it redirects to https://webpifeed.blob.core.windows.net/webpifeed/5.1/WebProductList.xml
But don't get your hopes up: The content and update time are the same, and it contains the same broken links to AMD64 packages.
And yet, by some magic, online installation finds working download URLs for packages, such as http://download.microsoft.com/download/1/2/8/128E2E22-C1B9-44A4-BE2A-5859ED1D4592/rewrite_amd64_en-US.msi . And surprisingly, this working URL can also be found in the feed in the URL I posted above.
So the problem now boils down to WebPiCmd, in /Offline mode, somehow using the wrong download URLs for certain AMD64 packages...
Monday, March 15, 2021 1:31 PM -
User515338469 posted
It gets better:
If you look at the feed (the WebProductList.xml) file generated by WebPiCmd in the offline cache, you will not find an entry for "URLRewrite2". Instead, there is this one:
<productId>UrlRewrite2Beta</productId> <metadata> <title resourceName="Entry_UrlRewrite2Beta_Title">URL Rewrite 2.0 Beta</title> <version>2.0</version> <summary resourceName="Entry_UrlRewrite2Beta_Summary">IIS URL Rewrite provides flexible rules based rewrite engine that can be used to perform a broad spectrum of URL manipulation tasks.</summary> <id>http://www.microsoft.com/web/webpi/urlrewriter</id> <updated>2009-9-23T16:30:00Z</updated> <longSummary resourceName="Entry_UrlRewrite2Beta_LongSummary">URL Rewrite 2.0 for IIS 7 extends its foundation of rule-based URL rewriting with new support for outbound rewrite rules and with new capability to set HTTP request headers and IIS server variables. This new set of features provides administrators with complete control over the URL structure used by existing or legacy web applications that cannot be modified to natively support user and search engine friendly URLs.</longSummary> <published>2009-9-23T12:30:00Z</published>
Oops! This looks ancient!
BTW, speaking of ancient, although the update time of the feed file from the web is something-something-in-2016, the feed contains packages that were published in 2017, such as the URLRewrite 2.1 package with the working download URL. Did Microsoft develop a time machine? And can it be installed with WebPi? Because I want one, too!
Anyway, at this time it looks like when creating the offline cache, WebPiCmd is downloading the WRONG package or the wrong version or installer of it...
Monday, March 15, 2021 1:49 PM -
User515338469 posted
Looking at the feed file, it turns out there are two entries for English X64 installers for URLRewrite2: One with the broken URL that /Offline uses, and one with the working URL that online installation uses. They are both at the same level in the feed XML.
The FIRST entry is the "broken" one:
<!-- x64 English --> <installer> <id>20</id> <languageId>en</languageId> <architectures> <x64/> </architectures> <eulaURL>http://download.microsoft.com/download/6/9/C/69C1195A-123E-4BE8-8EDF-371CDCA4EC6C/License_rtw.htm</eulaURL> <installerFile> <fileSize>6128</fileSize> <installerURL>http://download.microsoft.com/download/C/9/E/C9E8180D-4E51-40A6-A9BF-776990D8BCA9/rewrite_amd64.msi</installerURL> <trackingURL>http://go.microsoft.com/fwlink/?LinkID=615137&clcid=0x409</trackingURL> <sha1>6a98b994adcc2e8d21507bf2b8baffb402c17395</sha1> </installerFile> </installer>
The SECOND entry is the working one:
<!-- x64 English --> <installer> <id>40</id> <languageId>en</languageId> <architectures> <x64/> </architectures> <osList> <os> <minimumVersion> <osMajorVersion>6</osMajorVersion> <osMinorVersion>1</osMinorVersion> </minimumVersion> <osTypes> <Server/> <HomePremium/> <Ultimate/> <Enterprise/> <Business/> </osTypes> </os> </osList> <eulaURL>http://download.microsoft.com/download/D/D/E/DDE57C26-C62C-4C59-A1BB-31D58B36ADA2/URL%20REWRITE%20MODULE-Final-EN.rtf</eulaURL> <installerFile> <fileSize>5936</fileSize> <installerURL>http://download.microsoft.com/download/1/2/8/128E2E22-C1B9-44A4-BE2A-5859ED1D4592/rewrite_amd64_en-US.msi</installerURL> XXX:DOESWORK <trackingURL>http://go.microsoft.com/fwlink/?LinkID=615137&clcid=0x409</trackingURL> <sha1>8F41A67FA49110155969DCCFF265B8623A66448F</sha1> </installerFile> <installCommands> <cmdline> <exe>%SystemRoot%\System32\net.exe</exe> <commandLineArguments>stop was /y</commandLineArguments> <ignoreExitCode>true</ignoreExitCode> </cmdline> <cmdline> <exe>%SystemRoot%\System32\net.exe</exe> <commandLineArguments>stop wmsvc</commandLineArguments> <ignoreExitCode>true</ignoreExitCode> </cmdline> <msiInstall> <msi>%InstallerFile%</msi> </msiInstall> <cmdline> <exe>%SystemRoot%\System32\net.exe</exe> <commandLineArguments>start w3svc</commandLineArguments> <ignoreExitCode>true</ignoreExitCode> </cmdline> <cmdline> <exe>%SystemRoot%\System32\net.exe</exe> <commandLineArguments>start wmsvc</commandLineArguments> <ignoreExitCode>true</ignoreExitCode> </cmdline> </installCommands> </installer>
They are the same, except for the download URLs and for the fact that the second one has installer commands and an OS list, and the first one doesn't.
My theory is now that online installation chooses the second entry, because it matches the client's OS, whereas /offline mode doesn't care about the OS and just uses the first installer it can find.
This brings up the question: What if you wanted to create an offline cache for a specific language or OS or architecture? There is a /Language switch, but none for OS or architecture. This looks like an oversight, but it doesn't even successfully default to the client OS and architecture.
BTW, there is a command called webpicmd-x64.exe, but using it to create the offline cache does not solve the problem. It seems to be identical to webpicmd.exe anyway.
From here, the next step seem to be one of:
- 1. Just download and use the 64-bit MSI file and forget WebPiCmd exists.
- 2. Download the original feed file, remove the cancerous x64 installer entry and try again with the edited feed as a custom feed.
Monday, March 15, 2021 2:03 PM -
User515338469 posted
To anyone who doesn't like the idea of using MSI files directly, and who wishes Microsoft had done a less shitty job at building and maintaining a package manager:
There IS a package manager that has IIS extensions and that works. It's known as Chocolatey.
https://chocolatey.org/packages/UrlRewriteStill hoping on WebPiCmd? Here is some more bad news: WebPiCmd can't even detect that an older version of an extension is installed and then install the latest one. The only way to make WebPiCmd to update, e.g., URLRewrite2, is to delete rewrite.dll from C:\windows\system32\inetsrv. This is ridiculous.
Either just use the MSI file, or use a real package manager.
EDIT: This rant wouldn't be complete without asking: WHY DOES URL REWRITING EVEN HAVE TO BE AN EXTENSION?!
Monday, March 15, 2021 2:17 PM