Category Archives: Amazon Web Services

How to change/update key pair for ec2 instance – AWS

Instruction from AWS EC2 support: Log into your AWS accountgo to your EC2 ConsoleUnder NETWORK & SECURITY, click on Key Pair Click on Create Key PairGive your new key pair a name, save the .pem file. The name of the key pair will be used to connect to your instanceCreate SSH connection to your instance…
Read more

Changing the Time Zone on Amazon Linux

TIP: If you are using a Linux server with, Amazon Linux, RDS database and PHP, you also need to change the timezone settings on them! Amazon Linux instances are set to the UTC (Coordinated Universal Time) time zone by default, but you may wish to change the time on an instance to the local time…
Read more

How to install PHP 7 and MySQL on EC2 Instance – Amazon

1. Install Apache 2.4 and PHP 7.0 on Amazon Linux AMI # Remove current apache & php (If you have installed a earlier version or you are having problems. Don't worry this WILL NOT remove any of your files, and it will make backup's of any config files you have). sudo yum remove httpd* php*…
Read more

AWS CLOSE_WAIT socket problems!

A buildup of sockets in CLOSE_WAIT state may indicate an application programming error. A CLOSE_WAIT socket is a socket in which the connection has received a FIN and has yet to be closed by the application. In this state, it is the responsibility of the application to close the socket, although the operating system will…
Read more

How to update PHP to latest version on AWS EC2

Warning: Before doing anything, make backups!   Remove old versions of PHP and Apache The old Apache and PHP versions in the server can conflict with the new install. So it is recommended to stop the web server and remove them using the commands: sudo service httpd stop sudo service mysqld stop sudo yum remove httpd* php*…
Read more

Allow user ec2-user (Amazon AWS) write access

To allow user ec2-user (Amazon AWS) write access to the public web directory (/home6/producw6/public_html/blackmoretech), enter this command via Putty or Terminal, as the root user sudo: chown -R ec2-user /home6/producw6/public_html/blackmoretech Make sure permissions on that entire folder were correct: chmod -R 755 /home6/producw6/public_html/blackmoretech
Read more

How to create folder on amazon ec2 linux

To create a folder in the root directory through an ssh terminal and use that folder for your application: sudo mkdir /myApp Next, set write permissions to myApp folder sudo chmod -R 777 myApp Done, now you can add/edit files in that directory as ec2-user!
Read more

FTP using WordPress and Amazon Web Services

Recently I started using Amazon Web Services for hosting and what not... some way cool stuff there.  Something I immediately ran into was this problem: When I installed WordPress I could NOT install any plugins and/or updates, through the WordPress interface because it would not let me use SSH2 with my PEM key that AWS…
Read more