The key authorization file from the server did not match this challenge (Letsencrypt)

The common cause of the error "The key authorization file from the server did not match this challenge" on Letsencrypt is that the domain name cannot be resolved correctly. You must make sure the domain is directing to the server and can be accessed from the outside network.

Change default php's sys_temp_dir on vesta

  1. Edit these two files. 
    vim /usr/local/vesta/data/templates/web/httpd/default.stpl
    vim /usr/local/vesta/data/templates/web/httpd/default.tpl
  2. Add the line "php_admin_value sys_temp_dir %home%/%user%/tmp" into those files as following:
    <Directory %sdocroot%>
            AllowOverride All
            SSLRequireSSL
            Options +Includes -Indexes +ExecCGI
            php_admin_value open_basedir %sdocroot%:%home%/%user%/tmp
            php_admin_value upload_tmp_dir %home%/%user%/tmp
            php_admin_value session.save_path %home%/%user%/tmp

T=remote_smtp defer (-53): retry time not reached for any host

Cause:
It doesn't normally happen due to exim database corruption. It normally happens if your machine goes offline or another machine goes offline for network connectivity. If that happens, then exim reaches the retry times and cannot succeed in sending out the messages and will not try to resend those messages until the retry timeout is reached.

If this happens to you frequently, then you likely have an issue with your machine's network or routing and it has nothing to do with exim.

Set up security websocket (wss) in vesta + php + centos

  1. Enable mod_proxy and mod_proxy_wstunnel module in apache.
    • vi /etc/httpd/conf.modules.d/00-proxy.conf
    • Remove '#' from the beginning of these two lines. If you can't find these two lines from the file, please add them manually.
      LoadModule proxy_module modules/mod_proxy.so
      LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so
  2. Add configuration for the apache
    • vi /home/{username}/conf/web/xxxx.com.httpd.ssl.conf

Add swap to linux

  1. Check swap status. 
    • If nothing is returned by the command, then the summary was empty and no swap file exists.​​
      swapon -s
    • Another way. We can see our current memory and swap usage (in megabytes).
      free -m
      
                   total       used       free     shared    buffers     cached
      Mem:          3953        315       3637          8         11        107
      -/+ buffers/cache:        196       3756
      Swap:            0          0       4095

"proc_open(): fork failed - Cannot allocate memory" error occur when using "composer update"

solution:

  1. /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024
  2. chmod 600 /var/swap.1
  3. /sbin/mkswap /var/swap.1
  4. /sbin/swapon /var/swap.1
  5. composer update
  6. /sbin/swapoff /var/swap.1
  7. rm /var/swap.1
Subscribe to Centos Blog RSS