Thursday, March 20, 2014

Packt Publishing now Buy One, Get One Free

Buy One, Get One Free on all of #Packt’s 2000 eBooks! bit.ly/1j26nPN #Packt2k


Tuesday, March 11, 2014

Big Data Oracle NoSQL in No Time - Setting up 1x1 Topology Part 3

Big Data Oracle NoSQL in No Time - Setting up 1x1 Topology Part 3

Index
Big Data Oracle NoSQL in No Time - Getting Started Part 1
Big Data Oracle NoSQL in No Time - Startup & Shutdown Part 2

Big Data Oracle NoSQL in No Time - Setting up 1x1 Topology Part 3
Big Data Oracle NoSQL in No Time - Expanding 1x1 to 3x1 Topology Part 4
Big Data Oracle NoSQL in No Time - From 3x1 to 3x3 Topology Part 5
Big Data Oracle NoSQL in No Time - Smoke Testing Part 6
Big Data Oracle NoSQL in No Time - Increasing Throughput Read/Write Part 7
Big Data Oracle NoSQL in No Time - It is time to Upgrade
Big Data Oracle NoSQL in No Time - It is time to Load Data for a Simple Use Case

Now let us quickly create 1x1 Topology

$ export KVBASE=/oraclenosql/lab
$ export KVHOME=$KVBASE/server1/oraclesoftware/kv-2.0.39
$ java -jar $KVHOME/lib/kvstore.jar runadmin -port 5000 -host server1
kv-> configure -name mystore
Store configured: mystore
kv-> plan deploy-datacenter -name "datacenter1" -rf 1 -wait
Executed plan 1, waiting for completion...
Plan 1 ended successfully
kv-> plan deploy-sn -dc dc1 -port 5000 -wait -host server1 -wait
Executed plan 2, waiting for completion...
Plan 2 ended successfully
kv-> plan deploy-admin -sn sn1 -port 5001 -wait
Executed plan 3, waiting for completion...
Plan 3 ended successfully
kv->topology create -name 1x1 -pool AllStorageNodes -partitions 30
Created: 1x1
kv-> plan deploy-topology -name 1x1 -wait
Executed plan 4, waiting for completion...
Plan 4 ended successfully
kv-> show topology
store=mystore  numPartitions=30 sequence=34
  dc=[dc1] name=datacenter1 repFactor=1

  sn=[sn1]  dc=dc1 server1:5000 capacity=1 RUNNING
    [rg1-rn1] RUNNING
          No performance info available

  shard=[rg1] num partitions=30
    [rg1-rn1] sn=sn1

kv->





















So what we have done ?

configure -name mystore
We created a Key Value pair store and we named it as mystore with the configure command.

plan deploy-datacenter -name "datacenter1" -rf 1 -wait
We created a plan which deploys a datacenter and with the replication factor 1. 
Factor one is not advisable for nosql deployment since only one copy of the data is maintained. In the event of failure all the data is lost.
Factor three is a good point to start with a nosql deployment and in this series we will try to achieve it.

plan deploy-sn -dc dc1 -port 5000 -host server1 -wait
We deployed a storage node using the option deploy-sn and to that we passed the data center identification number, the server name and the port number. To know the data center identification number issue with command "show topology" and it will gave us "dc1"

plan deploy-admin -sn sn1 -port 5001 -wait
In addition to the storage node we deployed admin server on this node. For high availability admin server can be configured more and the best to start with is on three nodes.

topology create -name 1x1 -pool AllStorageNodes -partitions 30
We created a topology with name 1x1. To the create topology command we created a storage pool with 30 partitions. Creating a storage pool can also be done with separate command "pool create -name AllStorageNodes". Pay attention to the partitions since it is a one time configuration parameter since this is a demo environment I have given 30 partitions.

plan deploy-topology -name 1x1 -wait
Finally we deployed the topology that we created. Using show topology we can verify the topology.









Thursday, March 6, 2014

Big Data Oracle NoSQL in No Time - Startup & Shutdown Part 2

Big Data Oracle NoSQL in No Time - Startup & Shutdown Part 2

Index
Big Data Oracle NoSQL in No Time - Getting Started Part 1
Big Data Oracle NoSQL in No Time - Startup & Shutdown Part 2

Big Data Oracle NoSQL in No Time - Setting up 1x1 Topology Part 3
Big Data Oracle NoSQL in No Time - Expanding 1x1 to 3x1 Topology Part 4
Big Data Oracle NoSQL in No Time - From 3x1 to 3x3 Topology Part 5
Big Data Oracle NoSQL in No Time - Smoke Testing Part 6
Big Data Oracle NoSQL in No Time - Increasing Throughput Read/Write Part 7
Big Data Oracle NoSQL in No Time - It is time to Upgrade
Big Data Oracle NoSQL in No Time - It is time to Load Data for a Simple Use Case

The below procedure will startup and shutdown the 4 node Oracle NoSQL Cluster.

Startup
export KVBASE=/oraclenosql/lab
export KVHOME=$KVBASE/server1/oraclesoftware/kv-2.0.39
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVBASE/server1/storage &
export KVHOME=$KVBASE/server2/oraclesoftware/kv-2.0.39
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVBASE/server2/storage &
export KVHOME=$KVBASE/server3/oraclesoftware/kv-2.0.39
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVBASE/server3/storage &
export KVHOME=$KVBASE/server4/oraclesoftware/kv-2.0.39
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVBASE/server4/storage &

