FTP for WordPress - How ?
-
@johnpoz said in FTP for WordPress - How ?:
at a loss to why wordpress would have to ftp to itself?
Take a look at the WP doc page I quoted above. WordPress by default tries to auto-update minor versions (5.6.2 to 5.6.3). It can also update plugins. To do so it needs to write to files on the web server. Looking at this from the hosting company's perspective, if PHP is running as that customer's account, then it can write files. This is normally how various PHP-as-CGI options work in the web site hosting settings.
If it's running as, say, an Apache module, it runs as a different account and can't write to anything in the customer account (because one wouldn't want PHP to be able to write to any account on the web server). WordPress can detect that and then prompts to connect to itself via FTP, presuming the customer can connect via FTP and upload files to their own web site. So it's basically a workaround to be able to allow it to update itself.
-
@steveits said in FTP for WordPress - How ?:
So it's basically a workaround to be able to allow it to update itself.
Ah - so when say running on a hosted solution.
Is that what the OP is trying to do, host multiple wordpress stuff on a server behind pfsense for multiple accounts?
-
@johnpoz Even one WordPress site works this way. It's about how the PHP process is running. In the olden days it was faster to run as an Apache module because running as CGI was one process per site and if it wasn't persistent (lots of RAM for hundreds or thousands of sites cheap hosting companies squeeze onto each web server) there was no opcode caching. Now usually it is run as FPM, or FastCGI. But even CGI would work for one site...they key is having PHP run as the file owner so it can update files on the web site.
Basically, "I can't write files, but if I FTP to myself I can so let's do that."
So as long as we're talking about WordPress installing updates to WordPress or its plugins, what OP definitely does not want to do is to allow FTP logins from the Internet.
-
@steveits said in FTP for WordPress - How ?:
what OP definitely does not want to do is to allow FTP logins from the Internet.
I would concur with that for sure... My take is he is running into some sort of reflection problem where he is attempting to ftp to the sites public IP (on the pfsense wan).
I haven't run wordpress for years and years, and it was always on a hosted solution.. I could always fire it up on my local network to test and see what exactly is needed for it to work..
-
@steveits
It worked flawlessly with my Cisco RV-130 firewall
What more do I need to say... -
If I can't host it myself, I don't do it ! Simple as that... I like knowing how to fix stuff that I use.
I'm surprised that no one else has had this issue. WordPress is still highly used eh?
-
@steveits
I'm self hosted, and it worked flawlessly when I was using a Cisco RV-130 firewall.Go figure !
-
@dhenzler Then I would suggest something changed in the web server config to change how PHP is running. See if it is set to run as FPM, or FastCGI, or CGI, on your web site. Otherwise, as noted try "localhost" or your web server's hostname, with your FTP login and password.
-
@steveits
Things don't generally change by themselves. Unless doing an update killed it... I do apt-update and apt-upgrade periodically.Just watched a Youtube on the subject, and the guy said this package worked with no additional info added. I'm going to check to see if the update/upgrade killed my ftp. Then will check it again.
-
@dhenzler I think you need to clarify what you're trying to do. Are you trying to have WordPress connect to itself to update all things WordPress? Or have external users connecting to your FTP server?
-
I'm trying to restore the plugin update (using ftp or ftps) as prescribed by the WordPress software. This more or less automatically accesses the update info (over WAN) and completes the update.
This is all controlled by Wordpress, the only thing you need to do is provide your WAN IP and login / passwd for ftp
-
@dhenzler I think your misconception is that no one connects to your web server to install updates. WordPress connects to its own server. Try localhost as the FTP server and see if it works.
-
localhost doesn't have Internet access...
I'm absolutely sure that it works when the port is open. I've had to move on to other issues like a fence that burned down in a neighbors out of control weed burn...
Maybe continue at another time.
Thanks
-
@dhenzler said in FTP for WordPress - How ?:
localhost doesn't have Internet access
But, it's a web server...?
"Fire bad" as they say, sorry to hear about that.
-
-
@steveits
https://www.youtube.com/watch?v=T4MOfg05pag -
You were right localhost works !