Title: Automatic Plugin Upgrade Problem
Last modified: August 19, 2016

---

# Automatic Plugin Upgrade Problem

 *  [isdoro81](https://wordpress.org/support/users/isdoro81/)
 * (@isdoro81)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/)
 * Hi,
 * I’ve hosted my site on Servage, when i try to upgrade a plugin, it asks my the
   ftp access password, the ftp server and if i use ssl (with other hosting it doesn’t
   need to set this info), i set these infos and then i go ahead.
 * I have this error:
 * Warning: ftp_pwd() [function.ftp-pwd]: Opening ASCII mode data connection for
   file list in /mounted-storage/home20b/sub001/sc18587-YDFT/www/wp-admin/includes/
   class-wp-filesystem-ftpext.php on line 122
 * Warning: ftp_pwd() [function.ftp-pwd]: Opening ASCII mode data connection for
   file list in /mounted-storage/home20b/sub001/sc18587-YDFT/www/wp-admin/includes/
   class-wp-filesystem-ftpext.php on line 122
 * Impossible to find the plugins directory.
 * I use the correct passwords.
 * Thanks
 * Giulio

Viewing 11 replies - 1 through 11 (of 11 total)

 *  [Samuel B](https://wordpress.org/support/users/samboll/)
 * (@samboll)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874769)
 * Some servers will not allow this action. Contact your host and ask if they will
   fix this.
 *  Thread Starter [isdoro81](https://wordpress.org/support/users/isdoro81/)
 * (@isdoro81)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874835)
 * Hi,
 * I don’t think that’s a server configuration error.
 * Warning: ftp_pwd() [function.ftp-pwd]: Transfer aborted. Link to file server 
   lost in /mounted-storage/home20b/sub001/sc18587-YDFT/www/wp-admin/includes/class-
   wp-filesystem-ftpext.php on line 122
 * Warning: ftp_pwd() [function.ftp-pwd]: CWD command successful in /mounted-storage/
   home20b/sub001/sc18587-YDFT/www/wp-admin/includes/class-wp-filesystem-ftpext.
   php on line 122
 * Warning: ftp_pwd() [function.ftp-pwd]: PORT command successful in /mounted-storage/
   home20b/sub001/sc18587-YDFT/www/wp-admin/includes/class-wp-filesystem-ftpext.
   php on line 122
 * Warning: ftp_pwd() [function.ftp-pwd]: CWD command successful in /mounted-storage/
   home20b/sub001/sc18587-YDFT/www/wp-admin/includes/class-wp-filesystem-ftpext.
   php on line 122
 * If you keep a close eye on the error you will see command is successful but the
   link from where it should upgrade the plugin is not given at line 122 from file/
   www/wp-admin/includes/class-wp-filesystem-ftpext.php
 * Please check this line $cwd = ftp_pwd($this->link);
 * The connection has been established but desired link is not found. So that will
   be the link to set there.
 * Thanks for your help
 * Giulio
 *  [Samuel B](https://wordpress.org/support/users/samboll/)
 * (@samboll)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874896)
 * Not a server config error – but host won’t allow server to do this function. 
   Checked with them?
 *  Thread Starter [isdoro81](https://wordpress.org/support/users/isdoro81/)
 * (@isdoro81)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874911)
 * Hi,
 * Thanks for your help, this is the answer of Servage:
 * >  I am sorry to say that you cannot connect to FTP from any script using the
   > port 21. Please check how you can change the port to 2121. Else it is not possible
   > to connect to FTP.
 * Can i change the port? How?
 * Thanks again
 * Giulio
 *  [Samuel B](https://wordpress.org/support/users/samboll/)
 * (@samboll)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874913)
 * I use [Filezilla](http://filezilla-project.org/download.php).
    You can easily
   change ports at the interface to whatever number needed.
 *  [mcs_trekkie](https://wordpress.org/support/users/mcs_trekkie/)
 * (@mcs_trekkie)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874986)
 * I was just able to fix “this issue”.
    Looks like Servage do have some issues 
   with active FTP transfers to their own FTP servers. I just “fixed” this by switching
   to passive transfer method by patching class-wp-filesystem-ftpext.php. Maybe 
   some developer could make passive transfer selectable from the UI ??
 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874987)
 * mcs_trekkie – can you detail the changes you made?
 * Have you considered suggesting that change at WordPress Trac?
 * [http://trac.wordpress.org](http://trac.wordpress.org)
    [Reporting Bugs](http://codex.wordpress.org/Reporting_Bugs)
 * Thanks for the info.
 *  [mcs_trekkie](https://wordpress.org/support/users/mcs_trekkie/)
 * (@mcs_trekkie)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874988)
 * well I don’t know the internals of WordPress very well so providing a full patch
   including buttons and all saving the setting somewhere is a little bit difficult
   right now.
    I simply added ftp_pasv($this->link, 1) after the ftp_login call 
   in the connect() function so passive mode is always used.
 * But I could try to make a full patch for this feature in the next days….
 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874989)
 * Well if you don’t want to prepare a patch, just report a trac ticket and show
   the line(s) of code you used to make the change. Use your forum login/password
   to login at trac. Good Luck.
 *  Moderator [Dion Hulse](https://wordpress.org/support/users/dd32/)
 * (@dd32)
 * Meta Developer
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874990)
 * _This is only for 2.7 i believe, 2.6 doesnt support it AFAIK:_ If you need to
   change the ftp port, You can set the hostname as such: **[http://ftp.hostname.com:2121](http://ftp.hostname.com:2121)**
 * As for passive mode, Opening a trac ticket would be best. FTP Passive Mode is
   allready used by 2 of the 3 FTP transports (There’s 3 different FTP connection
   methods supported by WordPress, depending on what the host allows). Enabling 
   it for the 3rd shouldnt cause any issues. I’ll open a Trac ticket later today
   if the OP doesnt.
 * I absolutely hate the fact that the FTP PHP Extension raises warnings for sucessful
   commands, So most of the warnings mentioned on this topic can be ignored (2.7
   silences these warnings too), _Transfer aborted. Link to file server lost_ might
   need to get some extra attention though, It might need to fail gracefully if 
   the link is lost.
 *  [mcs_trekkie](https://wordpress.org/support/users/mcs_trekkie/)
 * (@mcs_trekkie)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874991)
 * I have just opened a ticket in Trac and appended a patch for 2.6.2 which adds
   passive FTP support for WP_Filesystem_FTPext and allows to choose if passive 
   mode should be used or not in the update.php.
 * It was easier to get the input thing done than I first thought as I never did
   take a deeper look into the wordpress sources before.
 * The ticket is here:
    [http://trac.wordpress.org/ticket/7940](http://trac.wordpress.org/ticket/7940)

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘Automatic Plugin Upgrade Problem’ is closed to new replies.

## Tags

 * [ftp](https://wordpress.org/support/topic-tag/ftp/)
 * [plugin upgrade](https://wordpress.org/support/topic-tag/plugin-upgrade/)

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 11 replies
 * 5 participants
 * Last reply from: [mcs_trekkie](https://wordpress.org/support/users/mcs_trekkie/)
 * Last activity: [17 years, 7 months ago](https://wordpress.org/support/topic/automatic-plugin-upgrade-problem/#post-874991)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
