使用 Configuration Manager 建立 Linux 和 UNIX 伺服器應用程式Create Linux and UNIX server applications with Configuration Manager

適用於: Configuration Manager (最新分支)Applies to: Configuration Manager (current branch)

重要

從 1902 版開始,Configuration Manager 不支援 Linux 或 UNIX 用戶端。Starting in version 1902, Configuration Manager doesn't support Linux or UNIX clients.

請考慮以 Microsoft Azure 管理來管理 Linux 伺服器。Consider Microsoft Azure Management for managing Linux servers. Azure 解決方案具有廣泛的 Linux 支援,在大部分情況下都超越 Configuration Manager 的功能性,包括 Linux 的完整修補程式管理。Azure solutions have extensive Linux support that in most cases exceed Configuration Manager functionality, including end-to-end patch management for Linux.

當您針對執行 Linux 和 Unix 的電腦建立和部署應用程式時,請納入下列考量。Take the following considerations into account when you create and deploy applications for computers that run Linux and UNIX.

一般考量General considerations

Linux 和 UNIX 的 Configuration Manager 用戶端支援使用套件和程式進行軟體部署 。The Configuration Manager client for Linux and UNIX supports software deployments that use packages and programs. 您無法將 Configuration Manager 應用程式部署至執行 Linux 和 UNIX 的電腦。You can't deploy Configuration Manager applications to computers that run Linux and UNIX.

Linux 和 UNIX 軟體部署的功能包括:The capabilities of Linux and UNIX software deployment include:

  • 適用於 Linux 和 UNIX 伺服器的軟體安裝,包括下列功能:Software installation for Linux and UNIX servers, including the following capabilities:

    • 新軟體部署New software deployment

    • 已存在於電腦上的程式軟體更新Software updates for programs that are already on a computer

    • OS 修補程式OS patches

  • 原生 Linux 和 UNIX 命令,以及位於 Linux 和 UNIX 伺服器的指令碼Native Linux and UNIX commands, and scripts that are located on Linux and UNIX servers

  • 僅限於您在選取 [僅在指定的用戶端平台上] 程式選項時所指定作業系統的部署Deployments that are limited to the operating systems that you specify when you select the program option Only on specified client platforms

  • 可控制軟體安裝時機的維護期間Maintenance windows to control when software installs

  • 可監視部署的部署狀態訊息Deployment status messages to monitor deployments

  • 用戶端從發佈點下載軟體時,用來節流處理網路使用量的選項The option for the client to throttle network usage when it's downloading software from a distribution point

部署到 Linux 和 UNIX 電腦以及部署到 Windows 裝置之間的差異Differences between deploying to Linux and UNIX computers and deploying to Windows devices

將套件和程式部署到 Linux 和 UNIX 電腦,以及將套件和程式部署到 Windows 裝置之間的主要差異如下:The main differences between deploying packages and programs to Linux and UNIX computers and deploying packages and programs to Windows devices are as follows:

設定Configuration 詳細資料Details
只使用適用於電腦的設定,請勿使用適用於使用者的設定。Use only configurations that are intended for computers, and don't use configurations that are intended for users. 適用於 Linux 和 UNIX 的 Configuration Manager 用戶端不支援適用於使用者的設定。The Configuration Manager client for Linux and UNIX doesn't support configurations that are intended for users.
將程式設定為從發佈點下載軟體,以及從本機用戶端快取執行程式。Configure programs to download software from the distribution point and run the programs from the local client cache. 適用於 Linux 和 UNIX 的 Configuration Manager 用戶端不支援從發佈點執行軟體。The Configuration Manager client for Linux and UNIX doesn't support running software from the distribution point. 您必須將設定改為將軟體下載至用戶端再進行安裝。Instead, you must configure the software to download to the client and then get installed.

根據預設,在 Linux 和 UNIX 的用戶端安裝軟體後,便會從用戶端的快取刪除該軟體。By default, after the client for Linux and UNIX installs software, that software is deleted from the client's cache. 不過,已設定 [將內容保存在用戶端快取中] 的套件在軟體安裝後則不會從用戶端中刪除,而會保留在用戶端的快取中。However, packages that are configured with Persist content in the client cache aren't deleted from the client and remain in the client's cache after the software installs.

