530 valid hostname is expected ошибка

FTP errors are annoying as usual.

You want to upload an important file to your website using an FTP client, but it suddenly throws an error. Quite frustrating, sure.

One of these FTP errors is “530 valid hostname is expected“.

At Bobcares, we help server owners resolve such errors as part of our Dedicated Support Services for web hosts.

Today, we’ll discuss the top 2 reasons for this error and how we fix them.

FTP error “530 valid hostname is expected” – Brief explanation

FTP error 530 valid hostname is expected is a common error seen on FTP servers hosted on Windows system. This error occurs when users set up IIS with multiple FTP sites.

So, every time users enter the correct username and password, the system still prompts this error.

FTP error “530 valid hostname is expected” – Causes and Fixes

We now have a basic understanding of this error. Let’s now see the main reasons for this error and how our Dedicated Support Engineers fix them.

1) Incorrect binding in IIS

FTP binding is the combination of IP address, port and virtual hostname. The FTP server uses these details to listen to the requests made to that FTP host. So, wrong binding settings for the website can always break the FTP connection to the server.

We’ve seen many instances where users try to connect to the FTP site using a hostname that’s not configured in the IIS bindings. As a result, the FTP server was unable to identify the FTP host that connects to the server and throws the FTP error 530 valid hostname is expected.

Similarly, another common mistake we see is that customers set up the FTP site to bind to the localhost loopback IP address(127.0.0.1). As a result, the hostname can’t be resolved externally and the connection can be dropped.

How we fix?

Firstly, our Hosting Engineers get the FTP login details from the customer. Further, we check the Binding settings of the domain on the server. If the FTP host is not configured in the bindings, we’ll add the correct binding for that hostname in the IIS settings.

In addition to that, we confirm the IP address specified in the binding configuration is a non loop back address. That is, it should be the server’s public IP address or server’s internal IP address depending on how the server is configured.

[Need a Server Expert to look into your IIS binding settings? Click here, our Server Administrators are online 24/7.]

2) Incorrect username in the FTP client

This error commonly happens when users configure multiple FTP sites on the same IP address. In other words, multiple websites have same the set of IP address, Port number, etc. So, the FTP server can’t determine the exact account for which the user give the FTP credentials.

As a result it throws the FTP error 530 valid hostname is expected.

How we fix?

It’s a usual case that customers need to host multiple domains on the same IP address. So, here our Support Engineers suggest customers use a hostname and user combination in the format ‘hostname|user'(the symbol | separates hostname and user) in the username field of the FTP clients like Filezilla.

For example, consider that a user wants to connect to the FTP host ftp.domain.com with the username testing. Then, you should give the username as ftp.domain.com|testing. Here, the FTP server can easily identify that the FTP client is connecting to the host ftp.domain.com with the username testing.

[And, do you need a Server Expert to look into this error? One of our Support Engineers can fix it for you.]

Conclusion

In short, FTP error 530 valid hostname is expected can occur due to incorrect binding in IIS or wrong username given in the FTP client. Today, we’ve discussed these causes in detail and how our Support Engineers fix these problems.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

SEE SERVER ADMIN PLANS

var google_conversion_label = «owonCMyG5nEQ0aD71QM»;

I’ve configured IIS to have multiple FTP sites, using the instructions found here: https://docs.microsoft.com/en-us/iis/publish/using-the-ftp-service/using-ftp-virtual-host-names-in-iis-7

See the configuration I ended up with below.

In IIS I’ve configured basic authentication and use user mysite_ftp for ‘Connect as’, when testing settings I get green checkmarks on both Authenication and Authorization.

IIS settings:
enter image description here

When I use Filezilla to try to connect I get this logging:

Tried with VPS hostname: h2746286.stratoserver.net

Status: Resolving address of h2746286.stratoserver.net
Status: Connecting to 85.214.200.30:21...
Status: Connection established, waiting for welcome message...
Status: Insecure server, it does not support FTP over TLS.
Command:    USER tv_ftp
Response:   331 Valid hostname is expected.
Command:    PASS ***********
Response:   503 Login with USER first.
Error:  Critical error: Could not connect to server

Tried with hostname: www.telefonievergelijken.nl

Status: Resolving address of www.telefonievergelijken.nl
Status: Connecting to 85.214.200.30:21...
Status: Connection established, waiting for welcome message...
Status: Insecure server, it does not support FTP over TLS.
Command:    USER tv_ftp
Response:   331 Valid hostname is expected.
Command:    PASS ***********
Response:   503 Login with USER first.
Error:  Critical error: Could not connect to server

Tried with hostname: ftp.telefonievergelijken.nl

