Skip to main content

Posts

Showing posts from September, 2018

Error 521: Web server is down in plesk with cloudflare

Symptoms When visiting the website, it fails to load with error 521. The error occurs because the origin web server refused the connection from CloudFlare CloudFlare is used Website uses Nginx as a reverse-proxy; Cause CloudFlare IP addresses were blocked by  nginx  because of outdated contents of  /etc/nginx/conf.d/cloudflare.conf . /etc/nginx/conf.d/cloudflare.conf  contains old CloudFlare IP addresses list. Solution Make sure that you're not blocking CloudFlare IPs in  .htaccess ,  iptables , or your firewall. Make sure that you're operating off of the most recent versions of Bad Behavior or  mod_security . You want to ensure that mod_security's core rules aren't blocking CloudFlare requests; If you are running custom Apache modules, such as  mod_antiloris  and  mod_reqtimeout , disable and unload the modules. These modules will block any time an IP that connects more than 22 times. Since all connections are now coming from a CloudFlare

GITLAB Installation in Linux Server

1st IN UBUNTU 1. Install and configure the necessary dependencies sudo apt-get update sudo apt-get install -y curl openssh-server ca-certificates Next, install Postfix to send notification emails. If you want to use another solution to send emails please skip this step and  configure an external SMTP server  after GitLab has been installed. sudo apt-get install -y postfix During Postfix installation a configuration screen may appear. Select 'Internet Site' and press enter. Use your server's external DNS for 'mail name' and press enter. If additional screens appear, continue to press enter to accept the defaults. 2. Add the GitLab package repository and install the package Add the GitLab package repository. curl https://packages.gitlab.com/install/repositories/gitlab/gitlab-ee/script.deb.sh | sudo bash Next, install the GitLab package. Change `http://gitlab.example.com` to the URL at which you want to access your GitLab instance. Installation will automatically confi

Setting up multiple PHP versions in Webmin/Virtualmin

1. Log into your server Log in to your server with root user. How to log into Linux based server see  here . 2. Install PHP 5.6 on CentOS 6 Install the SCL Repo: yum install centos-release-scl Install the PHP packages: yum install rh-php56 rh-php56-php-mysqlnd 3. Install second PHP version In this case we will install PHP 7 on CentOS 6. Install the SCL Repo: yum install centos-release-scl Install the PHP packages: yum install rh-php70 rh-php70-php-mysqlnd 4.  Enable   “suexec_module”  on server This will allow Webmin to recognize different PHP versions: vi /etc/httpd/conf/httpd.conf Find and remove comment from line “#LoadModule suexec_module modules/mod_suexec.so”. It should look like this: LoadModule suexec_module modules/mod_suexec.so Save and close the file. Then restart Apache: service httpd restart 5.  Log into your Webmin control panel If you haven't done it yet, see how to use it in the link  here .   6.   Re-Check Configuration of the server After logging into Webmin, go t