Answers.Body: <p>Well, it turned out to be my own fault for the CPU usage, etc.  I had turned on monitoring by AWS for port 80 and 443.  Apparently something was out of whack with that because it consumed ALOT of the server!  I removed those monitors and surprise... back to normal and what I would have expected.  Odd behaviour but the function isn't that important to me that I will hunt down why it was doing what it was.
  I used the template as posted above, have distributed support for both the web pages and the database.  Quite happy with the change.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-05-10T12:21:59.497Z
Answers.LastActivityDate: 2023-05-10T12:21:59.497Z
Answers.UserDisplayName: Norm Dressler
Answers.Body: <p>I manage an instance with around 200,000 contacts on a EC2 t2.medium (No elastic scaling). We gradually ratcheted up to an RDS t3.xlarge.</p>
  <p>What ballpark are you in with Contacts and simultaneous users?  Are you talking about performance in the back-office (i.e. CiviCRM itself), or custom solutions that integrate the Civi API?</p>
  <p>If you are using the &quot;default&quot; EC2 size recommended in the blog post, I would expect problems. Also, I'm not sure it is a good idea to run Apache with the default configurations in the AMI. I use a custom image that sets limits per Civi's recommendations and per my experience.</p>
  <p>===</p>
  <p>That's my succinct answer... if you care to stay tuned for more rambling...</p>
  <p>Thanks for posting the question, I would be curious to find out what more CiviCRM admins are doing on AWS. The blog post is written by a name I do not recognize and contains the factual error that &quot;CiviCRM is built on Wordpress&quot;, so I don't think the author has any experience beyond writing the post. I haven't had the pleasure of trying Civi with scalable EC2 instances. Is that possible without rewriting how core handles files?</p>
  <p>This instance is on AWS due to general IT strategic decisions, not because it was well suited for CiviCRM. If there is a reason to use AWS for Civi, I think it might be RDS.</p>
  <p>I had to put a lot of effort into optimizing for mailings, mostly to keep them from bogging down other things. AWS SES is awesome and has just swallowed right down all I could throw at it. But I found that Apache was getting slammed with image requests when people opened the messages and was able to take that load off by tuning caching provided by CloudFlare.</p>
  <p>The best advice is always, &quot;Get More Information&quot;. Figure out how to profile your unique usage. You will need to look at both individual request performance, and also how things deteriorate under increased load. If you can't simulate high-demand, then look for opportunities to observe them in real-time.</p>
  <p>With all the facility of the cloud, web servers should be getting smaller. I would recommend coming up with a few categories of requests you need the web server to perform well on and profile each step of the most intensive kinds of requests. Look to bad code or inefficient api utilization or database queries needing optimization. If you are just trying to get vanilla Civi working better, again, I think just beef up the database server.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-05-10T04:26:55.953Z
Answers.Text: I added a 'correction' comment to that blog to make it clear civi is not just a WP plugin
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-05-10T02:17:54.143Z
Answers.LastActivityDate: 2023-05-10T02:17:54.143Z
Answers.UserDisplayName: ginkgoMZD
Answers.Body: <p>Probably your instance type is not powerful enough. Also you can use ARM based instance, which is cost effective and gives better performance with gp3 EBS.</p>
  <p>I have a m6g.large with at least another 3 websites plus one of them is civicrm with drupal, also running a docker container as well. So far no issues.</p>
  <p>I didnt use the template you have tried, but I have fired up my own EC2 with this control panel <a href="https://www.cloudpanel.io" rel="nofollow noreferrer">https://www.cloudpanel.io</a> and separately installed all softwares.
  This may help.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2023-05-09T08:18:44.373Z
Answers.LastActivityDate: 2023-05-09T08:27:47.330Z
Answers.LastEditDate: 2023-05-09T08:27:47.330Z
Answers.UserDisplayName: Tapash
Body: <p>I have followed the template and instructions from here - <a href="https://aws.amazon.com/blogs/publicsector/managing-nonprofit-members-donors-civicrm-aws/" rel="nofollow noreferrer">https://aws.amazon.com/blogs/publicsector/managing-nonprofit-members-donors-civicrm-aws/</a></p>
  <p>This is a great piece.  I have my production environment up and running with a modified version of this template.  However, I've noticed the environment is slow.  I have a t3.large setup with the Aurora DB and I have configured the ElasticCache with REDIS - this really helped but there are times the lag is unbearable or the site times out.  Any suggestions?</p>
  <p>Any pointers available to speed things up?  The cache hits are around 99% and sub second for the DB so I'm thinking its the Apache server?</p>
  <p>Thanks!</p>
  
