API cURL Error:

feerdispzoo

Verified User
Joined
Jan 17, 2022
Messages
189
Hello,
I use WHMCS and WordPress Manager. (All this working with DirectAdmin) Now I created instance WordPress Image and create remote ftp access. Now I try clone website, connection FTP working but everytime I get "API cURL Error:"

I don't see any more details. I have Curl installed on the server

[root@vim735ac ~]# curl
curl: try 'curl --help' or 'curl --manual' for more information
[root@vim735ac ~]#


Can anyone advise where I can look for the bug?
 
Hi there,

Maybe you have to look at the logfiles of your server. Seems like the account you are trying to execute with is not allowed to do so.
 
Now I try clone website,
How exactly? From WHMCS? If yes, then WHMCS should have something about the connection in a logfile.
The backup manager from DA logs always in one of the logfiles from either DA or the system log.
So somewhere something about which curl error must available for finding.
 
Hello @Richard G

we use WHMCS + DirectAdminExtended + WordPress Manager.

From WHMCS, in WordPress Manager module I need use "instance image = remote import website".

Everytime I get:
1663060004924.png



The problem is, I not see any logs (I have enabled all logs in whmcs) and in system activity now I've last log from 13/09/2022 05:04

Also I not have any logs in WordPress Manager module.

I try also use WordPress Manager in Softaculous, here I try use "remote import". The process running and stuck on 95%. So I think the same error get.
1663060506562.png


I think that I have run out of ideas, I have probably already changed everything, but it's hard to do it "blindly" without recognizing a specific error.

I logged in to the SSH user, and curl works fine and returns no error here - so I don't know what's going on here.
 
@Richard G
Im not sure with this, but I test one more thing fallow to:


Code:
[root@vim735ac ~]# curl mywebforremoteimport:21
curl: (1) Received HTTP/0.9 when not allowed

[root@vim735ac ~]# curl --version
curl 7.85.0 (x86_64-pc-linux-gnu) libcurl/7.85.0 OpenSSL/1.0.2k-fips zlib/1.2.7 zstd/1.5.2 nghttp2/1.33.0
Release-Date: 2022-08-31
Protocols: dict file ftp ftps gopher gophers http https imap imaps mqtt pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: alt-svc AsynchDNS HSTS HTTP2 HTTPS-proxy IPv6 Largefile libz NTLM NTLM_WB SSL UnixSockets zstd
[root@vim735ac ~]#
 
Last edited:
I don't work with WHMCS, but we have encountered issues with curl sometimes, for backup and restore transfers.
The automated process of DA uses curl for that. And in all cases, they were firewall issues. For example passive ports not opened.
So that's the only thing which comes into my mind at the moment.

You could try with firewall disabled (csf -x) and see if it works then.

Or maybe somebody else can help, or since you have DA extended, you can shoot in a ticket for investigation.
 
@Richard G
resolved! Simply the API CURL ERROR returned because the module generated an incorrect path to the new wordpress installation path.

there is a field: "in what directory do you want to install wordpress - leave empty if you want install in root domain" I always left this field blank, and it turned out that the module added the full path in the background like /home/user/domains/mydomain.com/public_html

and finally path was duplicated in backgroud and module tried to install in path like: /home/user/domains/mydomain.com/public_html/home/user/domains/mydomain.com/public_html

and that was causing this error. After cleaning this background track, it now works properly.
 
Great!

Good to see you figured it out. It's very hard to find a cause when no error is to be found.

Thanks for reporting back!
 
Back
Top