Status: Resolving address of ftp.telefonievergelijken.nl
Status: Connecting to 85.214.200.30:21...
Status: Connection established, waiting for welcome message...
Status: Insecure server, it does not support FTP over TLS.
Command:    USER tv_ftp
Response:   331 Valid hostname is expected.
Command:    PASS ***********
Response:   503 Login with USER first.
Error:  Critical error: Could not connect to server

applicationHost.config

<sectionGroup name="system.ftpServer">
    <section name="log" overrideModeDefault="Deny" allowDefinition="AppHostOnly" />
    <section name="firewallSupport" overrideModeDefault="Deny" allowDefinition="AppHostOnly" />
    <section name="caching" overrideModeDefault="Deny" allowDefinition="AppHostOnly" />
    <section name="providerDefinitions" overrideModeDefault="Deny" />
    <sectionGroup name="security">
        <section name="ipSecurity" overrideModeDefault="Deny" />
        <section name="requestFiltering" overrideModeDefault="Deny" />
        <section name="authorization" overrideModeDefault="Deny" />
        <section name="authentication" overrideModeDefault="Deny" />
    </sectionGroup>
    <section name="serverRuntime" overrideModeDefault="Deny" allowDefinition="AppHostOnly" />
</sectionGroup>

<sites>
    <site name="othersite" id="2">
        <application path="/" applicationPool=".NET v4.5">
            <virtualDirectory path="/" physicalPath="E:othersitewwwroot" userName="othersite_web" password="[enc:IISCngProvider:b1dn9+We00KRNWUB6shbPm/hLtBOF2hOG9We5zVgaEmYL5C/fDLxDc3QH9Rnvi79SjeM+Rauk/bQWEBzJnw=:enc]" />
        </application>
        <bindings>
            <binding protocol="http" bindingInformation="*:80:www.othersite.nl" />
            <binding protocol="http" bindingInformation="*:80:othersite.nl" />
        </bindings>
    </site>
    <site name="telefonievergelijken" id="3">
        <application path="/" applicationPool=".NET v4.5">
            <virtualDirectory path="/" physicalPath="E:telefonievergelijkenwwwroot" userName="tv_web" password="[enc:IISCngProvider:x+PhGwZweUwR53tUgGTdEGui8k4gIJRASehxKVtsPoTtxNIA8aRe8WUwvdLuEdzSQicrJVDwen7e/C6x9qfiFyudqtZYwhXuo=:enc]" />
        </application>
        <bindings>
            <binding protocol="http" bindingInformation="*:80:www.telefonievergelijken.nl" />
            <binding protocol="http" bindingInformation="*:80:telefonievergelijken.nl" />
        </bindings>
        <traceFailedRequestsLogging enabled="true" directory="E:IISDataLogFilesFailedReqLogFiles" />
    </site>
    <site name="FTP-othersite" id="1">
        <application path="/">
            <virtualDirectory path="/" physicalPath="E:othersitewwwroot" />
        </application>
        <bindings>
            <binding protocol="ftp" bindingInformation="127.0.0.1:21:" />
        </bindings>
        <ftpServer>
            <security>
                <ssl controlChannelPolicy="SslAllow" dataChannelPolicy="SslAllow" />
                <authentication>
                    <basicAuthentication enabled="true" />
                </authentication>
            </security>
        </ftpServer>
    </site>
    <site name="FTP-TV" id="4">
        <application path="/">
            <virtualDirectory path="/" physicalPath="E:telefonievergelijkenwwwroot" userName="tv_ftp" password="[enc:IISCngProvider:xYxqamuKq02/xUcvZGTdEGui8gh3w6XT0hEegnCMZbVIxeWIOypRIZ1u8UAOG/AJg=:enc]" />
        </application>
        <bindings>
            <binding protocol="ftp" bindingInformation="127.0.0.1:21:www.telefonievergelijken.nl" />
        </bindings>
        <ftpServer>
            <security>
                <ssl controlChannelPolicy="SslAllow" dataChannelPolicy="SslAllow" />
                <authentication>
                    <basicAuthentication enabled="true" />
                </authentication>
            </security>
        </ftpServer>
    </site>
    <siteDefaults>
        <logFile logFormat="W3C" directory="E:IISDataLogFiles" />
        <traceFailedRequestsLogging directory="E:IISDataLogFilesFailedReqLogFiles" />
        <ftpServer>
            <logFile directory="E:IISDataLogFilesFTPLogs" />
            <security>
                <authentication>
                    <basicAuthentication enabled="false" />
                </authentication>
            </security>
        </ftpServer>
    </siteDefaults>
    <applicationDefaults applicationPool="DefaultAppPool" />
    <virtualDirectoryDefaults allowSubDirConfig="true" />
</sites>        

UPDATE 1