Tags: <aws>
Title: Civicrm on Amazon AWS
ThreadText: # Civicrm on Amazon AWS
  
  (Asked by: username_0 on 2023-05-05)
  
  I have followed the template and instructions from here - <https://aws.amazon.com/blogs/publicsector/managing-nonprofit-members-donors-civicrm-aws/>
  
  This is a great piece. I have my production environment up and running with a modified version of this template. However, I've noticed the environment is slow. I have a t3.large setup with the Aurora DB and I have configured the ElasticCache with REDIS - this really helped but there are times the lag is unbearable or the site times out. Any suggestions?
  
  Any pointers available to speed things up? The cache hits are around 99% and sub second for the DB so I'm thinking its the Apache server?
  
  Thanks!
  
  **Tags:** aws
  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_0 on 2023-05-10. Score: 3 | Accepted answer
  
  Well, it turned out to be my own fault for the CPU usage, etc. I had turned on monitoring by AWS for port 80 and 443. Apparently something was out of whack with that because it consumed ALOT of the server! I removed those monitors and surprise... back to normal and what I would have expected. Odd behaviour but the function isn't that important to me that I will hunt down why it was doing what it was.
  I used the template as posted above, have distributed support for both the web pages and the database. Quite happy with the change.
  
  
  ---
  
  ### Answer by username_1 on 2023-05-10. Score: 2
  
  I manage an instance with around 200,000 contacts on a EC2 t2.medium (No elastic scaling). We gradually ratcheted up to an RDS t3.xlarge.
  
  What ballpark are you in with Contacts and simultaneous users? Are you talking about performance in the back-office (i.e. CiviCRM itself), or custom solutions that integrate the Civi API?
  
  If you are using the "default" EC2 size recommended in the blog post, I would expect problems. Also, I'm not sure it is a good idea to run Apache with the default configurations in the AMI. I use a custom image that sets limits per Civi's recommendations and per my experience.
  
  ===
  
  That's my succinct answer... if you care to stay tuned for more rambling...
  
  Thanks for posting the question, I would be curious to find out what more CiviCRM admins are doing on AWS. The blog post is written by a name I do not recognize and contains the factual error that "CiviCRM is built on Wordpress", so I don't think the author has any experience beyond writing the post. I haven't had the pleasure of trying Civi with scalable EC2 instances. Is that possible without rewriting how core handles files?
  
  This instance is on AWS due to general IT strategic decisions, not because it was well suited for CiviCRM. If there is a reason to use AWS for Civi, I think it might be RDS.
  
  I had to put a lot of effort into optimizing for mailings, mostly to keep them from bogging down other things. AWS SES is awesome and has just swallowed right down all I could throw at it. But I found that Apache was getting slammed with image requests when people opened the messages and was able to take that load off by tuning caching provided by CloudFlare.
  
  The best advice is always, "Get More Information". Figure out how to profile your unique usage. You will need to look at both individual request performance, and also how things deteriorate under increased load. If you can't simulate high-demand, then look for opportunities to observe them in real-time.
  
  With all the facility of the cloud, web servers should be getting smaller. I would recommend coming up with a few categories of requests you need the web server to perform well on and profile each step of the most intensive kinds of requests. Look to bad code or inefficient api utilization or database queries needing optimization. If you are just trying to get vanilla Civi working better, again, I think just beef up the database server.
  
  > **Comments:**
  > **username_2**: I added a 'correction' comment to that blog to make it clear civi is not just a WP plugin  
  
  ---
  
  ### Answer by username_3 on 2023-05-09. Score: 0
  
  Probably your instance type is not powerful enough. Also you can use ARM based instance, which is cost effective and gives better performance with gp3 EBS.
  
  I have a m6g.large with at least another 3 websites plus one of them is civicrm with drupal, also running a docker container as well. So far no issues.
  
  I didnt use the template you have tried, but I have fired up my own EC2 with this control panel <https://www.cloudpanel.io> and separately installed all softwares.
  This may help.
  
  
  ---
  
  