適用於 Linux 和 UNIX 的用戶端不支援適用於用戶端快取的設定,而且用戶端快取的大小上限只受限於用戶端電腦上的可用磁碟空間。The client for Linux and UNIX doesn't support configurations for the client cache, and the maximum size of the client cache is limited only by the free disk space on the client computer.
設定供發佈點存取的網路存取帳戶Configure the Network Access Account for distribution point access Linux 和 UNIX 電腦是針對工作群組電腦所設計。Linux and UNIX computers are designed to be workgroup computers. 若要從 Configuration Manager 站台伺服器網域的發佈點中存取套件,您必須設定站台的網路存取帳戶。To access packages from the distribution point in the Configuration Manager site server domain, you must configure the Network Access Account for the site. 您必須先將此帳戶指定為軟體發佈元件內容並設定帳戶,才能部署軟體。You must specify this account as a software distribution component property and configure the account before you deploy software.

您可以在每一網站設定多個網路存取帳戶。You can configure multiple Network Access Accounts at each site. Linux 和 UNIX 的用戶端可使用每一個設定為「網路存取帳戶」的帳戶。The client for Linux and UNIX can use each of the accounts you configure as a Network Access Account.

如需詳細資訊,請參閱 Configuration Manager 的站台元件For more information, see Site components for Configuration Manager.

您可以將套件和程式部署至只含 Linux 或 UNIX 用戶端的集合,或者將套件和程式部署至內含不同用戶端類型的集合,例如 [所有系統集合] 。You can deploy packages and programs to collections that contain only Linux or UNIX clients, or you can deploy them to collections that contain a mix of client types, such as the All Systems Collection. 不過,非 Linux 或非 UNIX 用戶端將不會安裝軟體或報告失敗。However, non-Linux and non-UNIX clients won't install the software or report failure.

當 Linux 和 UNIX 的 Configuration Manager 用戶端接收及執行部署時,會產生狀態訊息。When the Configuration Manager client for Linux and UNIX receives and runs a deployment, it generates status messages. 您可以在 Configuration Manager 主控台中檢視這些狀態訊息,或使用報告監視部署狀態。You can view these status messages in the Configuration Manager console, or by using reports to monitor the deployment status.

如需如何使用套件和程式的相關資訊,請參閱套件和程式For information about how to use packages and programs, see Packages and programs.

設定 Linux 和 UNIX 伺服器的套件、程式和部署Configure packages, programs, and deployments for Linux and UNIX servers

您可以使用 Configuration Manager 主控台中可用的預設選項,來建立及部署套件和程式。You can create and deploy packages and programs by using the available default options in the Configuration Manager console. 用戶端不需要任何唯一設定。The client doesn't require any unique configurations.

請使用以各節所提供的資訊來設定套件和程式,以及部署。Use the information in the following sections to configure packages and programs, and deployments.

封裝和程式Packages and programs

若要建立 Linux 或 UNIX 伺服器的套件和程式,請從 Configuration Manager 主控台使用 [建立套件和程式精靈] 。To create a package and program for a Linux or UNIX server, use the Create Package and Program Wizard from the Configuration Manager console. Linux 和 UNIX 的用戶端支援大部份的套件和程式設定。The client for Linux and UNIX supports most package and program settings. 但是,不支援數個設定。However, several settings aren't supported. 當您建立或設定套件和程式時,請考慮下列幾點:When you create or configure a package and program, consider the following points:

  • 包含目的地電腦所支援的檔案類型。Include the file types that are supported by the destination computers.

  • 定義目的地電腦適用的命令列。Define the command lines that are appropriate for use on the destination computer.

  • 請記住,不支援與使用者互動的設定。Keep in mind that settings that interact with users aren't supported.

下表列出不支援的套件和程式屬性:The following table lists the properties for packages and programs that aren't supported:

套件和程式內容Package and program property 行為Behavior 更多資訊More information
套件共用設定:Package share settings:

- 所有選項- All options
產生錯誤且軟體安裝失敗An error is generated and the software installation fails 用戶端不支援此設定。The client doesn't support this configuration. 用戶端必須改為使用 HTTP 或 HTTPS 下載軟體,然後從其本機快取執行命命列。Instead, the client must download the software by using HTTP or HTTPS, and then run the command line from its local cache.
套件更新設定:Package update settings:

- 中斷使用者與發佈點的連線- Disconnect users from distribution points
忽略設定Settings are ignored 用戶端不支援此設定。The client doesn't support this configuration.
作業系統部署設定:Operating system deployment settings:

- 所有選項- All options
忽略設定Settings are ignored 用戶端不支援此設定。The client doesn't support this configuration.
報告:Reporting:

- 使用套件內容進行狀態 MIF 比對- Use package properties for status MIF matching

- 使用這些欄位進行狀態 MIF 比對- Use these fields for status MIF matching
忽略設定Settings are ignored 用戶端不支援使用狀態 MIF 檔案。The client doesn't support the use of status MIF files.
執行Run:

