I can not publish my site via FTP. There is no way to enable passive mode.

Historically, I have always uploaded my site via FTP, since my server does not have extensions on the first page and will not.

Using the latest version of Visual Studio 2012 (11.0.51106.01 Update 1) (although I think this problem is for all 2012), I can not publish my site!

Error message

2> Unable to add 'file' to website. FTP Passive mode not available

I will also indicate that my connection is being checked, so I don’t think the error message is anything but clear and meaningful!

So, I have 3 questions.

  • Is this something I'm wrong or to blame for Visual Studio 2012?
  • Should I try to do this through passive mode or do I need to update my web server to enable "active mode"?
  • Is FTP still an acceptable method, or should I examine the Web Deploy parameter?
+4
source share
5 answers
  • Open the publishing profile Properties\PublishProfiles\your_profile_name.pubxml

  • Add <FtpPassiveMode>False</FtpPassiveMode> to <PropertyGroup>

  • Save the file and publish again.

+11
source

As a workaround, publish the site to the file system (i.e. save it locally), and then use another FTP client to transfer it. This is not great at all, but if you are desperate and out of options, this may be the solution, no matter how temporary it is.

As an actual fix, you can enable this on the server. In my case, this turned out to be a firewall problem (it provided input permissions for FileZilla Server) and did not use a custom port range on the FileZilla server (under passive)! This suggests that this is a port problem.

However, this does not explain why you may or may not disable / enable passive mode in VS 2012, but may be in earlier versions.

+3
source

You can also do this (I was getting the same error as yours):

1 - Build > Publish 'project' .

2 - Uncheck Passive Mode .

enter image description here

+1
source

It should work after 5 simple steps (IIS7.5):

  • Make sure passive mode is selected.
  • Be sure to configure the port range of the data channel in the support section of the IIS FTP firewall (for example, 5000-6000).
  • Make sure port 5000-6000 is open on the firewall (allow incoming connections in the port range 5000-6000)
  • net stop ftpsvc
  • net start ftpsvc
0
source

If you have access to the server. You must add svchost.exe to the "Allowed Programs" in the Windows Firewall.

Look at this movie. This is at the end. youtube film

It worked for me.

-1
source

All Articles