Playing with VirtualBox, Oracle 12c (12.1.0.1) and OEL 6.4 – Part 2

We will complete our lab by installing the Oracle Database software, create a Pluggable database and take a look in the Oracle Enterprise Manager Database Express.

The steps to install and create an Oracle Database 12c are:

1 – Go to the database directory created when unzipped the 2 Oracle Database Files and run /runInstaller .

SnapCrab_NoName_2013-7-1_20-33-26_No-00

2 – Unselect the option [I wish to receive security updates via My Oracle Support] and click [Next]. Of course, if you want to receive updates all you need to do is to leave this option marked and enter your My Oracle Support email and password.

.SnapCrab_NoName_2013-7-1_20-34-0_No-00

3 – You will receive a warning message that you have not provided an email address. Just click on [Yes].

SnapCrab_NoName_2013-7-1_20-34-27_No-00

4 – Select [Skip software updates] and click [Next].

SnapCrab_NoName_2013-7-1_20-34-46_No-00

5 – Select [Create and Configure a Database] and click [Next].

SnapCrab_NoName_2013-7-1_20-35-8_No-00

6 – Select [Server Class] and click [Next]. *** If you do not have enough resources on your laptop, please choose Desktop Class instead of Server Class.

 SnapCrab_NoName_2013-7-1_20-35-30_No-00

7 – Select the type of Database to be installed, choose [Single instance database installation] and click [Next].

 SnapCrab_NoName_2013-7-1_20-35-49_No-00

8 – Select the Install type. For this lab I will choose [Advanced Install] and click [Next].

 SnapCrab_NoName_2013-7-1_20-36-7_No-00

9 – Select the product Language, here all you need to to is leave English as the default and click [Next].

 SnapCrab_NoName_2013-7-1_20-36-24_No-00

