Advance

Tutorial Launch FTP with PowerShell on Windows Server 2016

Tutorial Launch FTP with PowerShell on Windows Server 2016
0
(0)

In this article, we want to discuss Tutorial Launch FTP with PowerShell on Windows Server 2016.

Tutorial How to Launch FTP with PowerShell on Windows Server 2016

In this tutorial, we want to build and use an FTP site with PowerShell.

How to Launch FTP with PowerShell:

1) First, open your PowerShell with Administrator access.

2) First of all, if you have not installed the FTP service on your IIS yet, install it with the following command.

Install-WindowsFeature Web-FTP-Server  

3) After installing FTP Server, enter the following command to enter the module working with IIS.

Import-Module WebAdministration  

4) After importing the desired module, create a directory with the following command.

New-Item c:\ElderFtpDir -Type Directory  

5) Then enter the following command to create an FTP site and set the server’s IP port and address on it.

New-WebFtpSite -Name "Elderftp" -Port 21 -IPAddress 192.168.1.101 -Force  

Be sure to enter your server’s IP address instead of the IP entered and your FTP name instead of Elderftp.

6) Then enter the following command to link your FTP site to the directory that was created in the fourth step.

cmd /c \windows\system32\inetsrv\appcmd set site "Elderftp" "-virtualdirectorydefaults.physicalpath:c:\ElderFtpDir"  
Recommended Article: Tutorial How to Migration Guide from cPanel to Directadmin

7) In the following configuration of FTP site with PowerShell, enter the following command to set Authentication of your site.

Set-ItemProperty IIS:\Sites\Elderftp -Name ftpServer.security.authentication.basicAuthentication.enabled -Value $true  

8) After creating the FTP site and linking it to the relevant directory, enter the following commands to set the SSL.

Set-ItemProperty IIS:\Sites\Elderftp -Name ftpServer.security.ssl.controlChannelPolicy -Value 0  Set-ItemProperty IIS:\Sites\Elderftp -Name ftpServer.security.ssl.dataChannelPolicy -Value 0  

9) Then enter the following command to set the Authorization settings of your FTP site.

Add-WebConfiguration -Filter /system.ftpserver/security/authorization -Value (@{AccessType="Allow"; Users="Administrator"; Permissions="Read,Write"}) -PSPath IIS: -Location Elderftp  

10) Restart your FTP site at the end and use it after restarting.

Restart-WebItem "iis:\sites\Elderftp"  

We hope you enjoy this tutorial Launch FTP with PowerShell on Windows Server 2016.

How useful was this post?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate this post.

View More Posts
Tom Veitch
Eldernode Writer
We Are Waiting for your valuable comments and you can be sure that it will be answered in the shortest possible time.

Leave a Reply

Your email address will not be published. Required fields are marked *

We are by your side every step of the way

Think about developing your online business; We will protect it compassionately

We are by your side every step of the way

+8595670151

7 days a week, 24 hours a day