apex, bare domain ( domain without www) and www.domain.com should point to the same IP. In amazon load balance or some of the cloud solution, they do not provide us a static IP, they provide us a name and asks us to point our domain to their domain. There is no problem with www.domain.com , but we can’t point apex domain (domain.com) to a cname record, it ‘s because the current DNS RFC does not allow this. There are many dns hosting providers customized their DNS to support this feature. If you are using Route53, you can use the script below to monitor the differenceRead More →

I recently had to clone a very large repository through SSH, every time i did i got this error   Cloning into ‘large-repository’… remote: Counting objects: 20248, done. remote: Compressing objects: 100% (10204/10204), done. error: RPC failed; curl 18 transfer closed with outstanding read data remaining fatal: The remote end hung up unexpectedly fatal: early EOF fatal: index-pack failed I could be the connection is bad , i finally fixed by using the commands below: $ git clone [email protected]:large-repository –depth 1 $ cd large-repository $ git fetch –unshallowRead More →

By default Apache only allows upto 150 connections, if the number is over, you will be in the queue. It will look like the server is down. The limit for server is usually configured in the following files: /etc/apache2/apache2.conf /etc/apache2/mods-available/mpm_worker.conf /etc/apache2/mods-available/mpm_prefork.conf This is the content to update:   <IfModule mpm_worker_module> ServerLimit 600 StartServers 10 MinSpareThreads 75 MaxSpareThreads 250 ThreadLimit 64 ThreadsPerChild 32 MaxRequestWorkers 600 MaxConnectionsPerChild 800 </IfModule>  Read More →

This is a bit gnarly. If you have a better method of updating the password without triggering a warning about PASSWORD being deprecated, I’m all ears. # Stop MySQL sudo service mysql stop # Make MySQL service directory. sudo mkdir /var/run/mysqld # Give MySQL user permission to write to the service directory. sudo chown mysql: /var/run/mysqld # Start MySQL manually, without permission checks or networking. sudo mysqld_safe –skip-grant-tables –skip-networking & # Log in without a password. mysql -uroot mysql Update the password for the root user. UPDATE mysql.user SET authentication_string=PASSWORD(‘YOURNEWPASSWORD’), plugin=’mysql_native_password’ WHERE User=’root’ AND Host=’%’; EXIT; # Turn off MySQL. sudo mysqladmin -S /var/run/mysqld/mysqld.sock shutdownRead More →

On Redhat, run this command lsblk You will see this NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sr0 11:0 1 1024M 0 rom sda 8:0 0 100G 0 disk ├─sda1 8:1 0 1G 0 part /boot └─sda2 8:2 0 99G 0 part ├─rootvg-swaplv (dm-0) 253:0 0 8G 0 lvm [SWAP] ├─rootvg-rootlv (dm-1) 253:1 0 14G 0 lvm / ├─rootvg-homelv (dm-2) 253:2 0 6G 0 lvm /home ├─rootvg-varlv (dm-3) 253:3 0 8G 0 lvm /var └─rootvg-tmplv (dm-4) 253:4 0 8G 0 lvm /tmp sdb 8:16 0 250G 0 diskRead More →

Environment variable GIT_SSH_COMMAND: From Git version 2.3.0, you can use the environment variable GIT_SSH_COMMAND like this: GIT_SSH_COMMAND=”ssh -i ~/.ssh/id_rsa_example” git clone example Note that -i can sometimes be overridden by your config file, in which case, you should give SSH an empty config file, like this: GIT_SSH_COMMAND=”ssh -i ~/.ssh/id_rsa_example -F /dev/null” git clone example Configuration core.sshCommand: From Git version 2.10.0, you can configure this per repo or globally, so you don’t have to set the environment variable any more! git config core.sshCommand “ssh -i ~/.ssh/id_rsa_example -F /dev/null” git pull git pushRead More →