10 – Select the Database Edition you want to install. Select [Enterprise Edition] and click [Next[.

 SnapCrab_NoName_2013-7-1_20-36-38_No-00

11 – Specify the Installation location and click [Next].

 SnapCrab_NoName_2013-7-1_20-36-53_No-00

12 – Create the Inventory and click [Next].

 SnapCrab_NoName_2013-7-1_20-37-15_No-00

13 – Select the type of database you want to create. Select [General Purpose] and click [Next].

 SnapCrab_NoName_2013-7-1_20-37-28_No-00

14 – Specify the database identifiers, enter “orcl” as the SID and here you can decide if you want to create a Container Database or as early releases a non-Container Database (by not selecting [Create as Container database]. For this example we will select Container database and create a Pluggable Database called “pdborcl” and click [Next].

 SnapCrab_NoName_2013-7-1_20-37-48_No-00

15 – Specify the configurations options, by default the Automatic Memory Management is enabled, click [Next].

 SnapCrab_NoName_2013-7-1_20-38-3_No-00

16 – Specify the storage to be used. Select [File System] and click [Next].

 SnapCrab_NoName_2013-7-1_20-38-26_No-00

17 – Management options. If you have an EM Cloud Control running on your environment, here is where you specify the EM details to manage this database. Leave as the default and click [Next].

 SnapCrab_NoName_2013-7-1_20-38-40_No-00

18 – Enable Recovery and click [Next].

 SnapCrab_NoName_2013-7-1_20-39-14_No-00

19 – Specify Passwords. For this scenario we use the password “oracle” to all accounts. Click [Next].

 SnapCrab_NoName_2013-7-1_20-39-38_No-00

20 – A warning will appear due that we are using a easy password. Click [Yes].

 SnapCrab_NoName_2013-7-1_20-39-53_No-00

21 – Click [Next] on Privileged Operating Systems groups.

 SnapCrab_NoName_2013-7-1_20-40-7_No-00

22 – Review the Summary page and click [install].

 SnapCrab_NoName_2013-7-1_20-40-35_No-00

 SnapCrab_NoName_2013-7-1_20-41-28_No-00

23 – Execute the configuration scripts as root and click [Ok] to continue the installation.

 SnapCrab_NoName_2013-7-1_20-43-51_No-00

 SnapCrab_NoName_2013-7-1_20-44-33_No-00

 SnapCrab_NoName_2013-7-1_20-45-15_No-00

 SnapCrab_NoName_2013-7-1_20-45-52_No-00

 SnapCrab_NoName_2013-7-1_20-51-35_No-00

24 – In the Finish page click [Close].

 SnapCrab_NoName_2013-7-1_20-52-3_No-00

25 – Edit /etc/oratab as follows.

 SnapCrab_NoName_2013-7-1_20-52-59_No-00

26 – Check the listener status.

 SnapCrab_NoName_2013-7-1_20-53-29_No-00

27 – Check if the Container Database is running.

 SnapCrab_NoName_2013-7-1_20-53-46_No-00

28 – Connect to the Enterprise Manager Database Express. It will first ask you to add a Security Exception in Firefox.

SnapCrab_NoName_2013-7-1_20-57-17_No-00

 SnapCrab_NoName_2013-7-1_20-57-30_No-00

29 – The Next step will be to download the Adobe Flash Player rpm and install it.

SnapCrab_NoName_2013-7-2_12-58-39_No-00

30 – Enter your database username and password. SYS and oracle and click [Login]

 SnapCrab_NoName_2013-7-2_13-1-6_No-00

31 – This is the First Screen of the new Enterprise Manager Database Express 12c. Here you are not able to use monitoring, set alertings or even execute backup and recovery operations. But you can do a lot of other stuff such  such as per example: Manage Storage such as: Undo, Redo Log Files, and Control Files, Configure Initialization Parameters, Memory  and Database Features and finally Manage  Performance, SQL Tuning and Users. and Roles (Security).

 SnapCrab_NoName_2013-7-2_13-47-36_No-00

SnapCrab_NoName_2013-7-2_13-44-55_No-00

SnapCrab_NoName_2013-7-2_13-45-27_No-00

SnapCrab_NoName_2013-7-2_13-45-56_No-00

SnapCrab_NoName_2013-7-2_13-44-21_No-00

 SnapCrab_NoName_2013-7-2_13-46-24_No-00

 SnapCrab_NoName_2013-7-2_13-47-3_No-00

 

Hope you enjoyed this tutorial and soon many more will come.

 

Regards,

 

Francisco Munoz Alvarez

//

Tagged with: , , , , , ,
Posted in 12c, General, Linux, Others, Tutorials, Virtualization

Playing with VirtualBox, Oracle 12c (12.1.0.1) and OEL 6.4 – Part 1

Now that 12c was released it’s time to install in on OEL 6.4 64 bits OS. Let’s start playing with this.

Before we start with the creation of the VM we will need to download some software first, such as:

Now that we have all the required software, let’s use the following steps to create our virtual machine using VirtualBox.

1 – Start VirtualBox and click on the option [New].

2 – Name the Virtual Machine and select the type of OS (Oracle Linux) and click [Next].

SnapCrab_NoName_2013-6-28_12-20-49_No-00

3 – Enter the amount of RAM for the VM. For this example I’m entering 4096MB if you do not have this amount of memory to use, please try with 2048 MB. An click [Next].

SnapCrab_NoName_2013-6-28_12-21-55_No-00

4 – Now is time to create the virtual disk for the VM. Select Create a Virtual Hard Drive now and click [Create].

SnapCrab_NoName_2013-6-28_12-22-30_No-00

5 – Select a hard drive type to be created, select VMDK and click [Next].

SnapCrab_NoName_2013-6-28_12-22-51_No-00

6 – Select the Dynamically allocated option and click [Next].

SnapCrab_NoName_2013-6-28_12-23-11_No-00

7 – Now let’s select the file allocation and size for our disk.  Let’s enter 50 GB for the disk Data and click [CREATE] to create the VM.

SnapCrab_NoName_2013-6-28_12-23-43_No-00

8 – Select the VM just created, than click [Settings] , select [Storage] , [ADD CD/DVD] , add the OEL 6.4 64 bit ISO image and click [OK].

SnapCrab_NoName_2013-6-28_12-27-18_No-00

9 – Due that I have a god number of CPUs available on my laptop, I will edit the VM to have 2 vCPUs. (This is an optional step)

SnapCrab_NoName_2013-6-28_12-28-47_No-00

10 – Start  the VM and click on the option [Install or upgrade an existing system].

SnapCrab_NoName_2013-6-28_12-29-56_No-00

11 – Select [Skip] the Disk Test.

SnapCrab_NoName_2013-6-28_12-30-48_No-00

12 – The installation Welcome Screen will appear. Please click [Next].

SnapCrab_NoName_2013-6-28_12-31-31_No-00

13 – Select the installation Language. For this example we will select [English] and click [Next].

SnapCrab_NoName_2013-6-28_12-31-57_No-00

14 – Select the VM Keyboard to be use [U.S. English] and click [Next].

SnapCrab_NoName_2013-6-28_12-32-23_No-00

15 – Select [Basic Storage Devices] and click [Next].

SnapCrab_NoName_2013-6-28_12-32-53_No-00

16 – You will receive a warning message that the device bellow may contain data. Click [Yes, discard any data].

SnapCrab_NoName_2013-6-28_12-33-28_No-00

17 – Enter the Host name of the VM, For this example I will use oracle12c and click [Next].

SnapCrab_NoName_2013-6-28_12-34-11_No-00

18 – Select your time zone and click [Next].

SnapCrab_NoName_2013-6-28_12-34-45_No-00

19 – Enter the Root use password. For this example I used “oracle” and click [Next].

SnapCrab_NoName_2013-6-28_12-35-20_No-00

20 – For the type of installation select [Replace Existing Linux System(s)] and click [Next].

SnapCrab_NoName_2013-6-28_12-36-31_No-00

21 – Once again you will receive a warning message, this time saying that  the partitions will be written to disk. Please click on [Write changes to disk].

SnapCrab_NoName_2013-6-28_12-37-9_No-00

22 – In the next screen select [Basic Server], [Customize now]  and click [Next]

SnapCrab_NoName_2013-6-28_12-38-39_No-00

23 –  Now we will select the following packages group on our installation:

  • Base System > Base
  • Base System > Compatibility libraries
  • Base System > Hardware monitoring utilities
  • Base System > Large Systems Performance
  • Base System > Network file system client
  • Base System > Performance Tools
  • Base System > Perl Support
  • Servers > Server Platform
  • Servers > System administration tools
    • Select the Package oracle-rdbms-server-11gR2-preinstall due that the 12c package still not available yet and this will work just fine for this installation.
  • Desktops > Desktop
  • Desktops > Desktop Platform
  • Desktops > Fonts
  • Desktops > General Purpose Desktop
  • Desktops > Graphical Administration Tools
  • Desktops > Input Methods
  • Desktops > X Window System
  • Development > Additional Development
  • Development > Development Tools
  • Applications > Internet Browser

SnapCrab_NoName_2013-6-28_12-41-59_No-00

24 – Click [Next] and the Installation Process will start.

SnapCrab_NoName_2013-6-28_12-47-40_No-00

25 – The Congratulations screen will appear and you will need to click [Reboot].

SnapCrab_NoName_2013-6-28_13-7-49_No-00

26 – On the OEL 6 Welcome page click [Forward].

SnapCrab_NoName_2013-6-28_13-8-51_No-00

27 – Review the License Information, select [Yes, I agree to the License Agreement] and click [Forward].

SnapCrab_NoName_2013-6-28_13-9-17_No-00

28 – In the Set Up Software Updates page just click [Forward].

SnapCrab_NoName_2013-6-28_13-9-51_No-00

29 – In the Create User page just click [Forward].

SnapCrab_NoName_2013-6-28_13-10-26_No-00

30 – Enter the Date and Time for your system and click [Forward].

SnapCrab_NoName_2013-6-28_13-10-58_No-00

31 – Do not select Enable Kdump and click [Finish] to reboot the machine once again.

SnapCrab_NoName_2013-6-28_13-11-33_No-00

32 – After the reboot connect to the machine using the root user.

SnapCrab_NoName_2013-6-28_13-12-14_No-00

33 – Disable the Firewall on [Administration] –> [Firewall].

SnapCrab_NoName_2013-6-28_13-13-15_No-00

34 – Select [Devices] –> [Install Guest Additions] to install the Virtual Box Guest Additions.

SnapCrab_NoName_2013-6-28_13-14-20_No-00

35 – Transfer the Database files to the virtual machine and unzip them.

  • $ unzip linuxamd64_12c_database_1of2.zip
  • $ unzip linuxamd64_12c_database_2of2.zip

36 – Configure the Host file as per the screenshot bellow.

SnapCrab_NoName_2013-6-28_14-43-26_No-00

37 – Use YUM (public yum)  to automatically setup the Oracle prerequisites if not used when installing the OS.

SnapCrab_NoName_2013-6-28_13-38-56_No-00

*** As you can see above in the screen shot, the oracle-rdbms-server-12cR1-preinstall package still not available. For this scenario we will use the oracle-rdbms-server-11gR2-preinstall package that will do the trick for us.

38 – Now we will need to setup the user oracle password .

$ passwd oracle (for this lab we will user the password oracle)

39 – Create the directories in which the Oracle software will be installed.

mkdir -p /u01/app/oracle/product/12.1.0/db_1
chown -R oracle:oinstall /u01
chmod -R 775 /u01

40 – Login as the oracle user and add the following lines at the end of the “.bash_profile” file.

# Oracle Settings
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR

ORACLE_HOSTNAME=oracle12c; export ORACLE_HOSTNAME
ORACLE_UNQNAME=DB12G; export ORACLE_UNQNAME
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/12.1.0/db_1; export ORACLE_HOME
ORACLE_SID=DB12G; export ORACLE_SID

PATH=/usr/sbin:$PATH; export PATH
PATH=$ORACLE_HOME/bin:$PATH; export PATH

LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH

41 – On the unziped folder created, go to database/rpm and install the cvuqdisk-1.0.9-1.rpm package.

$ rpm –Uvh cvuqdisk-1.0.9-1.rpm

42 – run xhost +

$ xhost +

access control disabled, clients can connect from any host

43 – Stop the Virtual Machine and Remove the OS disk from the [Storage] section and unselect the CD/DVD-ROM from the Boot Order and Start the VM.

SnapCrab_NoName_2013-6-28_13-24-51_No-00

Next, on part 2 of this lab, we will install the Oracle Database software and take a look in the Oracle Enterprise Manager Database Express.

 

Regards,

 

Francisco Munoz Alvarez

//

Tagged with: , , , , ,
Posted in 12c, General, Oracle FAQ, OVM, Tutorials, User Groups, White Papers

Once again, How to Improve your Oracle Career

The main question about the DBA job I hear all the time is: How can I became a successful DBA?

Most of the people that I talk to who have difficulties starting out in their DBA career really have an issue trying to absorb the mountainous volumes of information that a DBA needs to know this days. The evolution of the DBA role in the past few years was amazing, from a role that was basically responsible for administrate one or two small Oracle Databases and interact very closely with some System Administrators to become a super role (most of the time absorbing System and Network administrator responsibilities) some modern DBA responsibilities could be to manage:

  • Several Oracle Databases and Data Warehouses
  • High Availability environments like RAC and Standby Databases
  • Other type of RDBMS (MySQL, SQL Server, DB2, etc)
  • Support servers (Application and DB)
  • Security and Network stability
  • Storages and Clusters
  • Mentor other DBAs
  • Backup and Recovery Strategy
  • Handle User problems (including functional side of applications)
  • Review SQL and PL/SQL codes
  • Control and execute promotions to production environments

As per example, here are some common duties for a DBA in today’s world:

  • Monitor database instances on a daily basis to ensure availability.
  • Resolve unavailability issues.
  • Collect system statistics and performance data for trending and configuration analysis.
  • Configure and tune DB instances for optimal performance under application specific guidelines.
  • Analyze and administer DB security. Control and monitor user access. Audit DB usage when necessary.
  • Monitor backup procedures and Provide recovery when needed.
  • Develop and test backup and recovery procedures.
  • Upgrade RDBMS software and apply patches when needed.
  • Upgrade or migrate database instances as necessary.
  • Support application developers with any and all dB related activities.
  • Keep up with DB trends & technologies.
  • Use new technologies when applicable.
  • Install, test, and evaluate new Oracle related products.
  • Perform storage and physical design.
  • Balance design issues to achieve optimal performance.
  • Create, configure and design new DB instances.
  • Diagnose, troubleshoot and resolve any DB related problems.
  • Work with Oracle Support if necessary to bring problems to a successful resolution.
  • Ensure that Oracle networking software is configured and running properly.
  • Work with System Administrators (UNIX & NT) to ensure Oracle related matters are handled properly, or in some cases, do yourself it.
  • Train/Mentor new DBA’s
  • Create, Manage and Monitor Standby Databases
  • Understand your user Applications and needs.
  • Configure and Manage Database and Application Servers
  • Manage and configure Clusters , DWs and AS
  • Configure and Manage different type of RDBMS (Remember, you are a Database Administrator and they are database)
  • XML, Java, PHP, HTML, Linux, Unix, Windows Scripting
  • Create any necessary scripts for effective and occasionally periodic dB maintenance activities.
  • Capacity Planning /Hardware Planning

Like you can easily see, the DBA job is not easy, and each professional need to be capable to be multitasks and manages a lot of responsibilities and stress.

In this paper, we will see several examples on how to improve your DBA career and how to become a real success DBA.

First, Learn to change yourself

If you want to become a successful professional, first you need to educate yourself to be successful! Your future success depends only in your attitude today. You control your life, nobody else!

clip_image002

Becoming a successful DBA is a combination of:

  • Your professional attitude, always think positive and always look for solutions instead to kill yourself in a cup of water.
  • Learn how to research, before do something, investigate, search in the internet, read manuals. You need to show that you know how to do a properly research and look for solutions for your problems yourself.
  • Innovate, don’t wait for others to do your job, or because the other DBAs don’t care about the business you will do the same. Learn to innovate, learn to become a leader and make everyone follow your example with results. Think Different!
  • Learn to communicate properly; the best way to learn how to communicate effectively is learning to listen first. Listen, than analyze the context expressed and only than communicate an answer in a professional and honest way to your peers. Always treat everyone the same way you would like to be treated.

Albert Einstein said one time:

“If I had one hour to save the world, I would spend fifty-five minutes defining the problem and only five minutes finding the solution”

Learning to be Proactive

Why check the problems only when they are critical, or when is too late and the database is down, or the users are screaming?

Being proactive is the best approach to keep your DB healthy and to show your company, or your clients that you really care about them.

Many DBA’s expend most of their time being fire-fighters only, fixing problems and working on user’s requests all the time. They don’t do any proactive work; this mentality only will cause an overload of work to them, thousands of dollars of overtime, several hours without access to the data to the users,  poor performance to the applications, and what is worse of all, several unhappy users thinking that you doesn’t have the knowledge needed to take care of their data.

Let’s mention a small example, you have the archive log area alert set to fire when it is 95% full, and this happens in the middle of the night, some DBA’s will take seriously the alert and solve the problem quickly, others will wait until the next day to take care of it because they are tired, or sleeping, or they are in a place without internet access at the moment the alert arrived. Will be a lot easier if they set a proactive alert to be fire when 75% or 85%, or even better, take a look in the general health status of the DB before leave their work shift, to try to detect and solve any possible problem before be a real problem and be awake in the middle of the night or during the weekend (Remember how important is your personal and family time). I’ll always recommend to DBA’s to run 2 checklists daily, one in the start of their shift and other before they leave their shift.

I know several DBA’s that complain all the time that they got so many calls when they are on call, but they don’t do anything to solve the root problem, they only expend their time to solve the symptoms.

Here in my blog you can find an Oracle checklist script that will help to make your life a little easier (This is not my complete script, but will be a good start for you). This script is a compilation of several normal checklists and you can setup them with your own requirement and thresholds and always remember to have a baseline to compare. This script will not only help you to detect future or current problems, but also will help you to detect possible tuning requirement.

You also have several tools available in the market that can help you to monitor and setup your DB alerts, and help you with the proactive monitoring like: Oracle Enterprise Manager, Insider (FourthElephant), Spotlight (Quest) or if you prefer, your own scripts. The idea is to use them always on a proactive way, never reactive.

Let’s change our mentality, let stop being a fire-fighter and start to be a real hero!

Backup And Recovery

It’s time to be “Proactive with Backup & Recovery”, always when I arrive on a new client I ask the DBA on charge the following questions:

  • Do you have your recovery strategy documented step by step?
  • Are you 100% sure that your tape backups are usable?
  • Do you know exactly how long a recovery on your production environment will take if necessary?

And almost 90% of the time the answers will be:

  • No!
  • I not sure, but I think so!
  • No idea, probably…!

You will be on shock to know how many times I’m call to support a DBA to try to recover a Database because the most current tape backup is unusable!

Backup & Recovery are a very important (crucial) part of a DBA role, as a DBA I’ll never be stressed enough to repeat over and over what in my opinion is the most important rule for a DBA:

“The most important rule with respect to data is to never put yourself into an unrecoverable situation, never!”

You know, because bad stuff happens….

clip_image004clip_image006clip_image008

…When you less expect, and due to this, I’ll always recommend a DBA to perform a proactive approach to his/her Database Backup and Recovery strategy.

The main idea is:

  • Randomly choose a backup tape and recovery it on a test machine (It can be a virtual one).
  • Take this opportunity to document all the recover process.
  • Review the entire process ant try to improve it!
  • Repeat this exercise every month and try to involve other DBAs in the process!

This easy process will allow you to:

  • Test your Tape backups and see if they are being backup correctly.
  • Check and improve your recovery knowledge and strategy.
  • Document all your recovery process that could be used for any other DBA in the company in case you are not available in the recovery situation.
  • Detect any error on your backup & recovery strategy.
  • Know your recovery time. Next time your manager asks you” Do you know how long a recovery will take? You will know the exact answer.
  • Have an opportunity to review your process and try to make it more efficient.

Like you can see, this is an easy proactive exercise that will allow you and your company to be prepared in case of a disaster and recovery situations occurs, and you know when this always happens….

clip_image010

Cheers,

Francisco Munoz Alvarez

Posted in DBA Career Tips, General, Interview Tips, Oracle FAQ

Oracle VM 3.1 Disaster Recovery (HA)

On this scenario we will talk about how to implement HA (High Availability) for OVM 3.1 between a Primary Site (Production) and a Secondary Site (DR) located at 800 km away. On this post we will only talk about the storage replication part and how to make it work when a failover is required (I will not cover the Database replication side (Using Data Guard).

clip_image002

Please note that the Oracle VM Manager should be installed on both sites with the same UUID using the “./runInstaller.sh –uuid <uuid>” command. The UUID for the Oracle VM manager could be found in the configuration file of the OVM manager.

$ cat /u01/app/oracle/ovm-manager-3/.config | grep -i uuid

 

The Preparation

1) Identify the source LUN in the production OVM Manager we want to HUR to the DR site. (360060e8005449c000000449c00004606)

clip_image004

2) Present the LUN to the DR site.

Also specify the HUR source LUN (360060e8005449c000000449c00004606) and HUR target LUN (You will get the LUN ID from the SAN Engineers when they present the LUN to the DR site).

Ask the San Engineers to activate the HUR process.

 

The Failover

In the event of a primary site failure, DR procedures will be kicked off as shown below.

clip_image006

1) Production site is down, the storage replication synchronization between the production site and the DR site would have to be stopped.

2) Since these are block devices, there will be an OCFS2 filesystem on the devices. You will not be able to present the replicated repositories to the OVM servers at the DR site because of the cluster ID tamped into the repositories. This will cause mounting of the OCFS2 filesystems at the DR site to fail.

