Creating first simple AWS EC2 Instance
In this post we are going to discuss how to create our first AWS EC2 instance. If we compare a EC2 instances with our traditional infrastructure then it can be understood as a server.
Steps to create an EC2 instance
Login to your AWS management console and follow the below steps to proceed further.
In next blog we will learn how to connect to an EC2 instance using putty.
Steps to create an EC2 instance
Login to your AWS management console and follow the below steps to proceed further.
In next blog we will learn how to connect to an EC2 instance using putty.
Creating a Postgres(RDS) on Amazon Web Services (AWS)
Himanshu
Amazon Web Services
,
AWS
,
funoracleapps
,
Postgres
,
Postgres Installation
,
RDS
31 comments
In this post I am going to share how can we configure a Postgres Database using RDS service on Amazon Web Services.
I would be using the AWS free tier for this setup.
Once we login to AWS account go to Services Tab and select RDS.
Click on Launch New DB Instance and follow the below steps to proceed further.
Connecting to Postgres Database using the pgadmin4 tool.
I would be using the AWS free tier for this setup.
Once we login to AWS account go to Services Tab and select RDS.
Click on Launch New DB Instance and follow the below steps to proceed further.
Connecting to Postgres Database using the pgadmin4 tool.

Creating a Oracle Relation Database Service(RDS) on Amazon Web Services (AWS)
AWS is one of the major giants in Cloud technology today. In this post we will learn how to create a Relation Database Service on AWS.
Select the instances Tab and Select Launch DB Instance
Oracle Enterprise Edition is included in free-tier. Select Oracle EE.
Fill the details as per you need.



DB instance creation will take some time.
Click on the instance name to see the details.
Select Instance Actions and select See Details for check further details.
To create a RDS service you should register on AWS and create a account. Amazon provide a free tier account which can be used for 12 months and has sufficient free services available to practise.
I am also using a free-tier AWS account for writing this post.
Once we login to AWS account go to Services Tab and select RDS.
Select the instances Tab and Select Launch DB Instance
Oracle Enterprise Edition is included in free-tier. Select Oracle EE.
Fill the details as per you need.




