Netfx3 windows server 2019 как включить

Установка .NET Framework 3.5 на Windows Server 2012/2016

Запустите службу «Центр обновления Windows»

Нажмите «Пуск» и выберите «Администрирование»:

framework_1.png

В открывшемся окне перейдите в «Службы»:

framework_2.png

Нажмите правой кнопкой мыши на службе «Центр обновления Windows» и выберите «Свойства»:

framework_3.png

Установите тип запуска «Вручную» и нажмите «ОK»:

framework_4.png

Запустите службу:

framework_5.png

Установите .NET Framework 3.5

Нажмите «Пуск» и откройте «Диспетчер серверов»:

framework_6.png

Нажмите «Управление» и выберите «Добавить роли и компоненты»:

framework_7.png

Нажмите «Далее»:

framework_8.png

«Далее»:

framework_9.png

 «Далее»:

framework_10.png

«Далее»:

framework_11.png

«Далее»:

framework_12.png

Поставьте галочку напротив компонента «Функции .NET Framework 3.5» и нажмите «Далее»:

framework_13.png

Нажмите «Установить»:

framework_14.png

Дождитесь завершения установки:

framework_16.png

Можете закрыт окно, — .NET Framework 3.5 установлен. 

Установка .NET Framework 3.5 на Windows Server 2019

1. Скачайте архив с необходимыми компонентами sources.zip

2. Распакуйте файлы в корень диска С:\:

framework_20.png

3. Запустите «Командную строку» от имени администратора:

framework_19.png

4. Выполните команду с учётом пути к распакованным файлам из архива:
DISM /Online /Enable-Feature /FeatureName:NetFx3 /All /LimitAccess /Source:C:\sxs

framework_17.png

Таким образом компонент Microsoft .NET Framework 3.5 установлен.


Estimated reading: 1 minute


2125 views

I. Using Command Prompt

1. Run Command Prompt as Administrator

2. Execute the following command

DISM /Online /Enable-Feature /FeatureName:NetFx3 /All

An alternative option is to use the Server Manager software that was originally used to install and setup the server. Ensure that your account has administrative privileges before proceeding.

II. Using Server Manager

1. First you need to open the Server Manager on the system where you want to install the .NET Framework 3.5.

2. In the Server Manager, open the “Add Roles and Features” Wizard by clicking Manage –> Add Roles and Features.

3. Step forward to “Installation Type” and select “Role-based or feature-based installation”

4. Select the destination server for installation.

5. Click on “Features” and select the sub-feature ” .NET Framework 3.5 (includes 2.0 and 3.0)” under .NET Framework 3.5 Features.

6. Now, we get to the “Confirmation” step. Click “Install” to begin the installation.

7. Installation should have now succeed.

Большинство современных приложений Windows требуют наличия установленного .NET Framework. Например, в Windows 11/10 и Windows Server 2022/2019 по умолчанию уже установлена версия NET Framework 4.8. Однако некоторые старые приложения требуют наличия установленного .NET Framework 3.5, 2.0 или даже 1.0.

В этой статье мы рассмотрим, как установить .NET 3.5 в Windows 11/10 и Windows Server 2022/2019/2016.

Содержание:

  • Установка .NET Framework 3.5 в Windows 11 и 10
  • Как установить .NET 3.5 в Windows Server 2022/2019/2016?
  • Настройка параметров офлайн установка .Net 3.5 помощью GPO

Установка .NET Framework 3.5 в Windows 11 и 10

Проверьте, что .NET Framework 3.5 (включает в себя .NET 2.0 и 3.0) не установлен на вашем компьютере. Для этого, откройте консоль PowerShell с правами администратора и выполните команду:

Get-WindowsCapability -Online -Name NetFx3~~~~

Get-WindowsCapability NetFx3 не установлен в Windows 11

В нашем случае .NET 3.5 не установлен (
State=NotPresent
).

