Google News
logo
PowerShell - Interview Questions
What are PowerShell modules?
A PowerShell module is a conjoined portion of PowerShell functions or grouped code. All PowerShell cmdlets and providers are incorporated by a module or a snap-in. The receivers of these modules can add the commands included in the module to their PowerShell sessions to use them like built-in commands. The most uncomplicated method to build a PowerShell module is to save the script as a PSM1 file. 
 
A PowerShell module includes 4 fundamental elements :
 
* A PSM file, being the module;
* Help files or scripts required by the module;
* A manifest file that defines the module
* A directory that accumulates the content.

There are four types of PowerShell modules:
 
Script module : A PSM1 file that includes different functions to allow admins to execute management functions, import, and export.

Binary module : A .NET framework assembly (DLL file) that includes saved code. Programmers generally utilize a binary module to build cmdlets with strong features not easily done with a PowerShell script.

Manifest module : A module (PSM1) file with an associated PSD1 file (manifest).

Dynamic module : A dynamic module is dynamically built on demand by a script. It isn't reserved or loaded to persistent storage.
Advertisement