Ah, I’ve changed the 127.0.0.1 IP address to my VPS’s external IP address. When I try to connect with ftp.telefonievergelijken.nl|tv_ftp I get logging errors:

Error:  Could not connect to server
Status: Waiting to retry...
Status: Resolving address of ftp.telefonievergelijken.nl|tv_ftp
Status: Connection attempt failed with "EAI_NONAME - Neither nodename nor servname provided, or not known".

UPDATE 2

Changed username settings for connection:
enter image description here

  • Remove From My Forums
  • Вопрос

  • Доброго всем времени. Коллеги, не могу запустить ftp сервер. Сервер создал, указал папку. Но даже локально (ftp://localhost) не удается отобразить страницу.  Пробовал менять порт, не помогает.
    зы. iis 8 на w2k12

    • Изменено

      4 февраля 2016 г. 10:55

Ответы

  • ну не знаю насчет политики, но создался пользователь без пароля.

    Есть такое ограничение в локальной груповой политике (gpedit.msc) по умолчанию, возможно в этом проблема с авторизацией учетной записи с пустым паролем:

    1. On Local Group Policy Editor snap-in under Computer Configuration expand
      Windows Settings and then expand Security Settings.
    2. Expand Local Policies and click on Security Options.

    Accounts: Limit local account use blank passwords to console logon only = Enabled


    Учетные записи: разрешить использование пустых паролей только при консольном входе = Включен


    Для того. что отключить ограничение попробуйте установить значение Disabled(Выключен). Для применения logoff/logon.

    Либо применить следующие изменения в реестре (на свой страх и риск):

    Windows Registry Editor Version 5.00

    [HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlLsa]
    "LimitBlankPasswordUse"=dword:00000000

    Для применения перегрузите сервер.


    Best Regards, Andrei …
    MCP

    • Изменено
      SQxModerator
      8 февраля 2016 г. 14:45
      добавлено
    • Помечено в качестве ответа
      Vasilev VasilMicrosoft contingent staff
      26 февраля 2016 г. 6:31

User-1017055418 posted

 I created ftp site with this options:

Anonymous Authentication = Disable

Basic  Authentication=Enable

 Add Allow Rule(specified user:Administrator:Read,Write)

Allow SSL connection

Require SSL certificate:Not selected

bindings: ??.??.??.??:21:ftp.??example??.com(ftp)

add permissions for user ‘administrator’ on physical path.

 add ‘ftp’ alias(CName) on ‘??example??.com’ zone in DNS.(so I can ping and trace rout ‘ftp.??example??.com’ from internet)

I try to test my ftp site from cmd and that was OK,I wrote

 FTP ??.??.??.??

 User (??.??.??.??:(none)): ftp.??example??.com|Administrator

331 Password Required for ftp.??example??.com|Administrator.

Password: ******

230 User logged in.

FTP>

but when I test ftp with windows and wrote ‘ftp.??example??.com’ in address bar, can’t connect and said
Valid Host name expected. I Use fireftp (firefox addon) and this error shown:

 530-Valid hostname is expected.
 Win32 error:   No such host is known.
 Error details: Hostname didn’t match any configured ftp site.
530 End

I remove virtual host name from my binding and everything is OK????!!!!!

 bindings: ??.??.??.??:21: (ftp)

I want to use virtual host name because I want to create multiple FTP sites on a single IP address by using the default port(21):

Any idea?

FTP-Error-Valid-Hostname-Is-Expected

04
Mar

Windows Server

When connecting to IIS7 ( Internet Information Server – the default web server for windows servers ) using FTP you get the following error.

Response: 530 Valid hostname is expected.
Error: Could not connect to server

Reason

When you set up name-based FTP services IIS7 wants the site name defined with the username so that IIS7 can associate the username with the site they wish to log in to.

If you are having more than one FTP site on your VPS you will need to access FTP via following method.

Host: Mydomain.com
User: Mydomain.com|Username

Note the “|” that separates the Site name and the Username.

OR you remove the “Host Name” defined in the “Bindings” property of the FTP site.

cpanel-server-20off

Author

Inder

Founder & CEO of 24x7servermanagement.com with 20 years of experience in Cloud Infrastructure, Managed IT Services and Systems Administration. Certified AWS Cloud Associate Engineer.


Возможно, вам также будет интересно:

  • 5287 ошибка мерседес w221
  • 5287 ошибка мерседес 221
  • 5285 ошибка мерседес w221
  • 5283 ошибка мерседес w221
  • 5280 ошибка мерседес w221

  • Понравилась статья? Поделить с друзьями:
    0 0 голоса
    Рейтинг статьи
    Подписаться
    Уведомить о
    guest

    0 комментариев
    Старые
    Новые Популярные
    Межтекстовые Отзывы
    Посмотреть все комментарии