WordPress.org

Ready to get started?Download WordPress

Forums

Error:Can't connect to ftp while updating! (8 posts)

  1. akshaybz
    Member
    Posted 3 years ago #

    Hello,

    I moved my blog to another server and then updated it to v3.2 RC3.

    When I try to update, it asks for my ftp info, I enter it and get following error:

    Error: There was an error connecting to the server, Please verify the settings are correct.

    Although I know the setting are correct as I can connect using net2ftp,filezilla etc

  2. Dion Hulse
    WordPress Dev
    Posted 3 years ago #

    If you're using your domain in the hostname field, try again using 'localhost'.

    If that doesn't work, chances are you have a dodgy PHP FTP extension on the new server, as a last resort, i'd suggest adding define('FS_METHOD', 'ftpsockets'); to test to see if it's the FTP extension causing the issues or not.

  3. akshaybz
    Member
    Posted 3 years ago #

    I tried localhost earlier too and got this error:

    Downloading update from http://wordpress.org/nightly-builds/wordpress-latest.zip…
    
    Warning: touch() [function.touch]: SAFE MODE Restriction in effect. The script whose uid is 1529 is not allowed to access /tmp owned by uid 0 in /home/theace/public_html/wp-admin/includes/file.php on line 177
    
    Warning: unlink() [function.unlink]: SAFE MODE Restriction in effect. The script whose uid is 1529 is not allowed to access /tmp owned by uid 0 in /home/theace/public_html/wp-admin/includes/file.php on line 489
    Download failed.: Destination directory for file streaming does not exist or is not writable.
    
    Installation Failed

    Then I thought that I was wrong O.o

    I added define('FS_METHOD', 'ftpsockets'); to wp-config.php but then I got following error:

    Warning: Invalid argument supplied for foreach() in /home/theace/public_html/wp-admin/includes/class-wp-filesystem-ftpsockets.php on line 299
    
    Warning: Invalid argument supplied for foreach() in /home/theace/public_html/wp-admin/includes/class-wp-filesystem-ftpsockets.php on line 299
    Unable to locate WordPress Root directory.
    
    Installation Failed

    Help please

  4. Dion Hulse
    WordPress Dev
    Posted 3 years ago #

    hate to say it, but your old server was configured better than your new server :)

    remove the FS_METHOD define, as thats not the problem.

    Check your permissions on the WordPress files, it should be 644 or possible 664.. folders should be 755.

    Failing that, It sounds like your server might be running with suexec, due to The script whose uid is 1529 so this may also help if all the permissions are correct and it still doesnt work: define('FS_METHOD', 'direct');

  5. Jimmy
    Member
    Posted 3 years ago #

    Hi guys,

    I am having the exact same issue. I've been told here that it could be a permissions issue, but I'm not convinced.

    I've tried using localhost as the FTP host but I just get the same error, 'Download failed. Destination directory for file streaming does not exist or is not writable.'

    I'm really getting desperate and any help/advice would be much appreciated.

    Jimmy.

  6. Dion Hulse
    WordPress Dev
    Posted 3 years ago #

    Jimmy, your issue isnt related to this thread at all, cross-posting your issue will not help get it fixed faster, rather just splinter advice and get multiple answers that are the same.

  7. Jimmy
    Member
    Posted 3 years ago #

    My apologies. I have mistaken this for a previous thread I was viewing, which lead me to this one.

  8. Alex
    Member
    Posted 2 years ago #

    define('FS_METHOD', 'direct'); did the trick for me. Thanks Dion Hulse (@dd32)

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.