“mount.ocfs2: Cluster name is invalid while trying to join the group”

3) Find the former cluster ID stamped on the replicated repository.

We know what the target LUN ID should be (When the SAN Engineers presented the LUN to the DR site) eg 360060e8005458e000000458e00004075

clip_image008

Find the former cluster ID stamped on the replicated repository. (360060e8005458e000000458e00004075)

clip_image010

Cluster ID = 16a67562c33aa4fe

clip_image012

clip_image014

4) Find the new OCFS2 cluster ID at DR site.

clip_image016

5) Change the clusterID of the replicated repository (360060e8005458e000000458e00004075)

$ tunefs.ocfs2 –update-cluster-stack /dev/sde (360060e8005458e000000458e00004075)

clip_image018

Run fsck.ocfs2 /dev/sde

clip_image020

Y to continue.

clip_image022

Y

clip_image024

6) Check that cluster ID is already updated.

clip_image026

7) Repositories before refresh ( service ovmm stop / start)

clip_image028

8) After repositories refresh ( service ovmm stop / start)

Log onto DR OVM Manager. (console)

clip_image030

clip_image032

9) You should now see a VM under the unassigned Virtual Machines tag.

clip_image034

10) Edit VM and replace network adapter.

clip_image036

11) Migrate VM to a host.

