Deep Dive | SSH Protocol Version 2

There’s a lot more happening under the hood – Deep Dive SSH Protocol Version 2 SSH protocol version 2 is the default protocol used these days. Most modern operating systems now a days by default select SSH version 2 for login and they switch to SSH version 1 in case version 2 is unavailable. From first point in the below table, multiple functions like authentication, key exchange and encryption were part of a single protocol…

Continue reading

Deep Dive | SSH Protocol Version 1

The workflow of SSH Protocol Version 1 SSH Protocol works on Layer 5 of the OSI model which is also known as Session Layer. A common mis-conception is that SSH works on Public Key Cryptography and not on Secret Key A good program that you would want to use for remote login should have the CIA features which are confidentiality, integrity and authentication methods where these three mean the following: Confidentiality – The data is private…

Continue reading

Find 504s in access logs, grep timestamps and correlate with error and php5-fpm logs

Web-Server throwing too many HTTP 504s? Use this script to drill down and find the cause Script finds the 504s in the access logs (across zipped access logs as well), greps the timestamp of the log files and then finds the error logs (Across zipped error logs as well) corresponding to the timestamps of 504’s access log entries found. OS – Linux 3.2.0-4-amd64 x86_64 Memory/RAM – 4GB MySQL DB is running on a different server…

Continue reading

Ways PHP can run with Apache Web Server

How PHP runs on your Apache Web-Server? Know the concept Basically, when loading mod_php  (mod_php means PHP, as an Apache module.) as an Apache module, it allows Apache to interpret PHP files (those are interpreted by mod_php). There are (at least) two ways of running PHP, when working with Apache: Using CGI : a PHP process is launched by Apache, and it is that PHP process that interprets PHP code — not Apache itself Using PHP as an Apache module (called mod_php) : the PHP interpreter…

Continue reading

AWS CLI – some advanced features

Some advanced features of AWS CLI Some Commands: aws configure list – lists all the currently configured options for AWS CLI aws configure set profile.prod.region us-west-2 – This command will set the default region for prod profile to us-west-2aws configure –profile prod – This command configure a prod profile besides the default one.  aws configure set profile.prod.aws_access_key_id JLJKLJODJOJDLDDDLJDL – This command would setthe access key ID of prod profile. In this command, if the profile prod is not

Continue reading