Also Installed these Applications:
- Database oracle xe su pc win7 + INTERNET EXPLORER
- jboss AS and Oracle SQL Client on Linux Virtual Machine
Scenario a) PC connected to network with DNS available
LINUX VIRTUAL MACHINE INSTALLATION
Step 1 - Virtual box per win 7 installed
Step 2Linux Virtual machine creation
- From virtual box console create new virtual machine namedredhat 64 bit;
from network settings choose scheda con bridge
Step 3 - got file iso CentOS (versione 64 bit)
CentOS-5.4-x86_64-bin-DVD
Step 4- set file iso as installation source.
Step 5- installato CentOS sulla macchina virtuale (64 bit)
TASK COMPLETED
INSTALLATION SQL PLUS client on Linux
Step 1- created users sndadmin:users e oracle:oinstall
Step 2- installata jdk (rpm 64 ) su centos
Step 3
- installato istantclient Oracle (rpm ) x sqlplus su centos
comando: rpn -hi .....
oracle-instantclient-basic-10.2.0.4-1.x86_64.rpm
oracle-instantclient-jdbc-10.2.0.4-1.x86_64.rpm
oracle-instantclient-sqlplus-10.2.0.4-1.x86_64.rpm
STEP 4To have sqlplus and tnsnames.ora (copied from dir network/ADMIN in oracle xe) working (assume tnsnames in oracle home directory) set new properties in oracle home .bash_profile
PATH=$PATH:$HOME/bin:/usr/lib/oracle/10.2.0.4/client64/bin
export PATH
##aggiunta per utilizzo oracle
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/oracle/10.2.0.4/client64/lib
export LD_LIBRARY_PATH
SQLPATH=/usr/lib/oracle/10.2.0.4/client64/lib
export SQLPATH
TNS_ADMIN=/home/oracle
export TNS_ADMIN
TASK COMPLETED
CONNECTING ORACLE SQL PLUS CLIENT (Linux) TO ORACLE RDBMS ON (Win7)
Step 1
- Must define a rule on windows 7 firewall to allow connection from outside to port 1521 (oracle listener port).
Step 2
- As well manage linux iptables to allow http/https traffic to jboss (not recomanded ; step to repeat when restart linux)
[root@localhost log]# /etc/init.d/iptables save
Saving firewall rules to /etc/sysconfig/iptables: [ OK ]
[root@localhost log]# /etc/init.d/iptables stop
Flushing firewall rules: [ OK ]
Setting chains to policy ACCEPT: filter [ OK ]
Unloading iptables modules: [ OK ]
TASK COMPLETED
VIRTUAL BOX NETWORK CONFIGURATION FOR no Network Connection (see solution2 - that's better )
When pc has no network to have internal connection between windows pc and Linux Virtual change your Virtual machine network settings:
- Choose NAT mode
- define new port forwarding rules (es . windows ipconnfig command shows vbox ip= 192.168.56.1 while ifconfig from Linux shows ip = 10.0.2.15) as follows :
tcp 192.168.56.1 8888 10.0.2.15 8080 (per http)
tcp 192.168.56.1 8889 10.0.2.15 8443 (per https)
tcp 192.168.56.1 22 10.0.2.15 22 (per ssh)
tcp 192.168.56.1 8787 10.0.2.15 8787 (jboss remote debug)
VIRTUAL BOX NETWORK CONFIGURATION FOR works also with No Network Connection (solution2)
In virtual machine network settings choose Host Only - Networking as showed in picture below.
You will need no extra - configuration;
however if you want a (optional ) different hostname from localhost.localdomain to a different name (es. vhost.vhostdomain) you have 2 extra configuration on virtual machine:
- edit the file
/etc/sysconfig/network
NETWORKING=yes
HOSTNAME="VBOXCENTOS"
GATEWAY="192.168.0.1"
GATEWAYDEV="eth0"
FORWARD_IPV4="yes"
- set your hostname in /etc/hosts
127.0.0.1 localhost.localdomain localhost
192.168.56.101 VBOXCENTOS
Note: be sure to insert in your hosts file on windows this entry
virtualbox_ip_address VBOXCENTOS
Nessun commento:
Posta un commento