clip_image037

12) Start VM.

13) Configure MAC address and ip address. (VM OS)

Edit /etc/sysconfig/network-scripts/ifcfg-eth0

clip_image038

Get new MAC address from DR OVM Manager.

clip_image040

Update /etc/sysconfig/network-scripts/ifcfg-eth0 with the new MAC address.

clip_image041

14) Service network restart.

Regards,

Francisco Munoz Alvarez

Posted in Cloud, General, OVM, Virtualization

Improving VM Performance, Converting repository disk to LUN

If using OVM virtual disks, you can easily improve your VM performance by replacing the virtual disks for raw LUN’s. It gives an extra boost in the performance specially if using the PVM mode.

Note that here we are using OVM 3.1 and the guest VM is using OEL 5.7.

On this scenario we will convert the OVM DB11 virtual disks to raw LUN’s as follow:

clip_image002

1. Identify how many disk and sizes you want to copy to raw LUN’s

clip_image004

2. The disk sizes in the window above are not the actual size of the disks just an indication.

3. Identify the repository ID.

clip_image006

4. SSH to the OVM Server that hosts the VM, in this case it will be the host 1B09

clip_image008

5. Move to the folder that have the name of the repository ID you identified on the step 3.

$ cd /OVS/Repositories/0004fb00000300001176e2bcac96fae5/VirtualDisks

