sabato 27 febbraio 2016

How to create an SSH Tunnel Using the PuTTY Program on Windows to be able to use a remote WebLogic on Oracle Cloud on a local Eclipse

Suppose that you are working on an Oracle Cloud Domain:

Where you have Admin server on port 9001 (default on Oracle Cloud) on public IP address 141.145.25.45
WebLogic Admin, user: weblogic
WebLogic Admin, password: weblogicPWD

Once you have configured Putty as described in my previous post:
[How to access in SSH to Oracle Cloud using Putty and ppk key]

Then you can configure Tunnelling:

Select Tunnels on the Tree, put 9001 as "source port" and put in "destination" your public ip on cloud of the WLS Admin Server and your admin port, in my example 141.145.25.45:9001

Click on Add button:



Verify that "Local" and "Auto" field are selected:


Start your putty session and leave it open and running:


Now start your Eclipse:

Click on Window->Show View->Other ...
Select Server



Now you can see the tab Servers on Eclipse:



On the tab Servers, click on the link to create a new server:

Select the version of WLS that you are using on the Cloud:
Click Next:



You must have installed on your local Machine (where Eclipse is running) the same version of WLS.
Fill the Weblogic Home field with the path of your local installation and do the same for the Java Home field:

Click Next:


We are using Tunnelling, so use localhost as Remote Host, and 9001 as port:
Fill the user and password field with a valid user and password for the Admin Server:

in this sample are weblogic/weblogicPWD


Try the Test Connection Button:

Click on Finish:


Now you can see your remote Weblogic in Cloud as a local Weblogic Up & Running:





venerdì 26 febbraio 2016

How to create an Oracle Cloud Storage Container

If you need to create an Oracle Cloud Storage Container, you need it for example if you are creating an Oracle Database Cloud Service with backup, you can do this in different ways:

- With Rest services
- With tools like CloudBerry
- With OEPE (Oracle Enterprise Pack for Eclipse) and the Cloud Plugin.

Suppose that you are working on the following Cloud Domain:

Identity Domain: gse00000410
Login UserName: cloud.admin
Login Password: FabryPWD

The target is to create a Storage Container named: MariniStorage


----------[ Rest Services ]----------

We need to execute 2 command, the first one is to obtain an Auth-Token and a Storage-Url, the second one will create the Storage Container.

Here you can see the detail of the command and of the response:

[weblogic@localhost ~]$ curl -v -s -X GET -H "X-Storage-User: Storage-gse00000410:cloud.admin" -H "X-Storage-Pass: FabryPWD" https://gse00000410.storage.oraclecloud.com/auth/v1.0