В Windows 10/11 вы можете установить .Net Framework из панели Turn Windows Features on or off:

  1. Выполните команду
    optionalfeatures.exe
    ;
  2. В списке компонентов выберите .NET Framework 3.5 (includes .NET 2.0 and 3.0), нажмите ОК;
    Установка .Net Fframework 3.5 через панель управления Windows 11

  3. Если на вашем компьютере есть доступ в Интернет, в следующем окне выберите Let Windows Update download the files for you;
  4. win10 онлайн установки .net 3.5

  5. Windows скачает и установить последнюю версию компонента .NET Framework 3.5 с серверов Microsoft Update.
    загрузка net framework из интернета

Также вы можете установить .NET Framework 3.5 из командной строки:

  • С помощью DISM:
    DISM /online /Enable-Feature /FeatureName:"NetFx3"
  • Из PowerShell:
    Enable-WindowsOptionalFeature -Online -FeatureName "NetFx3"

Если ваш компьютер не подключен к интернету или находится в изолированной сети, то при установке .NET 3.5 появится ошибка:

Windows couldn’t complete the requested changes.
The changes couldn’t be completed. Please reboot your computer and try again.
Error code: 0x8024402C

0x8024402C ошибка установк net 3.5 в windows

В этом случае вы можете вручную установить компоненты NET 3.5 с вашего установочного образа (диска) Windows. Для этого вам понадобится установочная USB флешка или файл с ISO образом вашей версии Windows (как проверить версию Windows в ISO образе):

  1. Подключите ваш носитель с ставочным образом Windows к компьютеру. В моем случае у меня есть файл Windows11-22h2.iso. Щелкните по файлы и выберите Mount, чтобы смонтировать образ в виртуальный DVD привод (или воспользуйтесь командой PowerShell:
    Mount-DiskImage -ImagePath "C:\distr\Windows11-22h2.iso"
    );
  2. В моем случае виртуальному приводу с образом была назначена буква диска E: (мы будем использовать эту букву в следующих командах);
  3. Чтобы установить .Net 3.5 из файлов компонентов на установочном диске выполните команду:
    DISM /online /enable-feature /featurename:NetFX3 /All /Source:E:\sources\sxs /LimitAccess

    Или (аналогичная PowerShell команда):
    Add-WindowsCapability -Online -Name NetFx3~~~~ -Source E:\Sources\SxS

Add-WindowsCapability netfx3 установка из PowerShell

Чтобы проверить, что .NET Framework успешно установлен, выполните команду:

Get-WindowsCapability -Online -Name NetFx3~~~~

Name         : NetFX3~~~~
State        : Installed
DisplayName  : .NET Framework 3.5 (includes .NET 2.0 and 3.0)
Description  : .NET Framework 3.5 (includes .NET 2.0 and 3.0)
DownloadSize : 72822163
InstallSize  : 496836410

проверить что netfx3 установлен в Windows

Выведите список версий .NET Framework, которые установлены на вашем компьютере:

Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP' -Recurse | Get-ItemProperty -Name version -EA 0 | Where { $_.PSChildName -Match ‘^(?!S)\p{L}’} | Select PSChildName, version

[/alert]

Как установить .NET 3.5 в Windows Server 2022/2019/2016?