DB instance creation will take some time.
Once the instance is created it will be available.
Click on the instance name to see the details.
Select Instance Actions and select See Details for check further details.
Connecting to RDS instance using sqlplus or SQL Developer.
HostName: oraws.cyn2uth5ocpa.ap-south-1.rds.amazonaws.com
Port: 1521
Username: awsrds
Password : awsrds_password
Connection String:
PS E:\instantclient-basic-windows.x64-12.1.0.2.0\instantclient_12_1> ./sqlplus.exe awsrds/******@"(DESCRIPTI
ON=(ADDRESS=(PROTOCOL=TCP)(HOST=oraws.cyn2uth5ocpa.ap-south-1.rds.amazonaws.com)
>> (PORT=1521))(CONNECT_DATA=(SID=ORAWS)))"
SQL*Plus: Release 12.1.0.2.0 Production on Thu Apr 20 03:10:36 2017
Copyright (c) 1982, 2014, Oracle. All rights reserved.
Last Successful login time: Thu Apr 20 2017 03:10:03 +05:30
Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options
SQL> select name from v$database;
NAME
---------
ORAWS
I got "ORA-12170: TNS:Connect timeout occurred."error when connecting to Oracle Database on RDS
Solution:
Add entry in security group inbound connection tab.
Solution:
Add entry in security group inbound connection tab.
Installation of Oracle 11g Database on Oracle Virtual Box
In this post we will look into steps for installation of Oracle 11g database on Virtual Box.
We need to download Oracle 11g software for Linux from Oracle site.
The installation will be done on Oracle Virtual box having Oracle Enterprise Linux. Detailed steps for installation of Virtual Box and OEL is posted earlier. Please refer Oracle Virtual Box Installation for detailed steps.
Only we need to make sure we defined hardisk and RAM to virtual machine as per your need.
I have given 50 GB hard disk and 2 GB RAM to my virtual machine which will be used for the installation.
The layout of the file system is as below:
Once the machine is prepared will proceed with database installation and creation.
/u01 -- will be used for Oracle Home
/datatop -- will be used for datafiles
Install the pre-required rpm's for oracle database installation using yum.This will also create a oracle OS user that will be used for installing the database.
[root@funoraclecore yum.repos.d]# yum install oracle-rdbms-server-11gR2-preinstallLoaded plugins: refresh-packagekit, securityol6_UEK_latest | 1.2 kB 00:00 ^[[Bol6_UEK_latest/primary 40% [======================== ] 941 kB/s | 13 MB 00:19 ol6_UEK_latest/primary | 31 MB 00:25 ol6_UEK_latest 659/659ol6_latest | 1.4 kB 00:00 ol6_latest/primary | 63 MB 00:52 ol6_latest 38729/38729Setting up Install ProcessResolving Dependencies--> Running transaction check---> Package oracle-rdbms-server-11gR2-preinstall.x86_64 0:1.0-13.el6 will be installed--> Processing Dependency: compat-libcap1 for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Processing Dependency: ksh for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Processing Dependency: libaio-devel for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Processing Dependency: compat-libstdc++-33 for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Running transaction check---> Package compat-libcap1.x86_64 0:1.10-1 will be installed---> Package compat-libstdc++-33.x86_64 0:3.2.3-69.el6 will be installed---> Package ksh.x86_64 0:20120801-33.el6 will be installed---> Package libaio-devel.x86_64 0:0.3.107-10.el6 will be installed--> Finished Dependency Resolution Dependencies Resolved ======================================================================================================================================================================== Package Arch Version Repository Size========================================================================================================================================================================Installing: oracle-rdbms-server-11gR2-preinstall x86_64 1.0-13.el6 ol6_latest 18 kInstalling for dependencies: compat-libcap1 x86_64 1.10-1 ol6_latest 17 k compat-libstdc++-33 x86_64 3.2.3-69.el6 ol6_latest 183 k ksh x86_64 20120801-33.el6 ol6_latest 760 k libaio-devel x86_64 0.3.107-10.el6 ol6_latest 13 k Transaction Summary========================================================================================================================================================================Install 5 Package(s) Total download size: 990 kInstalled size: 2.5 MIs this ok [y/N]: yIs this ok [y/N]: YDownloading Packages:(1/5): compat-libcap1-1.10-1.x86_64.rpm | 17 kB 00:00 (2/5): compat-libstdc++-33-3.2.3-69.el6.x86_64.rpm | 183 kB 00:00 (3/5): ksh-20120801-33.el6.x86_64.rpm | 760 kB 00:00 (4/5): libaio-devel-0.3.107-10.el6.x86_64.rpm | 13 kB 00:00 (5/5): oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64.rpm | 18 kB 00:00 ------------------------------------------------------------------------------------------------------------------------------------------------------------------------Total 281 kB/s | 990 kB 00:03 warning: rpmts_HdrFromFdno: Header V3 RSA/SHA256 Signature, key ID ec551f03: NOKEYRetrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracleImporting GPG key 0xEC551F03: Userid : Oracle OSS group (Open Source Software group) <build@oss.oracle.com> Package: 6:oraclelinux-release-6Server-4.0.4.x86_64 (@anaconda-OracleLinuxServer-201302251503.x86_64/6.4) From : /etc/pki/rpm-gpg/RPM-GPG-KEY-oracleIs this ok [y/N]: YRunning rpm_check_debugRunning Transaction TestTransaction Test SucceededRunning Transaction Installing : ksh-20120801-33.el6.x86_64 1/5
[root@funoraclecore yum.repos.d]# id oracleuid=54321(oracle) gid=54321(oinstall) groups=54321(oinstall),54322(dba) [root@funoraclecore ~]# passwd oracleChanging password for user oracle.New password:
The zip files that would be downloaded for oracle needs to be unzipped. Folder with data base name will be created.
Set the below environment parameter in .bash_profile file for oracle user.
Select Yes and Continue
Please ignore the below errors as we have already higher version of packages installed.
Run the mentioned scripts as root user.
SQL> select name,open_mode from v$database;
We need to download Oracle 11g software for Linux from Oracle site.
The installation will be done on Oracle Virtual box having Oracle Enterprise Linux. Detailed steps for installation of Virtual Box and OEL is posted earlier. Please refer Oracle Virtual Box Installation for detailed steps.
Only we need to make sure we defined hardisk and RAM to virtual machine as per your need.
I have given 50 GB hard disk and 2 GB RAM to my virtual machine which will be used for the installation.
The layout of the file system is as below:
Once the machine is prepared will proceed with database installation and creation.
/u01 -- will be used for Oracle Home
/datatop -- will be used for datafiles
Install the pre-required rpm's for oracle database installation using yum.This will also create a oracle OS user that will be used for installing the database.
[root@funoraclecore yum.repos.d]# mv public-yum-ol6.repo public-yum-ol6.repo_orig[root@funoraclecore yum.repos.d]# ls- ltrbash: ls-: command not found[root@funoraclecore yum.repos.d]# ls -ltrtotal 4-rw-r--r--. 1 root root 1953 Feb 24 2013 public-yum-ol6.repo_orig[root@funoraclecore yum.repos.d]# wget http://public-yum.oracle.com/public-yum-ol6.repo--2017-04-09 20:01:30-- http://public-yum.oracle.com/public-yum-ol6.repoResolving public-yum.oracle.com... 23.32.28.209, 23.32.28.208Connecting to public-yum.oracle.com|23.32.28.209|:80... connected.HTTP request sent, awaiting response... 200 OKLength: 7748 (7.6K) [text/plain]Saving to: “public-yum-ol6.repo” 100%[==============================================================================================================================>] 7,748 --.-K/s in 0s 2017-04-09 20:01:31 (107 MB/s) - “public-yum-ol6.repo” saved [7748/7748] [root@funoraclecore yum.repos.d]# ls -ltrtotal 12-rw-r--r--. 1 root root 1953 Feb 24 2013 public-yum-ol6.repo_orig-rw-r--r--. 1 root root 7748 Apr 4 01:05 public-yum-ol6.repo[root@funoraclecore yum.repos.d]# id oracleid: oracle: No such user
[root@funoraclecore yum.repos.d]# yum install oracle-rdbms-server-11gR2-preinstallLoaded plugins: refresh-packagekit, securityol6_UEK_latest | 1.2 kB 00:00 ^[[Bol6_UEK_latest/primary 40% [======================== ] 941 kB/s | 13 MB 00:19 ol6_UEK_latest/primary | 31 MB 00:25 ol6_UEK_latest 659/659ol6_latest | 1.4 kB 00:00 ol6_latest/primary | 63 MB 00:52 ol6_latest 38729/38729Setting up Install ProcessResolving Dependencies--> Running transaction check---> Package oracle-rdbms-server-11gR2-preinstall.x86_64 0:1.0-13.el6 will be installed--> Processing Dependency: compat-libcap1 for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Processing Dependency: ksh for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Processing Dependency: libaio-devel for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Processing Dependency: compat-libstdc++-33 for package: oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64--> Running transaction check---> Package compat-libcap1.x86_64 0:1.10-1 will be installed---> Package compat-libstdc++-33.x86_64 0:3.2.3-69.el6 will be installed---> Package ksh.x86_64 0:20120801-33.el6 will be installed---> Package libaio-devel.x86_64 0:0.3.107-10.el6 will be installed--> Finished Dependency Resolution Dependencies Resolved ======================================================================================================================================================================== Package Arch Version Repository Size========================================================================================================================================================================Installing: oracle-rdbms-server-11gR2-preinstall x86_64 1.0-13.el6 ol6_latest 18 kInstalling for dependencies: compat-libcap1 x86_64 1.10-1 ol6_latest 17 k compat-libstdc++-33 x86_64 3.2.3-69.el6 ol6_latest 183 k ksh x86_64 20120801-33.el6 ol6_latest 760 k libaio-devel x86_64 0.3.107-10.el6 ol6_latest 13 k Transaction Summary========================================================================================================================================================================Install 5 Package(s) Total download size: 990 kInstalled size: 2.5 MIs this ok [y/N]: yIs this ok [y/N]: YDownloading Packages:(1/5): compat-libcap1-1.10-1.x86_64.rpm | 17 kB 00:00 (2/5): compat-libstdc++-33-3.2.3-69.el6.x86_64.rpm | 183 kB 00:00 (3/5): ksh-20120801-33.el6.x86_64.rpm | 760 kB 00:00 (4/5): libaio-devel-0.3.107-10.el6.x86_64.rpm | 13 kB 00:00 (5/5): oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64.rpm | 18 kB 00:00 ------------------------------------------------------------------------------------------------------------------------------------------------------------------------Total 281 kB/s | 990 kB 00:03 warning: rpmts_HdrFromFdno: Header V3 RSA/SHA256 Signature, key ID ec551f03: NOKEYRetrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracleImporting GPG key 0xEC551F03: Userid : Oracle OSS group (Open Source Software group) <build@oss.oracle.com> Package: 6:oraclelinux-release-6Server-4.0.4.x86_64 (@anaconda-OracleLinuxServer-201302251503.x86_64/6.4) From : /etc/pki/rpm-gpg/RPM-GPG-KEY-oracleIs this ok [y/N]: YRunning rpm_check_debugRunning Transaction TestTransaction Test SucceededRunning Transaction Installing : ksh-20120801-33.el6.x86_64 1/5
Installing : libaio-devel-0.3.107-10.el6.x86_64 2/5
Installing : compat-libstdc++-33-3.2.3-69.el6.x86_64 3/5
Installing : compat-libcap1-1.10-1.x86_64 4/5
Installing : oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64 5/5
Verifying : oracle-rdbms-server-11gR2-preinstall-1.0-13.el6.x86_64 1/5
Verifying : compat-libcap1-1.10-1.x86_64 2/5
Verifying : compat-libstdc++-33-3.2.3-69.el6.x86_64 3/5
Verifying : libaio-devel-0.3.107-10.el6.x86_64 4/5
Verifying : ksh-20120801-33.el6.x86_64 5/5
Installed: oracle-rdbms-server-11gR2-preinstall.x86_64 0:1.0-13.el6 Dependency Installed: compat-libcap1.x86_64 0:1.10-1 compat-libstdc++-33.x86_64 0:3.2.3-69.el6 ksh.x86_64 0:20120801-33.el6 libaio-devel.x86_64 0:0.3.107-10.el6 Complete!
[root@funoraclecore yum.repos.d]# id oracleuid=54321(oracle) gid=54321(oinstall) groups=54321(oinstall),54322(dba) [root@funoraclecore ~]# passwd oracleChanging password for user oracle.New password:
BAD PASSWORD: it is based on a dictionary wordRetype new password:
passwd: all authentication tokens updated successfully.
[root@funoraclecore ~]# ls -ld /media/sf_himanshu_sharedrwxrwx---. 1 root vboxsf 0 Apr 9 19:35 /media/sf_himanshu_share[root@funoraclecore ~]# usermod -G vboxsf oracle[root@funoraclecore ~]# id oracleuid=54321(oracle) gid=54321(oinstall) groups=54321(oinstall),492(vboxsf)
Changing permission of /u01 and /datatop
[root@funoraclecore Desktop]# chown oracle:oinstall /u01[root@funoraclecore Desktop]# chown oracle:oinstall /datatop[root@funoraclecore Desktop]# ls -ld /datatop /u01drwxr-xr-x. 3 oracle oinstall 4096 Apr 9 12:17 /datatopdrwxr-xr-x. 3 oracle oinstall 4096 Apr 9 12:17 /u01
Set the below environment parameter in .bash_profile file for oracle user.
TMP=/tmp; export TMPTMPDIR=$TMP; export TMPDIR ORACLE_HOSTNAME=funoraclecore.lab; export ORACLE_HOSTNAMEORACLE_BASE=/u01/oracle; export ORACLE_BASEORACLE_HOME=$ORACLE_BASE/product/11.2.0; export ORACLE_HOMEORACLE_SID=TEST12; export ORACLE_SIDPATH=$ORACLE_HOME/bin:$PATH; export PATH LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATHCLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
Go to database directory and launch run installer and proceed with GUI installer as below.
Provide the inputs as required.
Select Yes and Continue
Please ignore the below errors as we have already higher version of packages installed.
Run the mentioned scripts as root user.
Once installation is completed. Please verify database.
SQL> select name,open_mode from v$database;
NAME OPEN_MODE
--------- --------------------
TEST12 READ WRITE
Subscribe to:
Posts
(
Atom
)
No comments :
Post a Comment