- 所有選項- All options
忽略設定Settings are ignored 用戶端永遠會執行沒有使用者介面的套件。The client always runs packages with no user interface.

用戶端會忽略 [執行] 的所有設定選項。The client ignores all configuration options for Run.
執行之後:After running:

- Configuration Manager 會重新啟動電腦- Configuration Manager restarts computer

- 程式控制重新啟動- Program controls restart

- Configuration Manager 會將使用者登出- Configuration Manager signs the user out
產生錯誤且軟體安裝失敗An error is generated and the software installation fails 不支援系統重新啟動設定及使用者特定的設定。The system restart setting and user-specific settings aren't supported.

使用 [不需要任何動作] 設定以外的其他設定時,用戶端會產生錯誤,並繼續進行軟體安裝,不會採取任何動作。When any setting other than the No action required setting is in use, the client generates an error and continues the software installation, with no action taken.
程式可執行:Program can run:

- 只有在使用者登入時- Only when a user is signed in
產生錯誤且軟體安裝失敗An error is generated and the software installation fails 不支援使用者特定的設定。User-specific settings aren't supported.

設定此選項時,用戶端會產生錯誤,且軟體安裝失敗。When this option is configured, the client generates an error and fails the installation of the software.

此時會忽略其他選項,並繼續軟體安裝。Other options are ignored and the software installation continues.
執行模式:Run mode:

- 以使用者的權限執行- Run with user's rights
忽略設定Settings are ignored 不支援使用者特定的設定。User-specific settings aren't supported.

不過,用戶端支援以系統管理權限執行的設定。However, the client supports the configuration running with Administrative rights.

當您指定 [以系統管理權限執行] 時,Configuration Manager 用戶端會使用其根認證。When you specify Run with administrative rights, the Configuration Manager client uses its root credentials.

此設定不會產生錯誤或記錄項目。This setting doesn't generate an error or log entry. 不過,當用戶端產生 [程式可執行] = [只有在使用者登入時] 的必要條件設定錯誤時,軟體安裝會失敗。Instead, the software installation fails when the client generates an error for the prerequisite configuration of Program can run = Only when a user is signed in.
允許使用者檢視程式安裝,並與其互動Allow users to view and interact with the program installation 忽略設定Settings are ignored 不支援使用者特定的設定。User-specific settings aren't supported.

此時會忽略此設定,並繼續軟體安裝。This configuration is ignored and the software installation continues.
磁碟機模式:Drive mode:

- 所有選項- All options
忽略設定Settings are ignored 由於內容永遠會下載到用戶端並於本機執行,因此不支援此設定。This setting isn't supported because content is always downloaded to the client and run locally.
先執行其他程式Run another program first 產生錯誤且軟體安裝失敗An error is generated and the software installation fails 不支援遞迴程式安裝。Recursive program installation isn't supported.

當程式被設定為先執行其他程式時,軟體安裝會失敗,且不會啟動其他程式安裝。When a program is configured to run another program first, the software installation fails, and the other program installation isn't started.
當此程式指派給電腦時:When this program is assigned to a computer:

- 針對登入的每個使用者執行一次- Run once for every user who signs in
忽略設定Settings are ignored 不支援使用者特定的設定。User-specific settings aren't supported.

不過,用戶端支援針對電腦執行一次的設定。However, the client supports the configuration running once for the computer.

此設定不會產生錯誤或記錄項目,因為已針對 [程式可執行] = [只有在使用者登入時] 的必要條件設定建立錯誤和記錄項目。This setting doesn't generate an error or log entry because an error and log entry are already created for the prerequisite configuration of Program can run = Only when a user is logged on.
抑制程式通知Suppress program notifications 忽略設定Settings are ignored 用戶端未實作使用者介面。The client doesn't implement a user interface.

選取此項設定時,系統會忽略此設定並繼續軟體安裝。When this configuration is selected, it's ignored and the software installation continues.
在部署此程式的電腦上停用此程式Disable this program on computers where it's deployed 忽略設定Settings are ignored 不支援此設定,且它不影響軟體的安裝。This setting isn't supported and doesn't affect the installation of software.
允許在未部署此程式的情況下,從安裝套件工作順序安裝此程式Allow this program to be installed from the Install Package task sequence without being deployed 用戶端不支援工作順序。The client doesn't support task sequences.

不支援此設定,且它不影響軟體的安裝。This setting isn't supported and doesn't affect the installation of software.
Windows Installer:Windows Installer:

- 所有選項- All options
忽略設定Settings are ignored 用戶端不支援 Windows Installer 檔案或設定。The client doesn't support Windows Installer files or settings.
OpsMgr 維護模式:OpsMgr Maintenance Mode:

