
I thought about doing something more productive with my time than just DJ’ing to myself and my room mates. As a result, I decided to embark on the journey to become a certified Oracle DBA, and, also, be a CCNA (Certified Cisco Network Associate). But, as I already knew — one must crawl, before they walk, and they must also walk before they run. Simple, I suppose.
Following my philosophical train of thought about personal and intellectual development, I decided to start with the first of the three certifications on the pathway to becomming a DBA — an Oracle Certified Associate (OCA), which comes before the Oracle Certified Professional (OCP). The Oracle Certified Master (OCM) is the ultimate of these certifications, and grants an individual to call themself a Oracle DBA which carries a lot of weight behind it. From the look of things, they are in great demand and will not cease to be.
To train myself, I decided to be practical with my learning. I am a kinetic learning, from all the tests I took, and from my own personal experiences and observations.
After several tries to install Oracle on my Fedora 9 box, I, somewhat, abandoned the installation due to the huge work load I was expected to undergo just to run a database server. I do not have all this time. I am a college student with many other projects and goals in mind. So, I cheated, and downloaded an old copy of an Oracle database (10g) running in a VMWare environment under CentOS. I give much credit to the person who thought about emulating 10g, because setting up the Operating System’s environment variables, kernel configuration, network interfaces, and installing all required software libraries needed to run OUI (Oracle Universal Installer) can be quite cumbersome and overwhelming at times, for Linux newbies, and lazy college students that have to time on their hands due to class assignments, senior design research, and personal projects.
The first step I took in getting off the ground with this was to uncompress the package: VMWare-CentOS-Oracle.zip into an accessible folder on my local disk. After the extraction, I fired up VMWare player (which is now free for download), clicked on OPEN to browse for my virtual image to load, and selected the proper file that initiates this process. I was looking for a .vmx file, and, sure enough, it was parked in “VMWare-CentOS-Oracle” folder as sles.vmx in my case.
After having the image load up and bringing up a login interface, I had nowhere to go but consult the documentation that came with it. Consequently, I opened up the “howto.doc” instructions file and was told that the two available accounts were “root”, with a password set as “root”, and “oracle”, with a password set as “oracle” as well. I logged in as user oracle. And was greeted by an XFCE desktop interface. I was so happy!
I looked around, then glanced over the TERMINAL/console icon on the taskbar panel and proceeded on clicking on it. I was given the following option to:
[oracle@localhost ~]$
Choose your Oracle Home
1) Server 10.2 EE: /u01/app/oracle/product/10.2/db_1
To start/stop database, listener, new EM console
2) Client 10.2: /u01/app/oracle/product/10.2/client
To run Java EM and other tools
1
Your current environment:
ORACLE_BASE = /u01/app/oracle
ORACLE_HOME = /u01/app/oracle/product/10.2/db_1
ORACLE_SID = DB1
You can change your environment running:
. /home/oracle/.bash_profile
It didn’t matter. I just wanted to play, so I went into SERVER mode. As you can see, my choice was 1. Yeah!
To get things on the way, I started all necessary software for the Oracle database to run on my machine:
[oracle@localhost ~]$ lsnrctl start
LSNRCTL for Linux: Version 10.2.0.4.0 – Production on 21-AUG-2008 10:18:17
Copyright (c) 1991, 2007, Oracle. All rights reserved.
Starting /u01/app/oracle/product/10.2/db_1/bin/tnslsnr: please wait…
TNSLSNR for Linux: Version 10.2.0.4.0 – Production
System parameter file is /u01/app/oracle/product/10.2/db_1/network/admin/listener.ora
Log messages written to /u01/app/oracle/product/10.2/db_1/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost.localdomain)(PORT=1521)))
STATUS of the LISTENER
————————
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.4.0 – Production
Start Date 21-AUG-2008 10:18:18
Uptime 0 days 0 hr. 0 min. 1 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/oracle/product/10.2/db_1/network/admin/listener.ora
Listener Log File /u01/app/oracle/product/10.2/db_1/network/log/listener.log
Listening Endpoints Summary…
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))
Services Summary…
Service “PLSExtProc” has 1 instance(s).
Instance “PLSExtProc”, status UNKNOWN, has 1 handler(s) for this service…
The command completed successfully!
I also started SQLplus with the /NOLOG option which establishes no initial connection to the database:
[oracle@localhost ~]$ sqlplus /NOLOG
SQL*Plus: Release 10.2.0.4.0 – Production on Thu Aug 21 10:22:22 2008
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
I then proceeded to connecting to the database as SYSDBA (the highest of the administrative roles):
SQL> conn / as sysdba
Connected to an idle instance.
Now, I decide to fire it up using:
SQL> startup;
ORACLE instance started.
Total System Global Area 314572800 bytes
Fixed Size 1267236 bytes
Variable Size 163580380 bytes
Database Buffers 146800640 bytes
Redo Buffers 2924544 bytes
Database mounted.
Database opened.
Time for something else, since the database has been started:
SQL> exit
{Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 – Production
With the Partitioning, Data Mining and Real Application Testing options
[oracle@localhost ~]$ emctl start dbconsole
Oracle Enterprise Manager 10g Database Control Release 10.2.0.4.0
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
https://localhost:5500/em/console/aboutApplication
Starting Oracle Enterprise Manager 10g Database Control ……. started.
——————————————————————
Logs are generated in directory /u01/app/oracle/product/10.2/db_1/localhost_DB1/sysman/log
And, now, the most fun part is where I went ahead and did logged into the administrative panel through the HTTP server setup by Oracle. The hostname is: https://localhost:5500/em It brought up the following page where I logged in as “sys” with password “oracle” as a “SYSDBA”:
Shortly after, I browsed around what this portal had to offer to the SYSBA, and found the following information I could retrieve from the schema:
And, finally, I decided to see what the Administration tab had to offer me, so I navigated to it, and found the following tasks I could accomplish graphically:
Also, under this were more options from this administrative arsenal of tools: And, lastly, from the same category was this:[oracle@localhost ~]$ cd /u01/app/oracle/product/10.2/client
[oracle@localhost client]$ ls
assistants has jdbc nls oui root.sh wwg
bin hs jdk odbc owm root.sh.old xdk
cdata install jlib olap perl slax
cfgtoollogs install.platform jpub OPatch plsql sqlj
classes instantclient jre opmn precomp sqlplus
crs inventory ldap oracore racg srvm
css jar lib oraInst.loc rdbms sysman
diagnostics javavm network ord relnotes uix
Next time around, I will show how I create databases and tables using oracle. And will perform some very basic selection, insertion, updating, altering, and removing of data from the schema.
That’s it for now, boys and girls!
Having opened my console, I downloaded, then installed iperf (v2.0.2) on my machine:
[netfish@localhost ~]$ wget http://dast.nlanr.net/Projects/Iperf2.0/iperf-2.0.2.tar.gz
–2008-07-23 20:11:41– http://dast.nlanr.net/Projects/Iperf2.0/iperf-2.0.2.tar.gz
Resolving dast.nlanr.net… 141.142.232.90
Connecting to dast.nlanr.net|141.142.232.90|:80… connected.
HTTP request sent, awaiting response… 200 OK
Length: 233595 (228K) [application/x-gzip]
Saving to: `iperf-2.0.2.tar.gz’
100%[=======================================>] 233,595 942K/s in 0.2s
2008-07-23 20:11:41 (942 KB/s) – `iperf-2.0.2.tar.gz’ saved [233595/233595]
[netfish@localhost ~]$ tar zxvf iperf*gz
iperf-2.0.2/
iperf-2.0.2/m4/
[netfish@localhost ~]$ cd iperf-2.0.2
[netfish@localhost iperf-2.0.2]$ ./configure -prefix=/home/netfish/Software/iperf/
[netfish@localhost iperf-2.0.2]$ make
mmake[1]: Leaving directory `/home/netfish/iperf-2.0.2′
[netfish@localhost iperf-2.0.2]$ make install
Making install in compat
test -z “/home/netfish/Software/iperf//bin” || mkdir -p — “/home/netfish/Softwa
make[1]: Leaving directory `/home/netfish/iperf-2.0.2′
[netfish@localhost iperf-2.0.2]$ ls
aclocal.m4 config.h.in configure* include/ Makefile README
compat/ config.log configure.ac INSTALL Makefile.am src/
config.guess* config.status* depcomp* install-sh* Makefile.in stamp-h1
config.h config.sub* doc/ m4/ missing*
[netfish@localhost iperf-2.0.2]$ cd ..
[netfish@localhost ~]$ cd Software
[netfish@localhost Software]$ cd iperf
[netfish@localhost iperf]$ ls
bin/
[netfish@localhost iperf]$ cd bin
[netfish@localhost bin]$ ls
iperf*
[netfish@localhost bin]$ ./iperf -s -f M
———————————————
Server listening on TCP port 5001
TCP window size: 0.08 MByte (default)
————————————————————
[ 4] local 127.0.0.1 port 5001 connected with 127.0.0.1 port 49227
[ 5] local 127.0.0.1 port 5001 connected with 127.0.0.1 port 49228
[ 6] local 127.0.0.1 port 5001 connected with 127.0.0.1 port 49229
[ 7] local 127.0.0.1 port 5001 connected with 127.0.0.1 port 49230
[ 4] 0.0-60.1 sec 3714 MBytes 61.8 MBytes/sec
[ 5] 0.0-60.1 sec 3793 MBytes 63.1 MBytes/sec
[ 6] 0.0-60.1 sec 4470 MBytes 74.4 MBytes/sec
[ 7] 0.0-60.1 sec 3865 MBytes 64.3 MBytes/sec
[SUM] 0.0-60.1 sec 15842 MBytes 264 MBytes/sec
^A
Following this, I opened a second tab from my console (Shell No. 2) and send packets from that node, to the loopback address (localhost) to Port 5001, with a TCP window size of 0.25MB, for 60 seconds:
[netfish@localhost ~]$ cd Software/iperf/bin
[netfish@localhost bin]$ ./iperf -c localhost -P 4 -f M -w 256k -t 60
————————————————————
Client connecting to localhost, TCP port 5001
TCP window size: 0.25 MByte (WARNING: requested 0.25 MByte)
————————————————————
[ 6] local 127.0.0.1 port 49230 connected with 127.0.0.1 port 5001
[ 3] local 127.0.0.1 port 49227 connected with 127.0.0.1 port 5001
[ 4] local 127.0.0.1 port 49228 connected with 127.0.0.1 port 5001
[ 5] local 127.0.0.1 port 49229 connected with 127.0.0.1 port 5001
[ 6] 0.0-60.0 sec 3865 MBytes 64.4 MBytes/sec
[ 3] 0.0-60.0 sec 3714 MBytes 61.9 MBytes/sec
[ 4] 0.0-60.0 sec 3793 MBytes 63.2 MBytes/sec
[ 5] 0.0-60.0 sec 4470 MBytes 74.5 MBytes/sec
[SUM] 0.0-60.0 sec 15842 MBytes 264 MBytes/sec
[netfish@localhost bin]$
Knowing that Gigabit ethernet has theoretical limit of 128Mbps, I received an expected bandwidth peaking at around 264 MB/s.
QUIZ Can you tell why this value is over the 128MB/s rate?