Creating Hyperv Agent Installer

Creating Hyperv Agent Installer

Skip to end of metadata

Go to start of metadata

Pre-built Hyper-V Agent Installer

If you want to use pre-built Hyper-V Agent Installer then you can download from jenkins.

For master you can download from http://jenkins.buildacloud.org/job/cloudstack-master-hyperv-agent and for other releases search for appropriate job at http://jenkins.buildacloud.org/ .

Creating Hyper-V Agent Installer

To build on windows you have to follow instructions of step 1 athttps://cwiki.apache.org/confluence/display/CLOUDSTACK/Setting+up+a+CloudStack+dev+environment+on+Windows.

In addition to packages mentioned there you have to select wget package also.

Install mono on windows. You can download mono from http://www.go-mono.com/mono-downloads/download.html.

Before building  import all certificates using below command in Cygwin

mozroots --import --ask-remove

After setting up the environment you can build the agent using Cygwin. In Cygwin you have to execute  buildagent.sh script. This script is present in (cloudstack src folder)/plugins/hypervisors/hyperv

To build on Linux you can refer to Donal‘s blog http://dlafferty.blogspot.in/2013/08/building-your-microsoft-solution-with.html.

Installing and uninstalling Service from Command line

After building you will get the output/executable in (cloudstack src folder)//plugins/hypervisors/hyperv/DotNet/ServerResource/AgentShell/bin/Debug

That output folder can be zipped and can be distributed.

In that output folder there is one executable generated AgentShell.exe.

From command line that can be used to install and uninstall service as follows

To install service

  • AgentShell.exe --install -u <username> -p <password>

              where username is of form domain\username or username for example Administrator or blr\Administrator

This user should be part of local Administrators and Hyper-V Administrators group on the host

To uninstall service

  • AgentShell.exe --uninstall

 

Note: Apart from installing service you have to manually create and add ssl certificate. For that you can follow the steps herehttps://cwiki.apache.org/confluence/display/CLOUDSTACK/Manually+Creating+and+installing+self+signed+certificate+for+CloudStack+Management+Server+communication+with+Hyper-V+agent

To build clickable installer

First you have to download the source code from github https://github.com/anshul1886/CloudStackAgentSetup.

Copy the InstallerSetup folder in (cloudstack src folder)//plugins/hypervisors/hyperv/DotNet/

After building the agent run one of the following command in (cloudstack src folder)//plugins/hypervisors/hyperv/DotNet/InstallerSetup/CloudStackAgentSetup

  • msbuild CloudStackAgentSetup.wixproj

                   or

  • MSBuild.exe CloudStackAgentSetup.wixproj

Installer will be generated in bin/debug folder of CloudAgentSetup proj (cloudstack src folder)//plugins/hypervisors/hyperv/DotNet/InstallerSetup/CloudStackAgentSetup/bin/Debug

CloudStackAgentSetup code uses the WixCommonUiExtension.dll with Eclipse Public Licensehttps://github.com/dblock/msiext/blob/master/LICENSE

Installing msi through command line

To install msi through command line quietly one can use the following command

msiexec /i CloudStackAgentSetup.msi /quiet /qn /norestart /log install.log SERVICE_USERNAME=<username> SERVICE_PASSWORD=<password>

If you don‘t want to install certificate with installer then execute as follows

msiexec /i CloudStackAgentSetup.msi /quiet /qn /norestart /log install.log SERVICE_USERNAME=<username> SERVICE_PASSWORD=<password> INSTALL_CERTIFICATE="False"

Deploy software via Group Policy’s Scheduled Tasks


Create .bat script which does the following

  • copies CloudStackAgentSetup.msi from a networked resource (shared folder) to Hyper-V host
  • installs the CloudStackAgentSetup.msi(use one of the method mentioned in above section, Installing msi through command line)
  • set the appropriate location for logs (replace install.log with your file)
  • deletes the CloudStackAgentSetup.msi from Hyper-V host after installation
  • save the .bat file as install-cloudstack-hyperv-agent.bat .

 

Create and deploy a scheduled task via group policy

  • Open Group Policy Management
  • Navigate to the Organization Unit you wish to receive CloudStack Hyper-V Agent deployment via a schedule task
  • Right-click on your target OU and select “Create a GPO in this domain, and Link it here”
  • Name: Deploy Application via Scheduled Tasks
  • Group Policy Management Editor > Computer Configuration > Preferences > Control Panel Settings > Scheduled Tasks
  • Right-click on Scheduled Tasks > New > Scheduled Tasks
  • Tab Tasks > Action > Create
  • Tab Task > Name > Install CloudStack Hyper-V Agent
  • Tab Task > Run > \\path to bat script\install-cloudstack-hyperv-agent.bat
  • Tab Task > Enabled > checked
  • Tab Schedule > Scheduled Task > Once, 2:00:00 AM
  • Tab Schedule > Scheduled Task Once > Run On > Pick a day that is best for you
  • (optional) Tab Settings > Power Management > Wake the computer to run this task > checked

Link this Group Policy to one or more OUs and under Security Filtering, add Authenticated Users and Domain Computers.

