Nginx Website Failed After 7.10.0 Update

SYSTEM INFORMATION
OS type and version Debian 12
Webmin version Latest
Virtualmin version 7.10.0
Related packages SUGGESTED

Hello,

After updating Virtualmin to 7.10.0 version, we experienced a bug when creating a new virtual server with nginx enabled.

Creating Nginx virtual host …
… done

Setting up PHP pool …
… done

Adding webserver user www-data to server’s group …
… done

… Nginx website failed! : virtualmin-nginx::feature_setup failed : virtualmin-nginx::feature_add_web_webmail_redirect failed : flush_file_lines called on non-loaded file /etc/nginx/sites-available/DOMAIN.net.conf

Creating SSL certificate and private key …
… done

Adding SSL to Nginx virtual host …
… done

Setting up log file rotation …
… done

Errors are in web-lib-funcs.pl file (lines: 3867, 4208)

Any suggestions? Everything worked before the update.

Yours sincerely,
Mantas

As far as I know, this is fixed by the webmin-nginx update we rolled out this morning.

1 Like

Unfortunately, the bug persists. We updated Virtualmin to the latest version a few hours ago. There are no new updates available.

Reading package lists…
Building dependency tree…
Reading state information…
webmin-virtual-server is already the newest version (7.10.0.gpl-1).
webmin-virtualmin-awstats is already the newest version (6.1).
webmin-virtualmin-htpasswd is already the newest version (3.5).
webmin-virtualmin-nginx is already the newest version (2.35).
webmin-virtualmin-nginx-ssl is already the newest version (1.20).
webmin-virtualmin-nginx-ssl set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Hello Joe,

Our production server still cannot create new virtual servers at this moment. Do you have any suggestions on what we can do?

Same issue, please fix this, thanks!

This issue appear when I create Sub-server. Please check it, thanks!

Maybe you @Ilia could take a look into this? The bugs remain to this day.

That’s an odd issue. It works for me. Try to disable Nginx website for domain feature in Edit Virtual Server page. It will regenerate Nginx server config for the domain, and most likely resolve the problem you’re seeing.

Not working,

When I active “Nginx website enabled” in “Edit Virtual Server”, I get this:

Creating Nginx virtual host …
… done

Setting up PHP pool …
… done

… Nginx website failed! :

… Nginx SSL website failed! :

Saving server details …
… done

Applying Nginx configuration …
… done

Restarting PHP-FPM 8.1 server …
… done

1 Like

I am getting the same error. No matter what I do. Tried different things.

Every time I update I feel scared. Maybe we shouldn’t update, if you want to update, you should setup a new server! :smiley:

1 Like

@khanhpkvn I had no idea it could break the system. We did not make a backup either. Learned a lesson. Will need to reinstall Virtualmin freshly since no one knows the reason. I would check out web-lib-funcs.pl file myself but I don’t work with Perl. ChatGPT can probably fix it but too many lines of code for it.

Sure. Maybe CrapGPT will recommend the fix by installing :
pip install huggingface-cli

@joe Maybe you should add ‘that term’ to the filter. :wink:

You made my night, haha. Indeed. After like ~10 tries, it gives some workable ideas. But yes, ChatGPT including Gemini struggles with complex code and even manages to “improve” a simple code making it 2x slower (I benchmarked and compared it with mine).

If you get “help” from ChatGPT, forget about getting help here. I’m not going to try to understand the kinds of mess ChatGPT causes people to get themselves into.

1 Like

I did not mean it that way. But what help did you offer, Joe? Your update broke 2 people’s Virtualmin. It could be even more they just did not sign up on the forum.

Out of how many virtualmin users that use nginx ? I don’t have a problem at all, this does sort of indicate you have something setup incorrectly or away from standard,

1 Like

@khanhpkvn @MantasU Can you guys PM me zipped /etc/nginx from your systems? I will try to reproduce the problem.

No updating is a mistake!

In the early days of AI, I recall we had adopted a policy to not post solutions in the forum which were copied over from output generated by AI. The AI system, in that instance, was found to be imagining stuff that did not exist on the Virtualmin screens.

It therefore follows that applying AI suggestions to a production system is also equally, if not more, taboo. The community can be expected to offer support for standard Virtualmin systems but if random suggestions made by AI are implemented, there would be too much deviation from standard for the community to be able to support.

Let’s at least acknowledge there was an initial problem. That has been fixed and is confirmed as working with the update that is out there and should by now have been installed.

Is that the only error? or are there multiple nginx .cnf files

So potentially some other error?