В Windows Server 2022,2019,2016 и 2012 R2 вы можете установить NET Framefork 3.5 несколькими способам:

  • ерез Server Manager (Add roles and features -> Features -> .NET Framework 3.5 Features -> .NET Framework 3.5 (includes .NET 2.0 and 3.0 );
  • С помощью DISM:
    DISM /Online /Enable-Feature /FeatureName:NetFx3 /All
  • С помощью PowerShell:
    Install-WindowsFeature NET-Framework-Core

При этом установочные файлы .NET 3.5 для вашей версии Windows Server будут загружены с серверов Windows Update. Чтобы сработал этот метод установки нужно убедиться:

  1. Ваш Windows Server должен иметь прямой доступ в Интернет. Настройки прокси-сервера и файервола не должны ограничивать доступ к серверам Windows Update.
  2. Хост не должен быть настроен на получения обновлений с локального WSUS сервера (проверьте настройки обновлений Windows в групповых политиках или напрямую в реестре);

    Проверьте значение параметра UseWUServer в реестре:
    Get-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" -Name "UseWUServer" | select -ExpandProperty UseWUServer
    Если значение параметра равно 1, значить ваш хост будет пытаться получить обновления с локального WSUS сервера. В этом случае при установке .NET 3.5 появится ошибка 0x800F0954. Измените значение параметра на 0 или удалите его, чтобы подключиться напрямую к серверам обновлений Windows Update.

Если ваш сервер имеет доступ в Интернет, но настроен на получение обновлений со WSUS, при устапновке NET Framework появится ошибка 0x800f081f.

Решение: установить .Net 3.5 онлайн с серверов Microsoft и игнорировать локальный WSUS:

  • Экспортируйте в reg файл текущие настройки Windows Update в ветке HKLM\Software\Policies\Microsoft\Windows\WindowsUpdate (
    reg export HKLM\Software\Policies\Microsoft\Windows\WindowsUpdate c:\WindowsUpdateRegFile.reg
    )
  • Удалите данную ветку (
    Remove-Item -Path HKLM:\Software\Policies\Microsoft\Windows\WindowsUpdate -Recurse
    ) и перезапустите службу:
    net stop wuauserv & net start wuauserv
  • Запустите установку .Net из Интернета:
    DISM /Online /Enable-Feature /FeatureName:NetFx3 /All
  • После окончания установки верните настройки WU, импортировав reg файл (
    Reg import c:\WindowsUpdateRegFile.reg
    ) и еще раз перезапустите службу Windows Update

Если с вашего сервера нет прямого доступа в Интернет, то при попытке установить .NET 3.5 в Windows Server через консоль Server Manager появится ошибка 0x800F081F (The source files could not be found), 0x800F0950, 0x8024402c, 0x800F0906 или 0x800F0907 (в зависимости от версии Windows Server).

.net3.5 ошибка установки 0x800f081f The source files could not be found

Хотя .NET Framework 3.5 присутствует в списке компонентов Windows Server 2022/2019/2016/2012R2, на самом деле его бинарные файлы в хранилище компонентов Windows отсутствуют (концепция Features on Demand). Это сделано, чтобы уменьшить размер образа операционной системы на диске. Вы можете проверить наличие.NET Framework 3.5 в локальном хранилище компонентов Windows Server с помощью команды:

Get-WindowsFeature *Framework*

windows server 2019 status компонента NET-Framework-Core в хранилище Removed

Как вы видите статус компонента
NET-Framework-Core
Removed.

Для установки NET-Framework-Core вам потребуется дистрибутив с вашей версией Windows Server в виде ISO файла, или в распакованном виде в сетевой папке. Смонтируйте ISO образ с дистрибутивом в отдельный виртуальный диск (например, диск D:).

Теперь вы можете установить .Net Framework 3.5 с помощью графической консоли Server Manager:

Установить компонент .Net 3.5 можно из графической консоли Server Manager. Для этого выберите компонент .Net Framework 3.5 Features, но, перед тем, как нажать кнопку Install, нажмите небольшую ссылку внизу мастера — Specify an alternative source path.

  1. Для этого выберите компонент .Net Framework5 Features. Перед тем, как нажать кнопку Install, нажмите на ссылку Specify an alternative source path внизу;
    Specify an alternative source path

  2. Укажите путь к хранилищу компонентов (SXS) дистрибутива Windows Server. Если вы смонтировали дистрибутив в виртуальный привод, это может быть путь
    D:\sources\sxs
    . Также это может быть сетевая папка, куда вы предварительно скопировали дистрибутив (например,
    \\server1\distr\ws2022\sources\sxs
    ). Нажмите ОК.

    D:\sources\sxs

Гораздо проще установить компонент Net Framework 3.5 Features из командной строки или консоли PowerShell, запущенной с правами администратора. Просто выполните команду:

Dism.exe /online /enable-feature /featurename:NetFX3 /All /Source:D:\sources\sxs /LimitAccess

Dism.exe /online /enable-feature /featurename:NetFX3 /All /Source:D:\sources\sxs /LimitAccess

Где
D:\
— диск с вашим дистрибутивом Windows Server.

Параметр LimitAccess запрещает DISM подключение к серверам обновлений для получения установочных файлов компонентов. Используются только файлы в указанном каталоге.

Если вы хотите установить компонент Windows Server с помощью PowerShell, воспользуйтесь командой Add-WindowsFeature:

Add-WindowsFeature NET-Framework-Core -Source d:\sources\sxs

После завершения установки компонента, перезагрузка сервера не требуется.

Также вы можете вручную скопировать 2 cab файла
microsoft-windows-netfx3...
из каталога sources\sxs вашего дистрибутива. В этом случае для установки .Net 3.5 достаточно выоплнить команду:

dism /online /Add-Package /PackagePath:C:install\net35\microsoft-windows-netfx3-ondemand-package~31bf3856ad364e35~amd64~~.cab.

Настройка параметров офлайн установка .Net 3.5 помощью GPO

С помощью групповой политики Specify settings for optional component installation and component repair (находится в разделе GPO Computer Configuration -> Administrative Templates -> System) можно настроить особые параметры установки компонентов Windows из локального источника или Windows Update даже при использовании WSUS.

На отдельностоящем компьютере вы можете включить этот параметр политики с помощью редактора локальной GPO (gpedit.msc). В среде Active Directory вы можете создать политику для всех компьютеров/серверов с помощью консоли GPMC.

Здесь можно указать, что при установки или восстановлении компонентов Windows необходимо всегда загружать файлы из Интернета с серверов Windows Update вместо локального WSUS (опция Download repair content and optional features directly from Windows Update instead of Windows Server Update Services — WSUS).

Также можно указать путь к каталогу с компонентами Windows Server (или wim файлу), который нужно использовать при офлайн установке (указывается в параметр Alternate source file path). Вы можете указать:

    • Путь к сетевой папке в UNC формате (
      \\server\distr\ws2016\sxs
      ) (здесь можно указать несколько UNC путей через точки с запятой:
      \\srv1\ws22\sxs;\\fs01\ws22\sxs;\\fs3\sxs
  • Также допустимо указывать WIM файл в качестве источника:
    WIM:\\srv1\distr\ws2016\install.wim:2
    (в этом случае
    2
    – это индекс образа вашей редакции Windows Server в WIM файле. Список доступных редакций в файле можно вывести так:
    DISM /Get-WimInfo /WimFile:"\\server\distr\ws2016\install.wim"
    )

gpo: -Specify intranet Microsoft update service location

Для разных версий Windows Server нужно использовать разные источники с каталогом SXS. Если в вашей сети есть несколько версии Windows Server, нужно создать отдельные GPO с разными UNC путями к сетевой папке с SXS. Чтобы GPO применялась только к хостам с определенными версиями Windows Server, можно использовать WMI фильтры групповых политик.

By default, .NET Framework 3.5 is not installed on Server 2019 and also the sources are not getting installed. If you open Roles and Features and select the feature and start the installation you are likely to get an error message (0x800F0950). The same is true when you download it from the Microsoft content server and try to install it by dism or Enable-WindowsOptionalFeature.

You have to take the sources from the sources\sxs folder of the Server 2019 iso file. If you have the installation DVD still inserted (which is usually the case if you set up a virtual machine) you can enter the path (probably d:\sources\sxs) on the Confirmation page of the Add-Roles-And-Features-wizard by selecting Specify an alternate source path.

Alternatively, mount the iso by double-clicking it (Win8 or later), copy the 2 microsoft-windows-netfx3… cab files in the folder sources\sxs and paste them to your server. Afterwards, you can call

dism /online /Add-Package /PackagePath:[sourcepath]\microsoft-windows-netfx3-ondemand-package~31bf3856ad364e35~amd64~~.cab.

Table of Contents

Introduction

Oddly enough, this has been my most popular blog post in the past nine years I’ve been running this blog.

This blog post has been updated often and was initially written for Windows Server 2012, but it is still applicable today.
Interestingly, installing Dotnet 3.5 is the same as almost ten years ago.

The latest version of Microsoft .NET Framework 3.5 is .NET Framework 3.5 (3.5.1) Service Pack 1.

It is now possible to install .NET Framework 3.5 SP1 using the GUI, Powershell, DISM, or the Offline Installer.
Which method you prefer is up to preference.

Like most people having issues installing .NET Framework 3.5 on your server or client machine, read this blog post to clarify this question.

This blog post focuses on installing .NET Framework 3.5 on Windows Server 2012, Windows Server 2016, Windows Server 2019, and Windows 10.

Where do I find the .NET Framework 3.5 installation status?

If you want to verify if .NET Framework 3.5 has been installed on your client, the easiest way is to do this via the Control Panel.

Here is how to check if .NET 3.5 is installed on Windows 10:

Open the Control Panel and go to Programs and Features.

Press Turn Windows features or off.

Windows 10 - Control Panel - Programs and Features - Turn Windows features on or off

Verify if .NET Framework 3.5 (Includes .NET 2.0 and 3.0) is enabled.

If you see the same as in the below screenshot, .NET Framework 3.5 is installed.

Windows 10 - Turn Windows features on or off

This blog post describes how to install .NET Framework 3.5 SP1 using:

  1. Command-line (DISM)
  2. Powershell
  3. Server Manager (GUI)
  4. Offline Installer

Unfortunately, installing Microsoft .NET Framework 3.5 is not as straightforward as you think. Microsoft has a guide for installing .NET Framework 3.5, but it does not provide the whole story.

.NET Framework 3.5 - Do you need to specify an alternate source path?

.NET Framework 3.5 comes with the Windows 10 DVD and is located in the \sources\sxs folder.

Versions of .NET Framework 3.5 on Windows 10

Note that when installing .NET Framework 3.5, they are version specific. You need to install .NET 3.5, which comes with each Windows 10 version. So, for Windows 10 2004, you will need to install .NET 3.5 from that media, 1909 from that media, and so on.

How to Install .NET 3.5 using DISM

Start an elevated command prompt using Run as Administrator and enter this command:

dism /online /enable-feature /featurename:NetFX3 /all /Source:d:\sources\sxs /LimitAccess

Note: The source should be the Windows installation disc. In my case, the media was located on D:.

Install .NET Framework 3.5 using DISM

Install .NET Framework 3.5 using DISM

Powershell command to install .NET Framework 3.5

It is also possible to install .NET Framework 3.5 using Powershell.

Run Powershell with elevation and use this command to accomplish this:

Add-WindowsCapability –Online -Name NetFx3~~~~ –Source D:\sources\sxs

Install .NET Framework 3.5 using the Server Manager

Go down to Specify an alternate source path and enter this in the path:

 <media drive>\sources\sxs
Specify an alternate source path when installing .NET Framework 3.5

Enter the source path, which should be the Windows 10 installation media.

Specify alternate source path in Add Roles and Features Wizard when installing .NET Framework 3.5

Install .NET Framework 3.5 using the offline installer

You can also install .NET Framework 3.5 offline using the Offline Installer: https://www.microsoft.com/en-us/download/confirmation.aspx?id=25150.

Review installation of .NET Framework 3.5

Once you have followed one of the above three installation methods, verify the .NET Framework 3.5 Feature installation status using:

  1. The GUI
  2. Powershell

Review installation of .NET Framework 3.5 using the Server Manager

If you open Server Manager and open Add Roles and Features, see the following for the .NET Framework 3.5 installation:

Review installation of .NET Framework 3.5 using Powershell

Use the below Powershell command to see if .NET Framework 3.5 is installed and with which subversions:

(Get-ItemProperty -Path "HKLM:\SOFTWARE\MicrosoftNET Framework Setup\NDPv3.5").Version

Conclusion

Incredibly, this is still an issue and my most popular blog post on this site.

The possibility to install .NET Framework 3.5 using Powershell is improved, but not much more.

Even though .NET Framework 3.5 is an old library, we will likely see it as a prerequisite in the upcoming years.

When did you first encounter this issue, and is it still applicable to you?

Please leave a comment below with your answer!

References

  • Microsoft Docs – Install .NET Framework 3.5

Related posts

  • How to check Bitlocker encryption status using different methods

Понравилась статья? Поделить с друзьями:
0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии
  • Не работает собака на клавиатуре windows 10
  • Как перейти в среду восстановления windows 10
  • Whatsapp for windows 10 mobile
  • Как создать кнопку сон на рабочем столе windows 10
  • Как узнать какая видеокарта стоит на ноутбуке windows 10 про