- 所有選項- All options
忽略設定Settings are ignored 用戶端不支援此設定。The client doesn't support this configuration.

將軟體部署到 Linux 或 UNIX 伺服器Deploy software to a Linux or UNIX server

若要使用套件和程式將軟體部署至 Linux 或 UNIX 伺服器,您可以從 Configuration Manager 主控台使用 [部署軟體精靈] 。To deploy software to a Linux or UNIX server by using a package and program, you can use the Deploy Software Wizard from the Configuration Manager console. Linux 和 UNIX 的用戶端支援大部分的部署設定。Most deployment settings are supported by the client for Linux and UNIX. 但是,不支援數個設定。However several settings aren't supported. 當您部署軟體時,請考量下列幾點:When you deploy software, consider the following points:

  • 在至少一個與針對內容位置所設定之界限群組相關聯的發佈點上佈建套件。Provision the package on at least one distribution point that's associated with a boundary group that's configured for content location.

  • 接收此部署的 Linux 和 UNIX 的用戶端,必須能夠從其網路位置存取此發佈點。The client for Linux and UNIX that receives this deployment must be able to access this distribution point from its network location.

  • Linux 和 UNIX 的用戶端會從發佈點下載套件,並在本機電腦上執行程式。The client for Linux and UNIX downloads the package from the distribution point and runs the program on the local computer.

  • 適用於 Linux 和 UNIX 的用戶端無法從共用資料夾下載套件。The client for Linux and UNIX can't download packages from shared folders. 它會從啟用 IIS 的發佈點 (支援 HTTP 或 HTTPS) 下載套件。It downloads packages from IIS-enabled distribution points that support HTTP or HTTPS.

    下表列出不支援的部署屬性:The following table lists properties for deployments that aren't supported:

部署內容Deployment property 行為Behavior 更多資訊More information
部署設定 – 目的:Deployment settings – purpose:

- 可用- Available

- 必要- Required
忽略設定Settings are ignored 不支援使用者特定的設定。User-specific settings aren't supported.

不過,用戶端支援 [必要] 設定 (該設定會強制執行排程的安裝時間),但不支援在該排程時間之前進行手動安裝。However, the client supports the setting Required, which enforces the scheduled installation time, but doesn't support manual installation prior to that scheduled time.
傳送喚醒封包Send wake-up packets 忽略設定Settings are ignored 用戶端不支援此設定。The client doesn't support this configuration.
指派排程:Assignment schedule:

- 登入- sign in

- 登出- sign out
產生錯誤且軟體安裝失敗An error is generated and the software installation fails 不支援使用者特定的設定。User-specific settings aren't supported.

不過,用戶端支援 [盡快] 設定。However, the client supports the setting As soon as possible.
通知設定:Notification settings:

- 允許使用者不論指派均執行程式- Allow users to run the program independently of assignments
忽略設定Settings are ignored 用戶端未實作使用者介面。The client doesn't implement a user interface.
到了排程指派時間時,便允許在維護期間以外執行下列活動:When the scheduled assignment time is reached, allow the following activity to be performed outside the maintenance window:

- 系統重新啟動 (如果是完成安裝所需)- System restart (if necessary to complete the installation)
產生錯誤An error is generated 用戶端不支援系統重新啟動。The client doesn't support a system restart.
高速 (LAN) 網路的部署選項:Deployment option for fast (LAN) networks:

- 從發佈點執行程式- Run program from distribution point
產生錯誤且軟體安裝失敗An error is generated and the software installation fails 用戶端無法從發佈點執行軟體,且必須先下載程式才能執行它。The client can't run software from the distribution point and instead must download the program before it can run.
網路速度慢或不可靠之網路界限的部署選項,或內容的後援來源位置:Deployment option for a slow or unreliable network boundary, or a fallback source location for content:

- 允許用戶端與同一個子網路上的其他用戶端共用內容- Allow clients to share content with other clients on the same subnet
忽略設定Settings are ignored 用戶端不支援在對等之間共用內容。The client doesn't support sharing content between peers.

如需內容位置的詳細資訊,請參閱管理 Configuration Manager 的內容與內容基礎結構For more information about content location, see Manage content and content infrastructure for Configuration Manager.

如需如何建立部署的詳細資訊,請參閱部署應用程式For more information about how to create a deployment, see Deploy applications.

管理從發佈點下載軟體的網路頻寬Manage network bandwidth for software downloads from distribution points

Linux 和 UNIX 用戶端支援從發佈點下載軟體時的網路頻寬控制。The Linux and UNIX client supports network bandwidth controls when it's downloading software from a distribution point.

