New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[upgrade] 4.1.2 to 4.2.0 issue with .htaccess #10913
Comments
@mollux any thoughts on this? |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: https://forum.mautic.org/t/403-error-after-mautic-3-3-5-update/22859/5 |
I have updated on 2 different servers IE no subfolder, the update was smooth. Second server is a WHM/CPANEL server the A note about the htaccess rule Perhaps it might be a good idea to exclude the index.php ? M. |
Thanks for the feedback/troubleshooting @raramuridesign - really helpful! So to summarise this seems to be an issue when Mautic is in a sub-folder, rather than when it is in a root or subdomain? Could you also confirm if those instances affected have the correct url rewrite settings (eg accessing mautic at domain.com/mautic/s/dashboard and not with an additional /index.php/ in the middle? |
@RCheesley the rewrite works on all the instances. |
A subfolder in combination wit the .htaccess could indeed cause this issue. Could you try to change following line in the .htaccess from To
|
@mollux I can confirm this change works. However I did notice the folder: I have also un-commented this line
The only issue I see with this approach is
What are your thoughts? |
@raramuridesign this was indeed purely an example, not something that needs to be committed in the repo. There is no off the shelf fix for this, but it's something that needs to be tackled via documentation and awareness. @RCheesley what would be the best place to document this change? There is a different approach for tarball based and composer based installed |
@mollux Thanks and makes total sense with regards to documentation. It might worth proving a full ideal Thoughts? |
Thanks folks, @mollux I think this should be documented in the https://github.com/mautic/mautic-documentation repo. Probably under Installing Mautic / Updating Mautic and a link in the Troubleshooting section to those resources. @raramuridesign we very rarely update htaccess, I think. The commit history is here: https://github.com/mautic/mautic/commits/4.x/.htaccess. We do provide a full htaccess file right there in the repository, so I'm not sure what you're requesting, as the rules will be very specific for your own setup. We can't not update this file if there is a need to do so. Maybe when we add to the docs we could give some examples for using Mautic in a folder, on a root domain, and in a subdomain as a starting point? |
Hi, Yes. I have tried the solution too and it worked well on Apache 2.4 However it still gets stuck on Apache 2.2 The workaround for Apache 2.2 is still pending. If Mautic 4.2.x requires minimum Apache 2.4 I would request Mautic team to update the requirement on Mautic website so that users don't get confused. |
Hello! I upgraded mautic 4.1.2 to 4.2.0 and it gave me 403 error. Enter htaccess and modify line 113 of <If "%{REQUEST_URI} =~ m#^/(index|index_dev|upgrade/upgrade).php#"> to <FilesMatch "^(index|index_dev|filemanager|upgrade).php$"> And it worked correctly. Will this cause any problems in the future? |
@marcoalejandropalacio I have added the info to the release notes for the workaround which is mentioned here, and we are going to add it to the documentation in due course. This is likely because you are hosting in a folder rather than a subdirectory or root domain? If so you might want to use the workaround mentioned. This should not present a problem in the future unless we update the htaccess file. Please always read the release notes before updating and we will make sure to be very clear if this file is being modified in future releases. |
I have the mautic installation in a subdomain.
I have the mautic installation in a subdomain. In my hosting the folders appear like this: domains/mydomain.com/public_html/mautic and the subdomain to access my mautic installation is mautic.mydomain.com I hope that the solution that worked for me will help other people who have the same error |
Hi folks, as this is a documentation issue relating to htaccess config I am going to close this issue - we will ensure that we provide clear warnings if we are updating the htaccess file in future releases, so please make sure you read the release notes! |
|
Hi, The code for apache 2.2 still not working. Please mention the exact syntax for apache 2.2 and 2.4 in well documented manner when the installation is made in a sub directory. |
Did you do just that to make it work?
In my case it didn't work. |
On my server mautic is installed in a subdomain and gave the same 403 problem. I uninstalled everything and reinstalled version 4.2 and was unsuccessful as I had to comment out the code:
So I was able to access, however, even informing the Amazon AWS SES access data, I can't connect, it gives an authentication error. |
@wilsonfe @nikitakothari06 |
On my server mautic is installed in a subdomain email.mydomain.com and gave the same 403 problem. |
Did you try to uncomment this line - the link above will only work for subfolders. So first read through the thread logically to see where your issue is. Perhaps you have a permissions issue... I suppose you should also ask on the forum and post screenshots and setup so users can assist. Github is for more code related issues.
ot this line in apache < 2.4
|
My installation is on hostinger on a shared hosting. They use Litespeed 5.4. Don't use apache. If I uncomment it gives error 403. <FilesMatch ".php$"> |
@wilsonfe I think you might need to ask someone who has knowledge on lightspeed. |
Hello there, I have an installation of mautic in a subdomain (sub.domain.com).
That's all. It worked. Have a nice day. |
Making this change... everything inside Mautic works fine for you? There are no functions that do not work? |
I tried forms, landing, campaigns automation, multiple users connected, no problem. |
The only way to install the new version was to install it all over again. I tried to update version 4.2.0 to 4.2.1 and got the same problem (403). I will have to redo the installation again from scratch. I use a subdomain. email.domain.com. I tried to do what @DanVen73 said, but I was unsuccessful. |
I updated the .htacess file before trying to do the update from the panel. Except those allowed below.#<If "%{REQUEST_URI} =~ m#^/(index|index_dev|upgrade/upgrade).php#"> I don't know if I did it right. |
It happened to me that the segment options did not work for me and two more options that I do not remember now. |
You have to substitute this: With this |
Thanks |
How can I update mautic manually? I realized that one of the errors that I am having is that when updating mautic from the notification, it keeps loading one of the steps continuously |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: https://forum.mautic.org/t/403-forbidden-after-fresh-install-with-softaculous/23891/11 |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: https://forum.mautic.org/t/error-while-upgrading-from-3-3-4-to-4-0/20686/8 |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: https://forum.mautic.org/t/as-usual-upgrade-to-4-2-2-this-time-effed-up-my-installation/24106/12 |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: https://forum.mautic.org/t/security-enhancement-gives-403/24460/2 |
Is there a solution available which will survive potential mautic upgrades? Maybe something I can specify on my server's VirtualHost which can override the |
@cherouvim it does not look like hence why its been documented ;-) |
Can someone check to see if @DanVen73's change works with an install that is not in a subdomain? Because his revisions to the .htaccess file solved our access issues when installing Mautic on a subdomain, and if it works for normal installs as well, then to my mind it should just be included in the core. Also, has this been documented anywhere? It took us awhile to find this issue and fix the problem, but had it been mentioned in the install instructions (even as a side note) it would have been real quick and reduced frustrations |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: |
Dear Ones, It is simple to solve this problem, just remove everything from /.htaccess and apply the listed below: Prezados, É simples resolver esse problema, basta remover tudo do /.htaccess e aplicar o listado abaixo:
|
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: |
This issue has been mentioned on Mautic Community Forums. There might be relevant details there: https://forum.mautic.org/t/mautic-installation-on-litespeed-server-through-softaculous/27864/2 |
This issue has been mentioned on Mautic Forums. There might be relevant details there: https://forum.mautic.org/t/installed-mautic-4-4-10-with-softaculous-getting-403-error/29425/2 |
This issue has been mentioned on Mautic Forums. There might be relevant details there: https://forum.mautic.org/t/i-have-some-issues-to-update-from-4-1-0/30477/7 |
This issue has been mentioned on Mautic Forums. There might be relevant details there: |
Mautic Version
4.2.x series
PHP version
7.4.27
What browsers are you seeing the problem on?
Firefox, Chrome
What happened?
After performing an upgrade, the site reports an error 403, forbidden.
We upgrade via command line and clear cache and clean permissions as part of the process.
This maybe server specific, but this line in the HTACCESS
https://github.com/mautic/mautic/blob/4.2.0/.htaccess
Causes the issue, by commenting out
The site loads again.
Prior to this verison 4.1.2 Worked with this in the htaccess file.
How can we reproduce this issue?
Server
Ubunto 18.04.4 LTS
Server API | FPM/FastCGI
MariaDB
1:10.2.43+maria~bionic
Apache
2.4.52-1+ubuntu18.04+1
NGiNX
1.19.9-1+ubuntu18.04+1
Not sure if this is important, but we have mautic in a subfolder off the domain
eg: domain.com/mautic/
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: