5

The problem is incorrect path to remote host, but is not true. I have acces to my server via ftp without problems. All WP files are there and the site is working fine (frontend/backent). I have also access to phpMyAdmin to MySQL datepase binded to this site. I have notce that paht to the web files is differ depend on FTP or SFTP is. In FTP app is such stright:

/[all wp files]

in editor app (such TextWrangler), after the samy access id/pass, I have got such path:

/home/[accountname]/public_html/[all wp files]

After click on detect button, app changing the path filed on:
- blanc - under FTP connection
or
- public_html - under SFTP
so it mean conection between MAMP and my server is working. Fine. But after this when I trying to Check URLs & credentials or when I trying Import Host... I received:
Error code: -3010 (The 'Path' to your remote document root is incorrect. The 'Path' field on the remote tab is the document root of your remote site that will be accessed via your Public Site URL (e.g.: 'public_html').) - Start auto detect not solved the problem.
or
Error code: -3113 (The 'Path' to your remote document root is incorrect. The 'Path' field on the remote tab is the document root of your remote site that will be accessed via your Public Site URL (e.g.: 'public_html').)

But it is not true! All files are there!

Please help. Should I use some special code under Apache tab (Additional parameters for VirtualHost directive or Directory directive?
Should I know something more from my serverprovider (home.pl) and solved this problem with them (there is no, in my subscription plan, access via cPanel or so, to set up something)?
Should I change something in https.conf file?

I'm not so using server coding so please forgive me but I have no idea where is the problem (but I'm trying to learn) :o)

My environment is:
MacOS X: 10.13.6
MAMP Pro: 5.2.2 (17923)

Thanx for any help or redirection to the answers someware else (I used searching ;o) but without success or I used wrong ask).

Trilian
  • 51
  • 4

3 Answers3

0

Just ran into this and found a solution that worked for me. I just had to switch the Public URL from https to http and it worked.

Josh R
  • 53
  • 6
0

I had this error too. Here's what I did to fix it: Logged into my remote CPanel account Created an FTP account for user@sitename.com Defined the user directory in the FTP user settings similar to this /home/[site]/public_html Ensured that this user had read/write permissions on the remote server (otherwise importing a site in MAMP Pro might fail) Then, in MAMP Pro (v 6.0.1) created a new host following these steps: https://documentation.mamp.info/en/MAMP-PRO-Mac/Create-a-new-host/Import/ I found that once the correct FTP permissions were set at the server, MAMP was OK and functioned as planned. Good luck, hope this works for you too.

0

I have debugged this issue for a while. Here's my solution.

  • Make sure you have access to the public_html folder that correspondents with your website; e.g. if I upload test.html to domain.com/public_html/test.html, be sure that the file is reachable at domain.com/test.html.

  • Fill in your domain with http://, not https:// in the MAMP remote settings.

  • Be sure that Apache / NGINX allows you to access dot (.) folders and files. This is because MAMP will upload a file to check with the corresponding domain; e.g. path: /domain.com/public_html/.mp-51B0CE71-78F2 must be reachable at domain.com/.mp-51B0CE71-78F without being blocked by your host.

E.g. in my case, I had to add this line to my NGINX vhost to allow all /.mp requests, but deny the rest of them.

# DENY ALL HIDDEN FILES
  location ~ /\.{
      deny all;
  }

# MAMP PRO allow file check
  location ~ /\.mp {
      allow all;
  }
  • In some cases you could have trouble with Cloudflare / Varnish caching; in this case: temporarily disable caching to make sure this is the case, if so: add the domain (domain.com) to your hosts file with the corresponding server.

These are my MAMP PRO remote settings.

If this still doesn't work, please check your log files while the MAMP error is given. Once closed, the corresponding log files will be deleted.

Picture of log file location on MacOS.

NTravolta
  • 1
  • 2