How to access AWS EC2 Files

Let’s get started Amazon EC2 by launching, connecting to, and using a Linux instance. An instance is a virtual server in the AWS cloud. With Amazon EC2, you can set up and configure the operating system and applications that run on your instance.

1) Login to your AWS account using your Account ID and Password

2) Go to services >> Compute >>Ec2 Section

ec2-instance

3) Go to instance and connect
See Picture

aws-ec2-files-access

4) Open SSH (Using putty)

5) Connect your sever using given host and private Key

Select all data from MySQL where varchar date greater than today ?

To select all event from MySQL varchar date, that start from tomorrow onwards, for that we have a easy method via using  STR_TO_DATE function.It convert stored date and compare with CURDATE() function

Here in this example I have an even table, in that table event start date is stored in the filed named event_start_time, my requirement is to fetch all event that is greater than today date and ineed in the event date ascending order.

See MySQL query

SELECT * FROM event WHERE STR_TO_DATE(event_start_time, '%d-%m-%Y') > CURDATE() ORDER BY STR_TO_DATE(event_start_time,'%d-%m-%Y') Asc

To Fetch coming 7 days data event

SELECT * FROM event WHERE STR_TO_DATE(event_start_time, '%d-%m-%Y') > CURDATE() AND STR_TO_DATE(event_start_time, '%d-%m-%Y') <= CURDATE() + INTERVAL 7 DAY 

To Fetch coming one month data event

SELECT * FROM event WHERE STR_TO_DATE(event_start_time, '%d-%m-%Y') > CURDATE() AND STR_TO_DATE(event_start_time, '%d-%m-%Y') <= CURDATE() + INTERVAL 30 DAY 

To fetch Today’s Event

SELECT * FROM event WHERE STR_TO_DATE(event_start_time, '%d-%m-%Y') = CURDATE()

How To Install Free cPanel in Linux Centos ?

Unfortunately cpanel is not a free software it is asking around Cost of 15 USD per month.But we have lot of similar software doing exactly the same functionality,out of that Zpanel is free and most popular.In this article am elaborate how to intall Zpanel in your system

1)  Clean OS (This installer is designed to install and configure ZPanel on a clean OS installation only!) 

#rm -rf *

2) Reboot your OS
#reboot

3 ) Download the install files from Github

# wget https://raw.github.com/zpanel/installers/master/install/CentOS-6_4/10_1_1.sh

4)  Change the permissions

#chmod +x 10_1_1.sh
5)  Run the installer

#./10_1_1.sh