Shutdown
export KVBASE=/oraclenosql/lab
export KVHOME=$KVBASE/server4/oraclesoftware/kv-2.0.39
java -jar $KVHOME/lib/kvstore.jar stop -root $KVBASE/server4/storage
export KVHOME=$KVBASE/server3/oraclesoftware/kv-2.0.39
java -jar $KVHOME/lib/kvstore.jar stop -root $KVBASE/server3/storage
export KVHOME=$KVBASE/server2/oraclesoftware/kv-2.0.39
java -jar $KVHOME/lib/kvstore.jar stop -root $KVBASE/server2/storage
export KVHOME=$KVBASE/server1/oraclesoftware/kv-2.0.39
java -jar $KVHOME/lib/kvstore.jar stop -root $KVBASE/server1/storage

Wednesday, March 5, 2014

Big Data Oracle NoSQL in No Time - Getting Started Part 1

Big Data Oracle NoSQL in No Time - Getting Started Part 1

Index
Big Data Oracle NoSQL in No Time - Getting Started Part 1
Big Data Oracle NoSQL in No Time - Startup & Shutdown Part 2

Big Data Oracle NoSQL in No Time - Setting up 1x1 Topology Part 3
Big Data Oracle NoSQL in No Time - Expanding 1x1 to 3x1 Topology Part 4
Big Data Oracle NoSQL in No Time - From 3x1 to 3x3 Topology Part 5
Big Data Oracle NoSQL in No Time - Smoke Testing Part 6
Big Data Oracle NoSQL in No Time - Increasing Throughput Read/Write Part 7
Big Data Oracle NoSQL in No Time - It is time to Upgrade
Big Data Oracle NoSQL in No Time - It is time to Load Data for a Simple Use Case

I have been exploring NoSQL and Hadoop since the buzz word started to flood. Have been doing research on Oracle NoSQL mostly on the use case and started to find options to use it in my day to day life and seeing a lot of cases which can help. I will start to blog more on that but before I begin with the use case want to tell my friends how to setup a simple Oracle NoSQL Cluster.

This is only for study purpose. I am using only one physical server and creating four virtual nosql store running on different ports.

Modify the /etc/hosts file with the alias
10.0.0.1 labserver.localdomain.com server1 server2 server3 server4

Download nosql software to /oraclenosql/lab/stage
Here I am using 11g later will upgrade to 12c

Creating a staging folder and create a base nosql folder with binaries in it.
cd /oraclenosql/lab/
mkdir stage
mkdir nosql_11g;cd nosql_11g
mkdir oraclesoftware storage
cd oraclesoftware
cp /oraclenosql/lab/stage/kv-ee-2.0.39.zip .
unzip kv-ee-2.0.39.zip

Clone the staged binary into four servers. This cloning folder will help me to create different case studies quickly by just deleting the folders and re-creating them again.

cd /oraclenosql/lab
cp -Rf nosql_11g server1
cp -Rf nosql_11g server2
cp -Rf nosql_11g server3
cp -Rf nosql_11g server4


echo "server 1"
export KVHOME=/oraclenosql/lab/server1/oraclesoftware/kv-2.0.39
export KVSTORAGE=/oraclenosql/lab/server1/storage
java -jar $KVHOME/lib/kvstore.jar makebootconfig -root $KVSTORAGE -capacity 1 -harange 5010,5020 -admin 5001 -port 5000 -host server1
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVSTORAGE &

echo "server 2"
export KVHOME=/oraclenosql/lab/server2/oraclesoftware/kv-2.0.39
export KVSTORAGE=/oraclenosql/lab/server2/storage
java -jar $KVHOME/lib/kvstore.jar makebootconfig -root $KVSTORAGE -capacity 1 -harange 5110,5120 -admin 5101 -port 5100 -host server2
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVSTORAGE &

echo "server 3"
export KVHOME=/oraclenosql/lab/server3/oraclesoftware/kv-2.0.39
export KVSTORAGE=/oraclenosql/lab/server3/storage
java -jar $KVHOME/lib/kvstore.jar makebootconfig -root $KVSTORAGE -capacity 1 -harange 5210,5220 -admin 5201 -port 5200 -host server3
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVSTORAGE &

echo "server 4"
export KVHOME=/oraclenosql/lab/server4/oraclesoftware/kv-2.0.39
export KVSTORAGE=/oraclenosql/lab/server4/storage
java -jar $KVHOME/lib/kvstore.jar makebootconfig -root $KVSTORAGE -capacity 1 -harange 5310,5320 -admin 5301 -port 5300 -host server4
nohup java -jar $KVHOME/lib/kvstore.jar start -root $KVSTORAGE &

export KVHOME=/oraclenosql/lab/server1/oraclesoftware/kv-2.0.39
java -jar $KVHOME/lib/kvstore.jar runadmin -port 5000 -host server1
kv>

Make sure you get the KV prompt.
Also verify URL http://labserver.localdomain.com:5010



In the upcoming blog , we will see the below;
Startup and Shutdown Scripts
Setting up 1x1 topology
Expanding 1x1 to 3x1 topology
Moving from 3x1 to 3x3 topology
From 3x3 to 3x4 topology
Smoke Testing NoSQL

Monday, March 3, 2014

Play around with APEX 4.0 with Oracle APEX Cookbook

As always my best tool is APEX but when it comes to building an application then it does not take too much time. What about a website running out of APEX ? So here is some guidance from packpub book which helps you to explore APEX to build applications with the latest techniques in AJAX and Javascript using features such as plugins and dynamic actions. With HTML5 and CSS3 support, make the most out of the possibilities that APEX has to offer.



So what does this Cookbook cover ?

Creating a Basic APEX Application
Themes and Templates
Extending APEX
Creating Websheet Applications
APEX Plug-ins
Creating Multilingual APEX Applications
APEX APIs
Using Web Services
Publishing from APEX
APEX Environment
APEX Administration
Team Development
HTML5 and CSS3
Mobile

Is this good enough for building your company website ? Do let me know if you need more.

Popular Posts