ebook img

Developer's Guide to Building vApps and Virtual Appliances - VMware PDF

158 Pages·2012·1.79 MB·English
by  
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Developer's Guide to Building vApps and Virtual Appliances - VMware

Developer’s Guide to Building vApps and Virtual Appliances VMware Studio 2.6 This document supports the version of each product listed and supports all subsequent versions until the document is replaced by a new edition. To check for more recent editions of this document, see http://www.vmware.com/support/pubs. EN-000831-00 Developer’s Guide to Building vApps and Virtual Appliances You can find the most up-to-date technical documentation on the VMware Web site at: http://www.vmware.com/support/ The VMware Web site also provides the latest product updates. If you have comments about this documentation, submit your feedback to: [email protected]  Copyright © 2008–2012 VMware, Inc. All rights reserved. This product is protected by U.S. and international copyright and intellectual property laws. VMware products are covered by one or more patents listed at http://www.vmware.com/go/patents. VMware is a registered trademark or trademark of VMware,Inc. in the United States and/or other jurisdictions. All other marks and names mentioned herein may be trademarks of their respective companies. VMware,Inc. 3401 Hillview Ave. Palo Alto, CA 94304 www.vmware.com 2 VMware,Inc. Contents About This Book 9 Getting Started with VMware Studio 1 Introduction to VMware Studio 13 Overview 13 What Is a vApp? 13 What Is a Virtual Appliance? 14 Audience for VMware Studio 14 Key Features 15 Architecture of VMware Studio 16 Virtual Appliance Management Infrastructure (VAMI) 17 Build System 17 VMware Studio Plugin for Eclipse 18 Integration with VMware vCenter Update Manager 18 Roadmap of This Manual 18 Linux and Eclipse Developers 18 Windows Developers 19 Developers Planning to Build vApps 19 Automating Builds from the Command Line 19 ISVs Shipping Virtual Appliances 19 2 Deploying and Using VMware Studio 21 Prerequisites 21 Deploying VMware Studio 22 Deployment Options 22 Supported Distribution Formats 23 Deployment Procedure 23 Security of Self‐Signed SSL Certificate 24 Modifying the Network and Time Zone Settings 24 Setting the Time Zone 25 Using VMware Studio Web Console 25 Accessing the VMware Studio Web Console 25 Shutting Down the VMware Studio Appliance 25 Setting Time Zone in the Web Console 25 Network Configuration in the Web Console 25 Updating the VMware Studio Appliance 26 Automatic Updates 26 Update Repository 27 3 Building VMs and vApps with VMware Studio 29 Outline of VM Build Procedure 29 Outline of vApp Build Procedure 29 Acquiring the Operating System ISO 30 Requirements for Building 64‐Bit VMs 30 Output Formats 30 VMware, Inc. 3 Developer’s Guide to Building vApps and Virtual Appliances Supported Products to Run Generated VMs and vApps 30 VMware vSphere User Privileges for Provisioning 31 ESX/ESXi and vCenter Server User Privileges 31 ESX/ESXi and VirtualCenter User Privileges 32 User Privileges for Provisioning with vCloud Director 32 Developing a Linux‐Based VM 4 Creating a Linux‐Based VM 35 Overview 35 Prerequisites – OS and Application 35 Accessing the Web Console 35 Operating System ISO Image 36 Application Director Templates 37 Appliances with Application Stack 37 Just Enough Operating System (JeOS) 37 Footprint Reduction 37 ISO of Qualifying Custom Linux OS 37 Adding Support for a New Linux OS 37 Requirements 38 Support Files for the New OS 38 Fedora 11 As an Example 39 Application Packages 39 Adding On Demand Repositories 40 Creating an On Demand Repository 40 Specifying Packages in Build Profiles 40 Creating a VM Build Profile 40 Web Console Tab Reference 42 Description Tab 42 Hardware Tab 43 OS Tab 44 Application Tab 46 Management Tab 46 Output Tab 48 Build Settings Tab 50 Building a VM from the Build Profile 52 Testing the Generated VM 52 Reiterating the Build Process 53 VMware Tools Installed in a Generated VM 53 Migrating Build Profiles from Studio 1.0 or 2.0 53 5 Packaging a Linux Application 55 VMware Studio Make Package (mkpkg) Tool 55 Options of the Make Package Tool 55 Example of Creating a DEB Package 56 Example of Creating an RPM Package 57 Operating System Native Tools 58 DEB Native Packaging 58 RPM Native Packaging 58 TAR Archive as Input Format 59 Operating System Footprint Reduction 60 Just Enough Operating System 60 4 VMware, Inc. Contents 6 Adding a Linux Management Service 61 VMware Studio VAMI Service 61 Default Management Services 62 Creating a Management Service 63 service.xml 63 view.xml 64 Creating a Vanilla VM 64 Underlying CLI 64 Importing a Management Service 64 Customizing the Initialization Script 65 7 Managing a Linux Update Repository 67 Overview of Updates 67 Generating an Update 68 Updates on CDROM 69 Updates Requiring Reboot 70 Digitally Signing an Update 70 Adding Your EULA to an Update 70 Publishing an Update 71 Publishing an Update Repository from ZIP 71 Testing Against a Staging Update Repository 72 Diagnosing Failed Updates 73 Update Repository XML 73 Supporting Central Updates with VMware vCenter Update Manager 74 8 Using the VMware Studio Plugin for Eclipse 75 Requirements of VMware Studio Plugin for Eclipse 75 Getting Started with VMware Studio Plugin for Eclipse 75 Packaging Applications to Run In a Virtual Machine 76 Creating Management Services 77 Additional Eclipse Features 77 Uninstalling the Eclipse Plugin 78 Developing a Windows‐Based VM 9 Creating a Windows‐Based VM 81 Overview 81 Prerequisites – OS and Application 81 Accessing the Web Console 81 Operating System ISO Image 82 OS Image Installation Options for Windows 82 Virtual Disk Size for Windows Server 82 Adding Support for a New Windows OS 83 Windows Application Packages 83 Creating a VM Build Profile 83 Additional Fields for Windows Reference 84 OS Tab 84 Application Tab 86 Building a VM from the Build Profile 87 Testing the Generated VM 87 Reiterating the Build Process 88 Provisioning a Windows ISO in vSphere Datastore 88 VMware, Inc. 5 Developer’s Guide to Building vApps and Virtual Appliances 10 Packaging a Windows Application 89 About VMware Studio Package for Windows 89 Repository of Windows Application Packages 89 Creating a Windows Application Package 90 Registered Exit Codes 91 Environment Variables when installing Packages 91 Developing a vApp for vSphere 11 Creating a vApp from VM Builds 95 Introduction to Building a vApp 95 Prerequisites 95 Creating a vApp Build Profile 95 Web Console Tab Reference 96 Description Tab 97 VMs Tab 97 Start Order Tab 98 Resources Tab 98 Output Tab 98 Building a vApp Build Profile 99 Inspecting the vApp Build 100 Deleting a vApp Build 100 Testing the Generated vApp 100 Importing vApp Profiles 100 12 Guidelines for Creating Virtual Appliances 101 Outline of Virtual Appliance Build Procedure 101 VMware Recommendations 101 Choosing OVF Version 101 Choosing Virtual Hardware Version 102 User Accounts 102 Include Update Agent 102 Footprint Reduction 102 Partitioning Disk for System and User Data 102 VMware Ready Virtual Appliances 102 Guidelines for Adding Kernel Extensions 102 13 Building from the Command Line 103 Using the Command Line 103 Retrieve OVF Properties 105 14 Build From an Existing VM 107 Importing an Existing VM Using the CLI 107 Prerequisites 107 How It Works 108 Discovering an Existing VM 108 Two‐Step Existing VM Discovery 108 Modifying the Import Profile 109 Building with the Import Profile 109 Existing VM Capabilities and Limitations 109 6 VMware, Inc. Contents Appendixes A Management Services Web API 113 Root Object 113 VAMI Container 113 vami.container.navigate 113 vami.container.logout 113 vami.container.newHistoryItem 114 vami.container.isLogin 114 vami.container.getUser 114 vami.container.getSessionID 114 VAMI Container Callbacks 114 vami.container.registerOnShowCallback 114 vami.container.registerOnHideCallback 115 vami.container.registerOnNavigateCallback 115 VAMI I/O 115 vami.io.httpGet 115 vami.io.httpPost 116 VAMI Log 116 vami.log.info 116 vami.log.warn 116 vami.log.error 117 Managing Builds 117 Discovery Reports 117 Old Builds 117 B IPv6 Networks and Virtual Appliances 119 Supporting IPv6 in Virtual Appliances 119 IPv6 in Virtual Appliances 119 Changing the IPv6 Configuration 119 About IPv6 Support 120 DHCPv6 Availability 120 IP Configurations 120 About SLAAC 120 Name Service 121 Subnetworks and Routing 121 Avoiding Potential DNS Conflicts 121 Automatic Name Service 121 Conclusion 121 C Security with SSH and SSL 123 Installing SSH on Windows Workstation 123 Checking Veracity of an SSL Certificate or SSH Key 124 D Editing XML Build Profiles 127 Introduction 127 Structure of VM XML Build Profiles 127 Useful Attributes Not Displayed in the VMware Studio Web Console 136 Customizing the Footer in the Web Console 137 Creating Virtual Disks, Partitions, and Virtual Devices 137 Logical Volume Management in Build Profile 139 Signing OVF Files 139 Unmounting CDROM or ISO After a Build 140 VMware, Inc. 7 Developer’s Guide to Building vApps and Virtual Appliances Resource Allocation Setting Data 140 Structure of vApp XML Build Profiles 141 E Troubleshooting 145 Resolving VMware Studio Issues 145 Resolving Eclipse Plugin Issues 149 Glossary 151 Index 155 8 VMware, Inc. About This Book VMware® Studio is an integrated development tool that takes existing software applications, packages them  into virtual machines and vApps, and builds virtual appliances ready to run on VMware platform products. This book, the Developer’s Guide to Building vApps and Virtual Appliances, provides information about creating  virtual machines and vApps using VMware Studio 2.6. Revision History This book is revised with each release of the product or when necessary. A revised version can contain minor  or major changes. Table1 summarizes the significant changes in each version of this book. Table1. Revision History Revision Description 2012‐03‐02 Revision for the VMware Studio 2.6 “Faraday” release. 2011‐04‐15 Major revision for the VMware Studio 2.5 “Edison” release. 2010‐11‐04 Internal version for the VMware Studio 2.1.1 update. 2010‐07‐13 Major revision for the VMware Studio 2.1 release. 2009‐08‐28 Final version for the VMware Studio 2.0 release. 2009‐06‐29 Retitled Developer’s Guide to Building vApps and Virtual Appliances for Studio 2.0 Beta. 2009‐02‐05 Corrections made to the first version, but no new material. 2008‐09‐05 First version of the Guide to Building and Implementing Virtual Appliances for VMware Studio 1.0. VMware provides several different SDK products, each of which targets different developer communities and  target platforms. To view documentation for the various SDK products, and the current version of this guide,  go to http://www.vmware.com/support/pubs/sdk_pubs.html. VMware Studio Forum If you have questions about VMware Studio or want to interact with other users and developers, go to the  community forum at http://communities.vmware.com/community/vmtn/vam/studio?view=discussions. For news about OVF and vApp development, go to the VMware blog at http://blogs.vmware.com/vapp/. Intended Audience This document is intended for developers, independent software vendors (ISV), system integrators (SI), value  added resellers (VAR), hardware appliance vendors (HAV), IT professionals, and datacenter administrators  who want to create quick‐starting virtual machines, vApps and virtual appliances with VMware Studio. For  information about deploying vApps and virtual appliances created by VMware Studio, see the companion  manual, User’s Guide to Deploying vApps and Virtual Appliances.  VMware, Inc. 9 Developer’s Guide to Building vApps and Virtual Appliances VMware Technical Publications Glossary VMware Technical Publications provides a glossary of terms that might be unfamiliar to you. For definitions  of terms as they are used in VMware technical documentation go to http://www.vmware.com/support/pubs. Document Feedback VMware welcomes your suggestions for improving our documentation. Send your feedback to  [email protected]. Technical Support and Education Resources The following sections describe the technical support resources available to you. To access the current versions  of other VMware books, go to http://www.vmware.com/support/pubs.  Online and Telephone Support To use online support to submit technical support requests, view your product and contract information, and  register your products, go to http://www.vmware.com/support. Support Offerings To find out how VMware support offerings can help meet your business needs, go to  http://www.vmware.com/support/services. VMware Professional Services VMware Education Services courses offer extensive hands‐on labs, case study examples, and course materials  designed to be used as on‐the‐job reference tools. Courses are available onsite, in the classroom, and live  online. For onsite pilot programsand implementation best practices, VMware Consulting Services provides  offerings tohelp you assess, plan, build, and manage your virtual environment. To access information about  education classes, certification programs, and consulting services, go to http://www.vmware.com/services. 10 VMware, Inc.

Description:
manual, User's Guide to Deploying vApps and Virtual Appliances. About This ovftool. VirtualCenter 2.5 and ESX/ESXi 3.5 supported OVF 0.9 only. You can
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.