* About to connect() to gse00000410.storage.oraclecloud.com port 443 (#0)
*   Trying 160.34.16.106...
* Connected to gse00000410.storage.oraclecloud.com (160.34.16.106) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
*   CAfile: /etc/pki/tls/certs/ca-bundle.crt
  CApath: none
* SSL connection using TLS_RSA_WITH_AES_128_CBC_SHA
* Server certificate:
*     subject: CN=*.storage.oraclecloud.com,O=Oracle Corporation,L=Redwood Shores,ST=California,C=US
*     start date: Aug 07 00:00:00 2015 GMT
*     expire date: Oct 05 23:59:59 2016 GMT
*     common name: *.storage.oraclecloud.com
*     issuer: CN=VeriSign Class 3 Secure Server CA - G3,OU=Terms of use at https://www.verisign.com/rpa (c)10,OU=VeriSign Trust Network,O="VeriSign, Inc.",C=US
> GET /auth/v1.0 HTTP/1.1
> User-Agent: curl/7.29.0
> Host: gse00000410.storage.oraclecloud.com
> Accept: */*
> X-Storage-User: Storage-gse00000410:cloud.admin
> X-Storage-Pass: 
FabryPWD
>
< HTTP/1.1 200 OK
< Date: Thu, 25 Feb 2016 06:06:27 GMT
< X-Auth-Token: AUTH_tk68a22aa11a48e6846da268d9d2c808f7
< X-Storage-Token: AUTH_tk68a22aa11a48e6846da268d9d2c808f7
< X-Storage-Url: https://em2.storage.oraclecloud.com/v1/Storage-gse00000410
< Content-Length: 0
< Server: Oracle-Storage-Cloud-Service


[weblogic@localhost ~]$ curl -v -s -X PUT -H "X-Auth-Token: AUTH_tk68a22aa11a48e6846da268d9d2c808f7" https://em2.storage.oraclecloud.com/v1/Storage-gse00000410/MariniStorage
* About to connect() to em2.storage.oraclecloud.com port 443 (#0)
*   Trying 160.34.16.106...
* Connected to em2.storage.oraclecloud.com (160.34.16.106) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
*   CAfile: /etc/pki/tls/certs/ca-bundle.crt
  CApath: none
* SSL connection using TLS_RSA_WITH_AES_128_CBC_SHA
* Server certificate:
*     subject: CN=*.storage.oraclecloud.com,O=Oracle Corporation,L=Redwood Shores,ST=California,C=US
*     start date: Aug 07 00:00:00 2015 GMT
*     expire date: Oct 05 23:59:59 2016 GMT
*     common name: *.storage.oraclecloud.com
*     issuer: CN=VeriSign Class 3 Secure Server CA - G3,OU=Terms of use at https://www.verisign.com/rpa (c)10,OU=VeriSign Trust Network,O="VeriSign, Inc.",C=US
> PUT /v1/Storage-gse00000410/MariniStorage HTTP/1.1
> User-Agent: curl/7.29.0
> Host: em2.storage.oraclecloud.com
> Accept: */*
> X-Auth-Token: AUTH_tk68a22aa11a48e6846da268d9d2c808f7
>
< HTTP/1.1 201 Created
< X-Trans-Id: tx69e0087526814f74a24fa-0056ce9b56ga
< Date: Thu, 25 Feb 2016 06:12:39 GMT
< Connection: keep-alive
< X-Last-Modified-Timestamp: 1456380759.12206
< Content-Type: text/html;charset=UTF-8
< Content-Length: 0
< Server: Oracle-Storage-Cloud-Service


----------[ CloudBerry ]----------

You need CloudBerry Explorer for OpenStack Freeware.
You can download it from:
http://www.cloudberrylab.com/free-openstack-storage-explorer.aspx

Install it and add a new Oracle Cloud Storage Account:


Now you can see your containers and create a new one using the blue cube icon "new container".


----------[ OEPE and the Cloud Plugin ]----------

You can download OEPE from:
http://www.oracle.com/technetwork/developer-tools/eclipse/downloads/index.html

Install it and from Window->Show View->Other, select the Oracle Cloud Plugin.

Now under iassmb_Storage you can see your containers and with the right button of the mouse if you click on iassmb_Storage you can create a new container.  



martedì 16 febbraio 2016

Domain To Partition Conversion Tool - From WLS 10.3.6/12c to WLS 12.2.1

You can download D-PCT tool from:

http://www.oracle.com/technetwork/middleware/weblogic/downloads/wls-main-097127.html

Readme file : http://download.oracle.com/otn/nt/middleware/12c/1221/wls1221_D-PCT-README.txt

" ... The Domain to Partition Conversion Tool (D-PCT) provides the ability to migrate an existing WebLogic Server 10.3.6, 12.1.2, 12.1.3 or 12.2.1 domain to a partition in a WebLogic Server 12.2.1 domain. This tool consists of two components: an export tool, which is used on the WebLogic Server installation that hosts the source domain; and an import tool, which is used on the target WebLogic Server 12.2.1 installation.
You can use this tool to create and configure partition, resource groups, and resource group templates. By default, this tool moves all applications, libraries, and resources to the new partition. Optionally, it also provides a mechanism for selecting individual applications, libraries, and resources. ... "

To use the D-PCT Tool you need to download (from the previous link) and install patch 22644507 on the target WebLogic Server 12.2.1 installation