用戶端會使用您在 Configuration Manager 中設定為用戶端設定的背景智慧型傳送 (BITS) 設定,但不會實作 BITS。The client uses the Background Intelligent Transfer (BITS) settings that you configure as client settings in Configuration Manager, but doesn't implement BITS. 不過,為了節流處理網路頻寬的使用,用戶端會控制用於軟體下載的 HTTP 要求區塊大小及區塊間延遲。Instead, to throttle the use of network bandwidth, the client controls the HTTP request chunk size and inter-chunk delay for the software download.

若要設定讓用戶端使用網路頻寬控制功能,您可設定 [背景智慧型傳送] 的用戶端設定,然後將設定值套用到用戶端電腦。To configure a client to use network bandwidth controls, you configure client settings for Background Intelligent Transfer and then apply the settings to the client computer. 若要使用頻寬控制功能,用戶端必須接收 [背景智慧型傳送] ,並將下列設定設為 [是] :To use bandwidth controls, the client must receive client settings for Background Intelligent Transfer with the following settings configured as Yes:

  • 限制 BITS 背景傳送的最大網路頻寬Limit the maximum network bandwidth for BITS background transfers

    用戶端支援下列 [背景智慧型傳送] 的設定:The client supports the following configurations for Background Intelligent Transfer:

    • 節流時段開始時間Throttling window start time

    • 節流時段結束時間Throttling window end time

    • 節流時段的最大傳輸速率 (Kbps)Maximum transfer rate during throttling window (Kbps)

    • 節流時段以外的最大傳輸速率 (Kbps)Maximum transfer rate outside the throttling window (Kbps)

下列 [背景智慧型傳送] 的設定未受支援,且遭到 Linux 和 UNIX 的用戶端忽略:The following configuration for Background Intelligent Transfer is not supported, and is ignored by the client for Linux and UNIX:

  • 允許在節流時段以外進行 BITS 下載Allow BITS downloads outside the throttling window

    如果從發佈點將軟體下載到用戶端的作業被中斷,適用於 Linux 和 UNIX 的用戶端將不會繼續下載。If the download of software to the client from a distribution point is interrupted, the client for Linux and UNIX doesn't resume the download. 反而會重新開始下載整個軟體套件。Instead, it restarts the download of the entire software package.

軟體部署的設定作業Configure operations for software deployments

類似於 Windows 用戶端,Linux 和 UNIX 的 Configuration Manager 用戶端會在輪詢及檢查新原則時,探索新的軟體部署。Similarly to the Windows client, the Configuration Manager client for Linux and UNIX discovers new software deployments when it polls and checks for new policy. 用戶端檢查新原則的頻率,取決於用戶端設定。The frequency at which the client checks for new policy depends on client settings. 您可以設定維護期間來控制軟體部署的時機。You can configure maintenance windows to control when software deployments occur.

您可以使用套件內容、程式內容和部署內容,設定 Linux 和 UNIX 伺服器的軟體部署。You can configure software deployments to Linux and UNIX servers by using package properties, program properties, and deployment properties.

當用戶端接收到部署的原則時,會提交狀態訊息。When the client receives policy for a deployment, it submits a status message. 用戶端也會在其啟動軟體安裝時以及安裝完成或失敗時,提交狀態訊息。It also submits status messages when it starts the installation of software and when the installation finishes or fails.

使用 Linux 和 UNIX 的 Configuration Manager 用戶端所執行的根認證,執行軟體部署的程式。Programs for software deployments run with the root credentials that the Configuration Manager client for Linux and UNIX runs with. 程式命令的結束代碼,可用於判斷成功或失敗。The exit code of the programs command is used to determine success or failure. 結束代碼為 0 (零) 視為成功。An exit code of 0 (zero) is treated as success. 此外, stdout (標準輸出資料流) 和 stderr (標準錯誤資料流) 會在記錄層級設定為 INFO 或 TRACE 時複製到記錄檔。In addition, the stdout (standard output stream) and stderr (standard error stream) are copied to the log file when the log level is set to INFO or TRACE.

提示

如果您要部署的軟體位於 Linux 或 UNIX 伺服器可以存取的網路檔案系統 (NFS) 共用,則不需要使用發佈點來下載套件。If the software that you want to deploy is located on a Network File System (NFS) share that the Linux or UNIX server can access, you do not need to use a distribution point to download the package. 不過,當您建立套件時,請勿選取 [此套件包含來源檔案] 核取方塊。Instead, when you create the package, do not select the check box for This package contains source files. 接著,當您在設定程式時,請指定適當的命令列以直接存取 NFS 掛接點上的套件。Then, when you configure the program, specify the appropriate command line to directly access the package on the NFS mount point.