Scan not starting – wp_remote_post() test back failed
-
I’ve recently moved my WordPress sites to a new DigitalOcean droplet (with the same config: 1vCPU, 2GB RAM) with PHP8.1-FPM and nginx.
For some reason WordFence is unable to start scans. The scan immediately stops:
- [Dec 24 12:35:06]?Attempting to resume scan stage (0 attempt(s) remaining)…
- [Dec 24 12:33:42]?Attempting to resume scan stage (1 attempt(s) remaining)…
- [Dec 24 12:32:31]?Scan stop request received.
- [Dec 24 09:05:22]?Attempting to resume scan stage (0 attempt(s) remaining)…
- [Dec 24 08:52:06]?Attempting to resume scan stage (1 attempt(s) remaining)…
- [Dec 24 08:50:55]?Scheduled Wordfence scan starting at Sunday 24th of December 2023 08:50:55 AM
I tried to change the settings to start scans remotely, but I had no luck with that. cURL is installed and enabled in my PHP installation.
A few more details. ufw is not active, but I have set up some rules in the DigitalOcean firewall. I opened up ports 80 and 443 to the WordFence IPs listed here:
- 44.239.130.172
- 44.238.191.15
- 35.155.126.231
- 54.68.32.247
- 44.235.211.232
- 54.71.203.174
I even tried disabling the firewall entirely, still no luck.
I’ve set up PHP-FPM to use a custom pool for every site I have, and files and dirs are owned by the user running the PHP-FPM processes. I set up open_basedir to only allow access to the site’s root directory and the /tmp directory.
Here are some PHP config parameters in case it’s helpful:
pm.max_children = 6 pm.start_servers = 3 pm.min_spare_servers = 2 pm.max_spare_servers = 3 pm.process_idle_timeout = 10s; pm.max_requests = 500
There’s a 256MB memory_limit.
I have disabled the following PHP functions (these were also disabled in my old server, where scans are working):
disable_functions = dl,exec,expect_popen,fpaththru,getmypid,getmyuid,leak,listen,passthru,pcntl_alarm,pcntl_async_signals,pcntl_exec,pcntl_fork,pcntl_get_last_error,pcntl_getpriority,pcntl_setpriority,pcntl_signal,pcntl_signal_dispatch,pcntl_signal_get_handler,pcntl_sigprocmask,pcntl_sigtimedwait,pcntl_sigwaitinfo,pcntl_strerror,pcntl_unshare,pcntl_wait,pcntl_waitpid,pcntl_wexitstatus,pcntl_wifcontinued,pcntl_wifexited,pcntl_wifsignaled,pcntl_wifstopped,pcntl_wstopsig,pcntl_wtermsig,popen,posix_ctermid,posix_getcwd,posix_getegid,posix_geteuid,posix_getgid,posix_getgrgid,posix_getgrnam,posix_getgroups,posix_getlogin,posix_getpgid,posix_getpgrp,posix_getpid,posix_getppid,posix_getpwnam,posix_getpwuid,posix_getrlimit,posix_getsid,posix_getuid,posix_isatty,posix_kill,posix_mkfifo,posix_setegid,posix_seteuid,posix_setgid,posix_setpgid,posix_setsid,posix_setuid,posix_times,posix_ttyname,posix_uname,proc_close,proc_get_status,proc_nice,proc_open,proc_terminate,shell_exec,system,system_exec
In WordFence’s diagnostics page I see this error:
- Connecting back to this site: wp_remote_post() test back to this server failed! Response was: cURL error 28: Operation timed out after 10002 milliseconds with 0 bytes received
- Connecting back to this site via IPv6 (not required; failure to connect may not be an issue on some sites): wp_remote_post() test back to this server failed! Response was: cURL error 7:
Which is strange because in Diagnostics WordFence also says:
Checking for cURL support: ? 7.81.0 (0x75100)
Does anyone have an idea what’s going on?
- The topic ‘Scan not starting – wp_remote_post() test back failed’ is closed to new replies.