Skip to main content

Questions tagged [nginx]

Nginx is an open source web server. The nginx project started with a strong focus on high concurrency, high performance and low memory usage. Nginx is often seen as an alternative for Apache when running Magento.

Filter by
Sorted by
Tagged with
0 votes
1 answer
32 views

Programatically logged in customer not persistent with magento 2 fpc enabled

i have created a a ajax controller which log in customer programatically after getting the otp from the customer and after getting the response i refresh the page , the problem is when full page ...
Ritesh Kumar's user avatar
0 votes
0 answers
26 views

Magento 2 : Restrict Access to Admin

I am trying to limit access to my Magento 2 admin panel via nginx using location ~* ^/(index\.php/admin|admin) { 00.00.00.00; try_files $uri $uri/ /index.php?$args; location ~* \.php$ { ...
miller75's user avatar
  • 409
0 votes
0 answers
56 views

I've got 502 Bad Gateway errors only in customer login and account registration

Both customer/account/loginPost/referer/....... & /customer/account/createpost/ Lead to 502 Bad Gateway nginx/1.18.0 (Ubuntu) Interesting fact is that customers actually are able to create account ...
rt89's user avatar
  • 11
0 votes
1 answer
68 views

Varnish not working with Magento 2.4.3: Website doesn't response

I have multiple website on the server and I am trying to configure Varnish cache for them. I have bypassed other sites as for now I am focusing only on the magento site i.e. magento.site. However, if ...
nix's user avatar
  • 127
0 votes
1 answer
34 views

http to https redirect

I've followed all the solutions found in similar issues in the forum. I have no succeed doing it. What i have: Magento 2.4.3 Varnish Cache 6 (set to work at port 80) Apache (set to work at port 8081 ...
rt89's user avatar
  • 11
0 votes
1 answer
117 views

Varnish vs NGINX Cache for Magento 2

I have recently moved to Magento 2.4.4 My server currently is running on WHM with Nginx reverse proxy cache. My Magento is using the built-in Redish Full Page Cache. Recently I went to hire a ...
loginid's user avatar
  • 394
0 votes
0 answers
39 views

Magento 1.9 PHP Fatal error: Call to a member function getFrontNameByRoute() on boolean line 382

Sometimes I get this error in my Magento 1.9 but I cannot debug the reason. It happens quite rarely but I would like to find out why. Can you help me debug? this is my code at around like 382. File ...
Sam Provides's user avatar
0 votes
1 answer
262 views

Mageno 2.4.6 with Apache - Varnish - Nginx Proxy on HTTPS

System: Ubuntu 22.04 LTS Varnish Cache 7.0.3 Magento 2.4.6-p2 Ngnix 1.8 Apache 2.4 Magento (Setting Web) set Base URLs with HTTP http://magento.com Magento (Setting Web) set Base URLs (Secure) with ...
Pako's user avatar
  • 175
0 votes
0 answers
32 views

Correcting 404 Error with modified_nginx.conf.sample

When trying to access my magento site I keep getting 404 errors and running sudo tail /var/log/nginx/error.log I see the following: 2023/10/19 20:26:32 [warn] 318594#318594: *166 using uninitialized &...
capnhud's user avatar
  • 123
0 votes
1 answer
76 views

How I can find what values must have `MAGE_RUN_CODE` and `MAGE_RUN_TYPE` for each store/website url from db?

I am transfering a magento website and I have lost nginx settings. But I have full access in the database. In my case I want to find out upon each store url what values must have the MAGE_RUN_CODE and ...
Dimitrios Desyllas's user avatar
1 vote
1 answer
517 views

Using Magento 2 in subdirectory calling nginx.conf.sample

I looked at this question but I believe magento has changed since then I am trying to set the location block for calling magento 2.4.6-p3 from a subdirectory with the following in my nginx 1.24 server ...
capnhud's user avatar
  • 123
0 votes
1 answer
288 views

Error 502 or Nginx takes over

Magento Installation and Network Setup: Magento 2.4.6-ps2 (server) with elasticsearch 5.8 (docker) on NGINX server is successfully installed and running on an Oracle Cloud network environment, ...
Debbie's user avatar
  • 101
0 votes
0 answers
115 views

Unable to run Magento site on nginx

Using Debian 11, I installed PHP 8.1, PHP-FPM 8.1, Mysql 8, NGINX, Elasticsearch, Magento2 via composer. Now I am able to see the localhost welcome Nginx page and I cant navigate to Magento site. I ...
Leo's user avatar
  • 1
0 votes
2 answers
259 views

very confused about Varnish. Is it running or not? no headers it only says Pregma: cache

Maybe someone can help: on Ubuntu, nginx, latest magento (2.4.6), varnish 6 This is my Nginx conf setup: server { listen 8080 default_server; listen [::]:8080 default_server; listen 443 ...
Henri's user avatar
  • 123
1 vote
2 answers
5k views

nginx: [emerg] host not found in upstream "php-fpm" in /var/www/html/magento/nginx.conf.sample:50

I'm newbie to magento as well as in nginx. So I was following a youtube video which uses wsl2 in creating a magento project. So I got this error nginx: [emerg] host not found in upstream "php-fpm&...
Shenhuh's user avatar
  • 11
0 votes
1 answer
90 views

Strip index.php from rest urls

I am having this issue with an external platform which trying to get rest urls from my magento 2.4.5. Issue is that the urls they hit contain index.php inside. They are like this: https://example....
G. G.'s user avatar
  • 1,191
0 votes
3 answers
37 views

Magento layout file not called?

This is my Controller Index.php <?php namespace Hikmadh\Menu\Controller\Adminhtml\Product; class Index extends \Magento\Framework\App\Action\Action { /** @var \Magento\Framework\View\Result\...
Thoubik's user avatar
  • 128
0 votes
2 answers
691 views

Magento2.4.5 Varnish alway so 503 backend fetch fail

I have setup Vanish 6 on Magento2.4.5 but it alway show 503 backend fetch fail. My nginx config: upstream fastcgi_backend { server unix:/run/php/php8.1-fpm.sock; } server { server_name mysite....
the light's user avatar
  • 728
1 vote
2 answers
35 views

Folder permission

I installed magento2 with LEMP (nginx + php8.1-fpm) magento root: /var/www/html/ I am trying to add a seperate folder and execute a phpfile inside this folder in magento root: /var/www/html/...
Gkna's user avatar
  • 81
1 vote
2 answers
322 views

How can i install Wordpress in magento subdirectory

On my EC2, Magento is installed on main domain with nginx and now i want to install wordpress on magento subdirectory. how can i configure nginx for wordpress? Magento website: domain.com Wordpress ...
Ansh Bhatia's user avatar
1 vote
1 answer
207 views

Magento 2 nginx 404 error permission denied on setup

I have problem with setting up project the nginx is working fine and it is setup correctly, but it gives me 404 Not Found page when I try to access the url. The log: 2022/12/06 19:01:26 [crit] 285154#...
Kristijan Isajloski's user avatar
1 vote
4 answers
2k views

Magento 2 - No cache server(s) could be purged

I try to clone a project to which was running on nginx and using varnish. I try to run it on apache2. I get this error: report.CRITICAL: No cache server(s) could be purged Cache host: company.vm:...
Black's user avatar
  • 3,390
0 votes
2 answers
949 views

Updated to magento 2.4.5 now nginx fails to start

Just upgraded to Magento 2.4.5 on Ubuntu 20.4 running nginx with a Hestia control panel. After a reboot of the server, nginx failed to restart. Running command sudo nginx -t brings up error: nginx: [...
myshadowself's user avatar
1 vote
2 answers
450 views

Varnish with brotli -> missing ESI handling/filtering

I've compiled brotli modules for nginx and added following (from https://www.getpagespeed.com/server-setup/varnish/varnish-brotli-done-right) to varnish default.vcl: sub vcl_recv { if(req.http....
Twisted_Jar's user avatar
0 votes
1 answer
260 views

Conditional webp and resizing in nginx

So regular, webp conditional loading works: map $http_accept $webp_suffix { default ""; "~*webp" ".webp"; } with small exception of pulling out of svg to ...
Twisted_Jar's user avatar
2 votes
2 answers
444 views

Hosting Magento with Nginx getting 500 error on static files

I am currently upgrading an Magento 2.3.5 site to 2.4.4. Everything seems to going well and I have the site running in local on Docker (using Lando.dev) with nginx and the Magento nginx.conf.sample. ...
Robert Wilde's user avatar
1 vote
1 answer
851 views

How to solve 502 bad gateway error?

I am trying to access my project locally and I keep getting 502 bad gateway nginx error. Funny thing is that the admin side works but, the customer view gives me this bad gateway error. I am using ...
LosMos's user avatar
  • 121
1 vote
1 answer
204 views

Issue in setting multi website with two servers in Magento 2

I'm trying to setup Multi website in AWS server. I found several solution for Multi website implementation. In my case, There are two different servers(assume 0.0.0.1 and 0.0.0.2) where magento has ...
TS Guhan's user avatar
  • 369
0 votes
1 answer
3k views

Failed to load resource: net::ERR_HTTP2_PROTOCOL_ERROR

I have Magento 2.4.4 running on Plesk CentOS Server. PHP 8.1 PHP FPM Enabled Varnish on Port 80 Nginx on Port 8080 and 443 Apache on Port 7080 and 7081 Most of the time the website doesn't load well ...
David Buik's user avatar
0 votes
1 answer
292 views

Nginx conf setup for one install multiple websites

I was able to install MG 2 on nginx and everything is running without issue. But, I am unsure as to how to setup up multiple websites under one install. The various walkthroughs and brief examples are ...
acctman's user avatar
  • 111
0 votes
0 answers
167 views

How to solve Magento 2 "Refuse to apply css because of its MIME type" on Nginx?

I have a Magento 2 store and everything was ok with the default theme. Then I installed Porto theme and now I get this errors in the console and the page (especially the top menu) doesn't load ...
Melody's user avatar
  • 43
0 votes
1 answer
1k views

Nginx: All Pages Return 404 Not Found except Home Page

I'm using Magento 2.4.4, I've set up the existing project, but all page goes to 404 except the homepage. I'm using Nginx for the first time so still figuring out how to configure it. /etc/nginx/sites-...
Partab Saifuddin Zakir's user avatar
1 vote
0 answers
223 views

How to setup magento2 pwa nginx

I have set up Magento backend on eample.com and want to run PWA on subdomain pwa.example.com, I have set up the virtual host in Nginx for both, However, the backend is running but PWA on pwa.example....
Arunendra's user avatar
  • 7,458
1 vote
1 answer
158 views

Url redirect 2 times when access from www

I'm trying to investigate the issue redirect when using www and HTTP link. Currently, if I use HTTP link with www.domain then it will redirect 2 times 301 > 302 > 200. I check via site: https://...
the light's user avatar
  • 728
0 votes
1 answer
424 views

Magento Frontend not working without index.php

I installed magento 2.4.3-p1. Everything goes good , backend working frontend is working fine but there is an issue. I am able to access the frontend from abc.com/index.php and inner links are working ...
Charanjeet Singh's user avatar
1 vote
1 answer
300 views

Nginx 502 - [error] 11679#0: *1 upstream sent too big header while reading response header from upstream, client: 127.0.0.1

I'm doing a local installation of an existing project and facing some issues to make it work. I keep getting **502 Bad Gateway - nginx **, when I check the error log, I see that the domain is being ...
gorgoliac-13's user avatar
1 vote
1 answer
618 views

Extreme big headers only in large configurable products

We have a Magento 2.4.0 store. Most of our products are configurable. And some of them are having a lot of options. We also use swatch options. We have discovered some links which return: Error 503 ...
G. G.'s user avatar
  • 1,191
1 vote
3 answers
2k views

Price on product detail page changed to 0.00 magento 2.4.3-p1

I'm facing a weird issue with the product detail page on magento 2.4.3. The product price will be shown while loading the page and changed to 0.000 once the page is loaded completely. The price is ...
Sandeep Nair's user avatar
0 votes
2 answers
549 views

Magento 2.4 issue with CSS/JS not being sent to browser after installation/deployment; most probably server related (Nginx/Apache)

I have seen a couple of similar issues, but none of the solutions/reasons helped me. I installed Magento 2.4; tried it switch it to default and developer modes, forced it to compile and deploy static ...
NIck's user avatar
  • 1
0 votes
1 answer
108 views

Last-Modified header is M2.4.3 upgrade date

We have recently upgraded our M2.4.3 version and have noticed that the last modified header for all our web pages is now fixed at the exact upgrade date of our store across all web pages even newly ...
Nadroj467's user avatar
  • 571
0 votes
1 answer
418 views

Reindex - 401 Authorization Required - nginx

I have set up a local version of our Magento 2 store on my local machine running on Valet+ with Docker serving Elastic Search. Everything is working great, except I am running into a few errors when i ...
Tom Greaves's user avatar
0 votes
1 answer
454 views

FPC and "upstream sent too big header while reading response header from upstream" error on nginx?

As soon as I enable FPC in Magento 2.4.2, I am getting a upstream sent too big header while reading response header from upstream error when I try searching. It does not happen for all search terms, ...
user4095519's user avatar
0 votes
1 answer
53 views

New Magento 2.4.1 installation with assets only appearing on first page load, when not created yet in static folder

Thanks for any help. The standard theme looks fine with this new installation (Windows / Nginx) on the first page load only. I can reliably duplicate the issue by clearing the pub/static folder, where ...
JasonM's user avatar
  • 1
0 votes
0 answers
391 views

Magento 2 on Valet not loading CSS

So, as the title says, css is not loading on my local Magento page. I have used Valet, and Magento has been working fine up until today. Today, I wanted to try something and executed valet secure {...
Noob Doob's user avatar
  • 127
1 vote
1 answer
1k views

Magento 2.4.2 - Forbidden error on Nginx because of no index file in root directory

I am getting a 403 forbidden error while opening my website URL on the browser. After so much research I have found that the index file is missing from the Magento root directory and it is moved to ...
Hybrid Developer's user avatar
0 votes
1 answer
567 views

Magento 2 nginx restricting admin are by IP address not working

I am trying to restrict access to the admin area by IP address, but it's not working. When I type in the admin url, it redirects me to the home page. If I change the IP address being whitelisted, it ...
Eric Brown's user avatar
0 votes
1 answer
888 views

Nginx sometimes returns 502 because of varnish panic

we are using Magento 2.3.5 with following setup: User >> NGINX >> VARNISH (locale Docker) >> APACHE + PHP Randomly some Requests returned by Nginx with 502. log file says: recv() ...
Luco's user avatar
  • 23
0 votes
1 answer
454 views

Magento Paypal onAuthorization error on return to success page

I have a fresh install of Magento 2.3.6. I enabled the default paypal payment method, and I am trying to debug it using sandbox mode. I am able to complete the process of the payment on Paypal, but ...
justadev's user avatar
  • 245
0 votes
1 answer
2k views

Magento 2 admin redirect after adding varnish

I just added varnish cache to my site. Before I added it, I was able to get onto the admin panel. After adding it, though, trying to get to the admin panel results in an infinite redirect loop. It ...
Eric Brown's user avatar
1 vote
1 answer
3k views

Configure php-fpm in magento2.4 correctly

php-fpm is consuming a large amount of memory, forcing the instance to restart. The server would like to know the configuration or the procedure for an ideal configuration. server: 4vcore memory: ...
amazonas ecommerce's user avatar

1
2 3 4 5
8