Log onto the VM through the VirtualBox console which will be shown when the VM has started.
The username is root and the password is oracle
1. When logged onto the desktop, right click and click on "Open Terminal" to bring up the terminal.
2. In the terminal edit /etc/sysconfig/network
[root@localhost ~]# vi /etc/sysconfig/network
and change to:
NETWORKING=yes HOSTNAME=source
3. Edit /etc/hosts and add the following two hosts entries
# Do not remove the following line, or various programs # that require network functionality will fail. 127.0.0.1 localhost ::1 localhost 10.0.2.4 source-int source dbv01 10.0.2.5 target-int target dbv02
4. Set the network address for eth0
cd /etc/sysconfig/network-scripts
mv ifcfg-eth0 ifcfg-eth1 vi ifcfg-eth1
Change the settings to the following (do NOT change the HWADDR or UUID)
DEVICE=eth1 HWADDR=08:00:27:d8:37:29 TYPE=Ethernet ONBOOT=yes BOOTPROTO=none IPADDR=10.0.2.4 NETMASK=255.255.255.0 GATEWAY=10.0.2.1 NETWORK=10.0.2.0 UUID=c4a351d7-380f-4dd9-a7ad-a92c30cf01c0 NM_CONTROLLED=no IPV6INIT=no
5. Ensure HWADDR in ifcfg-eth1 above is set to the same value as ATTR{address} in the following file.
cat /etc/udev/rules.d/70-persistent-net.rules
# This file was automatically generated by the /lib/udev/write_net_rules # program, run by the persistent-net-generator.rules rules file. # # You can modify it, as long as you keep each rule on a single # line, and change only the value of the NAME= key. # PCI device 0x8086:0x100e (e1000) SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="08:00:27:d8:37:29", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"
5. Restart the network interface
# /etc/init.d/network restart Shutting down interface eth0: [ OK ] Shutting down loopback interface: [ OK ] Bringing up loopback interface: [ OK ] Bringing up interface eth0: [ OK ]
6. View the network interface
# ifconfig eth0 Link encap:Ethernet HWaddr 08:00:27:18:B5:AF inet addr:10.0.2.4 Bcast:10.0.2.255 Mask:255.255.255.0 inet6 addr: fe80::a00:27ff:fe18:b5af/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:241 errors:0 dropped:0 overruns:0 frame:0 TX packets:330 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:21781 (21.2 KiB) TX bytes:47325 (46.2 KiB) Interrupt:10 Base address:0xd020 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:3670 errors:0 dropped:0 overruns:0 frame:0 TX packets:3670 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:4306552 (4.1 MiB) TX bytes:4306552 (4.1 MiB)
There is only one network interfaces:
- eth1 which is a fixed IP address. This is used to connect between the source and target servers and also to the Internet. This IP is 10.0.2.4.
7. scp (secure copy) does not work because there is display output in ~oracle/.bashrc and ~oracle/.bash_profile. To fix this:
a. Edit .bashrc in the home directory of oracle
cd ~oracle
vi .bashrc
Put a # in front of the following lines:
#cat ~/Desktop/README.txt #/sbin/ifconfig | grep "inet addr"
b. Edit .bash_profile in the home directory of oracle
cd ~oracle
vi .bash_profile
Put a # in front of the following lines:
#echo IP Address is: #/sbin/ifconfig | grep "inet addr"
0 Comments