clip_image010

6. Note the size of the two disks.

7. Present a 1 x 45GB LUN and a 1 x 110GB LUN to your OVM Server Pool.

8. Using the OVM Console, Log onto the VM (DB11) to get the mount points

clip_image012

9. Identify the new LUNS presented (At the OVM Manager).

clip_image014

10. Rename the storages.

clip_image016

11. Get the LUN ID’s of new LUN’s

clip_image018

12. In the OVM Server (1B09) that host the VM check for the LUN’s IDs you just identified on step 11.

$ cd /dev/mapper

$ ll

clip_image020

13. Shutdown the VM DB11.

14. Get ID of OVM.

clip_image022

15. On the OVM Server (1B09) make a backup of the VM DB11 config file.

$ cd /OVS/Repositories/0004fb00000300001176e2bcac96fae5/VirtualMachines/0004fb00000600002fd4b407b58c8e5a

$ cp vm.cfg to vm.cfg.bak

clip_image024

16. Create partition on raw LUN’s

$ fdisk –l to get disk device

clip_image025

clip_image027

17. Create partition on disk

$ fdisk /dev/sdl

  • N
  • P
  • 1
  • Use all the storage
  • W

$ fdisk –l /dev/sdl

clip_image028

18. Copy the img file to new LUN.

$ dd if=/OVS/Repositories/0004fb00000300001176e2bcac96fae5/VirtualDisks/0004fb0000120000fe9000e9ccaa5d08.img of=/dev/mapper/360060e8005b14a000000b14a00004301

