This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can trysigning in orchanging directories.
Access to this page requires authorization. You can trychanging directories.
You can install PowerShell on some distributions of Linux that aren't supported by Microsoft. Inthose cases, you might find support from the community for PowerShell on those platforms.
Supported Linux distributions must meet the following criteria:
For more information, see thePowerShell Support Lifecycle documentation.
The following distributions are examples of distributions supported by the community. Eachdistribution has its own community support mechanisms. Consult the distribution's website to findtheir community resources. You can also get help from thesePowerShell Community resources.
The documented steps to install PowerShell onUbuntu might work on Ubuntu interim releases.However, Microsoft only supports PowerShell on the Long Term Servicing (LTS) releases of Ubuntu.Microsoft doesn't supportinterim releases of Ubuntu.
PowerShell is available from theArch Linux User Repository (AUR). Packages in the AUR aremaintained by the Arch community. To install thelatest release binary, see theArch Linux wiki orUsing PowerShell in Docker.
# Install PowerShell packageapt update && apt -y install powershell# Start PowerShellpwsh
# Uninstall PowerShell packageapt -y remove powershell
You can install PowerShell on Gentoo Linux using packages from the Gentoo package repository. Forinformation about installing these packages, see thePowerShell page in the Gentoo wiki.
You may be able to install PowerShell on SLES and openSUSE using the SNAP package manager. Also,the following article provides information on how to install PowerShell on openSUSE:
Raspberry Pi OS (formerly Raspbian) is a free operating system based on Debian.
Important
.NET isn't supported on ARMv6 architecture devices, including Raspberry Pi Zero and Raspberry Pidevices released before Raspberry Pi 2.
Download the tar.gz package from thereleases page onto your Raspberry Pi computer. The linksto the current versions are:
https://github.com/PowerShell/PowerShell/releases/download/v7.4.11/powershell-7.4.11-linux-arm32.tar.gz
https://github.com/PowerShell/PowerShell/releases/download/v7.4.11/powershell-7.4.11-linux-arm64.tar.gz
https://github.com/PowerShell/PowerShell/releases/download/v7.5.2/powershell-7.5.2-linux-arm32.tar.gz
https://github.com/PowerShell/PowerShell/releases/download/v7.5.2/powershell-7.5.2-linux-arm64.tar.gz
Use the following shell commands to download and install the package. This script detects whetheryou're running a 32-bit or 64-bit OS and installs the latest stable version of PowerShell for thatprocessor type.
#################################### Prerequisites# Update package listssudo apt-get update# Install dependenciessudo apt-get install jq libssl1.1 libunwind8 -y#################################### Download and extract PowerShell# Grab the latest tar.gzbits=$(getconf LONG_BIT)release=$(curl -sL https://api.github.com/repos/PowerShell/PowerShell/releases/latest)package=$(echo $release | jq -r ".assets[].browser_download_url" | grep "linux-arm${bits}.tar.gz")wget $package# Make folder to put powershellmkdir ~/powershell# Unpack the tar.gz filetar -xvf "./${package##*/}" -C ~/powershell# Start PowerShell~/powershell/pwsh
Optionally, you can create a symbolic link to start PowerShell without specifying the path to thepwsh
binary.
# Start PowerShell from bash with sudo to create a symbolic linksudo ~/powershell/pwsh -Command 'New-Item -ItemType SymbolicLink -Path "/usr/bin/pwsh" -Target "$PSHOME/pwsh" -Force'# alternatively you can run following to create a symbolic link# sudo ln -s ~/powershell/pwsh /usr/bin/pwsh# Now to start PowerShell you can just run "pwsh"
rm -rf ~/powershell
Was this page helpful?
Was this page helpful?