[solved] Need assistance getting the http2 and mpm_event with 7.2-fpm

Hello Team,

I would like to get the full potential of your Virtualmin and performance of apache2 at the same time. In fact, I want to http2, mpm_event with 7.2-fpm.

From here, I would like future domain added on this server ready for the http2, mpm_event with 7.2-fpm.

Let me know if this is possible. Related to https://www.virtualmin.com/node/66141

Status: 
Closed (fixed)

Comments

Howdy -- thanks for contacting us!

it should be possible to get HTTP2 working on a Virtualmin server, and we've seen reports here in the support tracer and in the Forums from folks who have manually configured that.

HTTP2 and the Event MPM are unfortunately a bit outside the scope of our support though, and are also things we're not too familiar with.

I'm not familiar enough with the Event MPM to know whether that's able to work with Virtualmin.

Is it possible to get HTTP2 working using the Worker MPM? As I do know that MPM works.

Looking back at some past requests, I do see that a user told us they got HTTP2 working on Ubuntu using this article here:

https://interstellarconsulting.com/hosting/?section=enabling-http2-on-vi...

I see that article references the Event MPM ... I'm not sure though whether that means they used that, or whether they had to switch it to the Worker MPM to get things working.

kurtobando's picture
Submitted by kurtobando on Mon, 06/03/2019 - 12:30

Hello andreychek,

Thank you for your support.

I visit the link you have provided,

root@panel:~# sudo a2dismod mpm_prefork ERROR: The following modules depend on mpm_prefork and need to be disabled first: php7.2

so I disable the 7.2 first by sudo a2dismod php7.2

then these command below: sudo a2dismod mpm_prefork sudo a2enmod mpm_event sudo a2enmod http2

root@panel:~# sudo a2enmod php7.2 Considering dependency mpm_prefork for php7.2: Considering conflict mpm_event for mpm_prefork: ERROR: Module mpm_event is enabled - cannot proceed due to conflicts. It needs to be disabled first! Considering conflict mpm_worker for mpm_prefork: ERROR: Could not enable dependency mpm_prefork for php7.2, aborting

Could you shed some light on where to go about this?

However, you mentioned about mpm_worker, do you have any docs on how to enable mpm_worker with http2?

Sorry for the ignorance, I haven't got this far for apache2 yet.

Regards, Kurt

Hmm, I believe that php7.2 Apache module is for mod_php, which requires the Prefork MPM.

You can use a different PHP Execution Mode though by going into Server Configuration -> PHP Options, and there you can select the PHP Execution Mode of your choice.

Regarding HTTP2 and the Worker MPM -- sorry, I don't have any docs there... I only have the one link above since a user had mentioned it working for them, but we don't have any additional details on that.

HTTP2 and alternate Apache MPM's aren't things that end up coming up too often, and we haven't done any testing with those.

That said, as more distros begin shipping with Apache versions that support HTTP2, we'll very likely be adding formal support for that in the future. My guess is that could happen sometime after each of the 3 distros we support offer an Apache version that supports it. I believe CentOS is the only one missing that... and now that RHEL8 has come out, we could see a CentOS 8 version based on that by the end of the year.

I understand that doesn't help you now, but just wanted to let you know that I definitely see a day when we'll offer formal support for HTTP2.

kurtobando's picture
Submitted by kurtobando on Mon, 06/03/2019 - 13:00

Hello andreychek,

Thank you for your support.

I understand, I am just left behind with using prefork then, which I do not want to run on my VPS.

By any chance, do you have a recommendation on my current situation? Finally, if prefork is my only option, do you have personal optimization recommendation, based on my current specs?

Looking forward to your reply.

If you're interested in using HTTP2, and that's an important part of your project -- you might want to consider hiring a sysadmin to help out.

They could help you troubleshoot the process of getting either the Event MPM, or the Worker MPM, working with that setup.

If you'd like to try the free route for starters, you could always ask in the Forums to see if any sysadmins have any thoughts to share on how they got HTTP2 working with their servers.

If you do end up using Prefork -- I believe that's the default on most distros ATM. Most folks wouldn't notice any sort of performance difference between that and the other MPM's unless they're seeing particularly large amounts of traffic.

There's not really anything you'd need to do there, your server should work just fine with that mode.

And if you aren't using HTTP2, Worker mode should also work just fine. It may even work to use Worker with HTTP2, we just haven't tried before.

kurtobando's picture
Submitted by kurtobando on Sun, 07/21/2019 - 03:04

Switch to ubuntu 16.04, life is much easier now. Was able to run mpm_event and http2.

kurtobando's picture
Submitted by kurtobando on Sun, 07/21/2019 - 03:04

Title: Need assistance getting the http2 and mpm_event with 7.2-fpm ยป [solved] Need assistance getting the http2 and mpm_event with 7.2-fpm
Body: View changes