I have wrote about how to install EM Grid Control 11g in earlier post and also demonstrated how to deploy grid control agent to a linux box:
The agent deployment wizard of EM Grid Control is easy to use if you want to deploy your agents to Unix systems. It uses SSH connection to copy the files and setup the agent software. On the other hand, if your want to deploy your agent to a windows server, you need to get your hands a little bit dirty
I should say that this is not the only option to deploy agent, but I prefer to deploy the agents via EM Grid Control interface.
First we need to download the agent software which we’ll deploy to the target server. My target server is Windows Server 2008 32bit. So I’ll download the Oracle Management Agent (220.127.116.11.0) for Microsoft Windows x86 (457,295,565 bytes):
If you have a My Oracle Support (MOS) account and entered these credentials to EM Grid Control, you don’t need to manually download this zip file, you can click to “deployments page” and then click “Download Agent Software”, select the agent and click download. It will create a job to download:
If you don’t have a MOS account, then download the agent file, unzip it and move the “win32″ directory under the agent_download directory (<OMS_HOME>/sysman/agent_download/18.104.22.168.0/):
mv win32/ /u01/oracle/Middleware/oms11g/sysman/agent_download/22.214.171.124.0/
Switch to root user and add the FQDN of the target server to the /etc/hosts file.
Now we need to prepare our Microsoft Windows Server for the agent deployment. If the server is not included in a domain, we need to add a DNS suffix to it. Login to the server with an administrator account, right click on the computer, select “manage” and click “change system properties”.
Click “change”, click “more” on the opening window and enter the suffix. So our server has a FQDN (fully qualified domain name). Add the FQDN of this server and grid control server to the hosts file. Hosts file is located in “C:\Windows\System32\drivers\etc\”. Save the changes and restart the server (because we changed the name of the server).
Open “network and sharing center”, click “windows firewall”, and disable the firewall. Now we need to install the CYGWIN. CYGWIN is a collection of Linux tools for Windows.
Download and run the setup.exe from www.cygwin.com
Click “next” until the “choose download site” screen. Pick the nearest site (I prefer Germany).
Click OK and ignore the first time installation alert.
We need to add some packages to the default installation. Enter “zip” into search box, you’ll see that 4 packages are listed. Click on archive, so it will be marked as “install”.
Erase “zip” and enter “ssh”, you’ll see that Net package is listed, click on it to mark it as “install”, then click Next.
Installer will tell us that there are more dependent packages, click next, wait until the download and install completed and click finish.
So we have installed cygwin. We’ll use it to create a SSHD service. Edit the cygwin.bat file (c:\cygwin\cygwin.bat) and add the following line:
Run the cygwin.bat as “administrator” (right click and pick run as administrator), and issue “ssh-host-config”. Enter “no” when it asks about privilege separation. Enter “yes” when it asks about installing SSHD as a service.
Enter “ntsec” for CYGWIN value. Enter “no” when it asks if you want to use a different user name than cyg_server for the SSHD service. Then enter the password for this user, and complete the creation of the SSHD service. Run the SSHD service:
Let’s create a user for the agent (I prefer user oracle):
Right click on computer, click “manage”, click “configuration”, click “local users and groups”, click “users”, right click and select “new user”.
We need to synchronize the password of this user with CYGWIN. Run cygwin (as administrator) and run:
Now try to connect the server via SSH, and then create a directory:
MS-DOS style path detected: c:/oracle
Preferred POSIX equivalent is: /cygdrive/c/oracle
CYGWIN environment variable option "nodosfilewarning" turns off this warning.
Consult the user's guide for more details about POSIX paths:
Please be careful about how I typed the folder and how cygwin converts it to POSIX.
Let’s start deploying the agent. Login to Grid Control, and click to deployments page, and then click “install agent”, and click to fresh install.
Select the correct platform, enter the name of the server, OS credentials, installation base directory (c:\oracle) and Management Server Registration Password, and then click “continue”.
Enter the MOS information and then click submit.
Wait until installation completed.
EM Grid Control agent is installed.
We can reach our new server at the targets page and click on its name to get more information.