For more details refer to http://www.jasonpearce.com/2010/11/17/deploy-software-via-group-policys-scheduled-tasks/

To build clickable installer using Visual studio

Add the project to visual Studio and build it Visual Studio as normal build

(cloudstack src folder)//plugins/hypervisors/hyperv/DotNet/InstallerSetup/CloudStackAgentSetup

Troubleshooting

If any command is not working make sure that it is environment path

To get msbuild on path add the following path to Path environment variable

C:\Windows\Microsoft.NET\Framework\v4.0.30319

.

  • No labels

1 Child Page

Page: Manually Creating and installing self signed certificate for CloudStack Management Server communication with Hyper-V agent

时间: 2024-12-19 11:42:06

Creating Hyperv Agent Installer的相关文章

Symantec Backup Exec 2012 Agent For Linux安装

Backup Exec 2012 介绍 Backup Exec 2012 是一种为虚拟和物理环境提供保护的集成产品,能够简化备份和灾难恢复,并提供了无可匹敌的恢复功能.借助于强大的 Symantec V-Ray 技术,Backup Exec 2012 可以恢复整个服务器.关键 Microsoft 应用程序以及 VMware 或 Microsoft Hyper-V 虚拟环境,从而最大限度减少业务停机. 主要功能 使用获得专利的 V-Ray 技术,通过一次性备份在数秒内轻松地恢复虚拟机.应用程序.数

CLOUDSTACK FOR HYPER-V

原文地址:http://zhu.vn/archives/1040 我这里是内网测试环境,宿主机为Server 2012R2 ,虚拟化技术为HYPER-V,域环境来的(不是域环境玩不了). 先给宿主机安装上CS的Hyper-v代理先,这是最根本的根本. 下载http://jenkins.buildacloud.org/view/4.5/job/cloudstack-4.5-hyperv-agent/lastSuccessfulBuild/artifact/bin/cloudstack-4.5-20

Linux下WebSphereV8.5.5.0 安装详细过程

Linux下WebSphereV8.5.5.0 安装详细过程 自WAS8以后安装包不再区别OS,一份介质可以安装到多个平台.只针对Installation Manager 进行了操作系统的区分 ,Websphere产品介质必须通过专门的工具Install Managere安装.进入IBM的官网http://www.ibm.com/us/en/进行下载.在云盘http://yun.baidu.com/share/linkshareid=2515770728&uk=4252782771 中是Linu

weblogic 命令行安装

安装JDK 10.1.125.224  注意系统版本32 or 64 1. chmod +x jdk-6u43-linux-i586.bin        jdk 是容器,是运行环境 2.[[email protected] weblogic_software]# cd jdk1.6.0_43 3.[[email protected] jdk1.6.0_43]# useradd weblogic 4.[[email protected] /]# chown weblogic:weblogic -

weblogic安装注意事项_linux

?更多技术干货请戳:听云博客 一.安装过程:参考“weblogic安装截屏(linux)” 注意事项:安装weblogic时,需要注意以下两点: 1.首先在安装目录下创建weblogic12文件夹 如安装目录:/opt/SpyTest/PVT/Java/container/ 2.第二步Choose Middleware Home Directory:输入/opt/SpyTest/PVT/Java/container/weblogic12/ 而不是下面的/opt/SpyTest/PVT/Java/

CentOS安装VMware Tools

新建cdrom挂载目录 mkdir /mnt/cdrom 挂载光驱 mount -t auto /dev/cdrom /mnt/cdrom这命令就是把CentOS CDROM挂载在/mnt/cdrom目录中,就可以访问里面的内容了: 使用光驱中的文件,进行安装 [[email protected] /]# cd /mnt/cdrom [[email protected] /]# ls -a [[email protected] /]# cp VMwareTools-8.6.1-19175.tar

Dive into python3

Table of Contents What’s New in “Dive Into Python 3” a.k.a. “the minus level” Installing Python Diving In Which Python Is Right For You? Installing on Microsoft Windows Installing on Mac OS X Installing on Ubuntu Linux Installing on Other Platforms U

【翻译自mos文章】在windows 2012上安装rac时,GI 的安装失败,报OUI-35024

在windows 2012上安装rac时,GI 的安装失败,报OUI-35024 来源于: RAC on Windows 2012: Grid Infrastructure Installation Fails With OUI-35024 (文档 ID 1907834.1) 适用于: Oracle Database - Enterprise Edition - Version 11.2.0.3 and later Microsoft Windows x64 (64-bit) 症状: Oracl

weblogic_server103.c的安装及配置

weblogic是bea公司的产品,后来被oracle收购,weblogic是基于Javaee架构的中间件,是纯java开发的java应用服务器.WebLogic主要用于开发.集成.部署和管理大型分布式Web应用.网络应用和数据库应用的Java应用服务器. weblogic_server103.下载链接:http://pan.baidu.com/s/1c6uSgQ  密码:4lk4 weblogic下载要去oracle官网注册下载,可能还需要付费,博主免费提供下载,下面就是weblogic的安装