How to convert AWS .pem key to putty .ppk key

Here I have AWS key .pem , to connect with putty in windows we need the .ppk format ,so here i have to convert AWS .pem key to putty .ppk key ,in simple have to convert .pem to .ppk

How convert AWS .pem key to putty .ppk key for that we have lots of software available, here am going to show with the help of  PuTTYgen

1 Download .pem (Privacy Enhanced Mail) from  AWS , is a base64 container format for encoding keys and certificates

 

2 ) Download PuTTYgen from online and install

 

3) Open PuTTYgen

convert AWS .pem key to putty .ppk key

4) Click Load button and load the .pem files

convert AWS .pem key to putty .ppk key

5) Click “save private key ” button and save your ppk files

so you converted AWS .pem key to Putty Private Key(ppk) or in simple .pem to .ppk

How to setup two domain using Lamp or XAMPP AWS Linux 2

Suppose we need to create two domain with xampp Let say tutorialshore.com and viewshore.com

First we have to install xampp in your AWS Linux 2  see below link for that

How to install xampp and FTP in AWS Linux 2 server

Then folle below steps

1 Allow custom virtual hosts from Apache config


open Apache config file using below command

# vi /opt/lampp/etc/httpd.conf

 

Find out below code
# Virtual hosts
#Include etc/extra/httpd-vhosts.conf

Replace above code with 

# Virtual hosts
Include etc/extra/httpd-vhosts.conf

 

2) Add custom domain in the hosts file

#vi /etc/hosts


127.0.0.3	tutorialshore.com
127.0.0.5	viewshore.com



3) Add custom domain in the hosts file

#vi /etc/hosts
 
add this two host at the end

127.0.0.3	tutorialshore.com
127.0.0.5	viewshore.com

4) Create your virtual hosts

#vi /opt/lampp/etc/extra/httpd-vhosts.conf

Add below line at the end


<VirtualHost 127.0.0.3:80>
 DocumentRoot "/opt/lampp/htdocs/tutorialshore"
 DirectoryIndex index.php

 <Directory "/opt/lampp/htdocs/tutorialshore">
 Options All
 AllowOverride All
 Require all granted
 </Directory>
</VirtualHost>

<VirtualHost 127.0.0.5:80>
 DocumentRoot "/opt/lampp/htdocs/viewshore"
 DirectoryIndex index.php

 <Directory "/opt/lampp/htdocs/viewshore">
 Options All
 AllowOverride All
 Require all granted
 </Directory>
</VirtualHost>
  



5) Create project Directoty

#cd /opt/lampp/htdocs
#mkdir tutorialshore
#mkdir viewshore

6) Upload your files and enjoy with your two new website

How to install LAMP in AWS server

Amazon Web Services is a one of the most flexible hosting service providers,but most of them are facing difficult how to install  LAMP (Apache , MySQL and PHP ) in AWS with out using paid Cpanel service . Here am going to ellobrate by steps how to install LAMP in AWS server

1 Install Apache

# sudo yum install httpd

# sudo systemctl start httpd.service

#sudo systemctl enable httpd.service

Try https://IP ADDRESS in browsers

 2  Install Database

#sudo yum install mariadb-server mariadb

# sudo yum install mariadb-server mariadb

# sudo mysql_secure_installation

#sudo systemctl enable mariadb.service

3) Install phpMyAdmin

# sudo yum Install phpMyAdmin

Try  http://yourIPaddress/phpmyadmin

How to install xampp and FTP in AWS Linux 2 server

steps to install xampp and FTP in AWS Linux 2 server

steps to install xampp

Step 1

Download xampp PHP version 7

# wget https://www.apachefriends.org/xampp-files/7.2.2/xampp-linux-x64-7.2.2-0-installer.run

Step 2

Change file Permission

#chmod +x xampp-linux-x64-7.2.2-0-installer.run

Step 3

Run installer

#./xampp-linux-x64-7.2.2-0-installer.run

Step 4

Run xampp service

#sudo /opt/lampp/xampp start

steps to install FTP

Steps 1

install vsftp

#sudo yum install vsftpd

Steps 2

add Custom TCP Rule in security group

 Log in to the AWS EC2 Management Console and select Security Groups from the navigation tree on the left. Select the security group assigned to your EC2 instance. Select the Inbound tab and add port range 20-21

Now the  Inbound tab  look like this 
Type	        Protocol   Port Range	Source
SSH	         TCP	     22	        ip/32
HTTP	         TCP	     80	        0.0.0.0/0
Custom TCP Rule	 TCP	   20 - 21	0.0.0.0/0
Custom TCP Rule  TCP	  1024 - 1048	0.0.0.0/

Steps 3

Open configure files make sure that u have the below configuration

 #Vi /etc/vsftpd/vsftpd.conf 

anonymous_enable=NO
local_enable=YES
write_enable=YES
local_umask=022
dirmessage_enable=YES
xferlog_enable=YES
connect_from_port_20=YES
xferlog_std_format=YES
chroot_local_user=YES
chroot_list_enable=YES
listen=YES

pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES
pasv_enable=YES
pasv_min_port=1024
pasv_max_port=1048
pasv_address=**.***.***.** #your ip address
local_root=/opt/lampp/htdocs
use_localtime=YES

Steps 4

Create FTP user

# sudo adduser ftpuser

Steps 5

Create ftpuser Password

# sudo passwd ftpuser
type password

Steps 6

Login using ftp client

Open Filezilla

Host : YOUR IP ADDRESS

User :  ftpuser

Password : YOUR PASSWORD
and connect