clip_image030

19. Follow the same process for the other drives.

20. Change the virtual disk to physical disks.

clip_image032

clip_image034

21. Start the VM.

22. Delete vm.cfg.bak and img virtual disks.

clip_image036

clip_image038

23. Refresh Repository.

clip_image040

Kind regards,

Francisco Munoz Alvarez

Posted in General, OVM, Tutorials, Virtualization

OVM V2V – Converting ESX VM to OVM using ISO boot CD

In this blog post we will learn how to convert an ESX VM to OVM  3.1 (V2V) using an ISO boot CD. Basically all you need to do to achieve this objective is to follow the following steps:

1. Uninstall VMtools from VM

2. Attache OVS-3.1.1-524.iso to the VM.

3. Boot VM from CD

clip_image002

4. Enter p2v

clip_image004.

5. Press ENTER.

clip_image006

6. Select Skip.

clip_image008

7. Enter the ip address of the VM or obtain address from DHCP.

clip_image010

8. Select the disk(s) to include in the image. You will select all the disks.

clip_image012

9. Use space bar to select the disk(s) and select OK

clip_image014

10. Enter the VM name, Memory and CPUs . Console Password “Password123”

Note that you will have to edit the vm.cfg file after the import and delete the line containing vncpasswd = ‘Password123’.

If you do not remove the line you will be asked to provide a VNC Authenticate password.

clip_image016

11. Select OK

clip_image018

12. On the Transition VM Connect to web server using IE or Firefox.

https://172.29.62.5

clip_image020

clip_image021

clip_image022

13. Save System-sda.img and vm.cfg into a folder (VM Name) on the transition VM.

If you have more than one disk you will see more than one System-sda.img.

14. Control-C to restart the VM.

15. Copy the files to their management server and create a TAR ball of the System-sda.img and vm.cfg files.

16. Import the TAR file to the OVM Manager as a template.

17. Clone the template as a VM.

And your are ready to go 😉

Regards,

 

Francisco

Posted in Cloud, General, OVM, Tutorials, Virtualization

What was new for Oracle Backup and Recovery at 11g?

Oracle 12c is around the corner and due that I have received many questions from fellow DBAs about what was new about Backup and Recovery at 11g I have decided to write a small white paper about it.

Hope you will enjoy reading it as much I enjoyed writing it.

What_is_new_at_11g

Cheers,

Francisco Munoz Alvarez

Posted in 11gR2, Backup & Recovery, General, Oracle FAQ, Tutorials, White Papers