VMware studio practice in TIM

2,048 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
2,048
On SlideShare
0
From Embeds
0
Number of Embeds
5
Actions
Shares
0
Downloads
10
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

VMware studio practice in TIM

  1. 1. VMware Studio Introduction Hubert Chan
  2. 2. VMware Studio Benefits• VMware Studio Benefits – Building vApps – Automated the building of Virtual Appliances – Integrate Virtual Appliance Management Infrastructure – Other Benefit https://www.vmware.com/products/studio/benefits.html
  3. 3. Before VMware Studio Solution• Creating a Base Image by hand – Manual 3rd party Libraries Management – Manual cleanup and post action – Modification is not version controlled – Recreate base image when add/remove 3rd party libraries
  4. 4. State of Art• Manual Instruction NOT so reliable• Midnight Daily Build suffers the Build Master• Frequent bug fixing cause build master busy to generate new OVA
  5. 5. Generate OVA by VMware Studio• VMware Studio integrates – VIX API – vSphere API – CentOS / RHEL • Kickstart (ks.cfg) • Yum repository
  6. 6. What you need to do• Create a VM profile – VM template (CentOS / RedHat / …) – Define VM Hardware Specification • CPU, RAM, NICs • Partition Layout – Define Installed Applications – Define Pre/Post Install Scripts – Build Related settings
  7. 7. VM Profile Template• Inherit base template
  8. 8. Hardware Specification• CPU / RAM / NICs
  9. 9. Hardware Specification• Disk and Partition
  10. 10. Support CentOS repository• Install RPMs from media (DVD ISO)
  11. 11. Install Packages• Install 3rd party / ISV packages
  12. 12. Application Pre/Post Install Scripts• Customization Scripts
  13. 13. Build Related Settings• ESXi related setting
  14. 14. Command Line• studiocli provides – Query build status – Create a new build – Delete a build
  15. 15. Ideally…• Ideally… – Create a VM profile once – Use studiocli to trigger a build – Copy built OVA through SCP
  16. 16. We think we can have• Advantages – Auto build for OVA – Add/Remove 3rd party libraries without pain – Easy to customize pre/post install scripts – VM Profile can be version controlled
  17. 17. Houston, we’ve got a problem.• Install4j package is not RPM – Use post install script to install install4j package $ wget -r -np -nH -R "index.html*" http://[VADK.localIP]/install_package/
  18. 18. Houston, we’ve got a problem.• No CentOS 6.2 Template – Rewrite from RHEL 6.1• Deployment of Install Package/RPMs is slow – Use rsync – http://coolshell.cn/articles/7425.html
  19. 19. Houston, we’ve got a problem.• Provide a way to do manual installation – Hand made python scripts to control flows • Installation • Patch 3rd party configuration • Firewall rules• studiocli does not work through SSH – Use /opt/vmware/share/build/vabs.pl
  20. 20. Houston, we’ve got a problem.• Modify VM profile XML for rpms/scripts – Use python lxml and glob• Need a CPAN mirror – Mini CPAN – Hack for CPAN init
  21. 21. Houston, we’ve got a problem.• Detect build automatically from tw-testing – autofs to mount tw-testing – Check MD5 every 5 minutes and store version in a python pickle – Trigger OVA build
  22. 22. Houston, we’ve got a problem.• Performance – Tuning (especially in memory) – Use SSD to save some time – Can use vmxnet in the future• Check VM instance whether powered off bug – No good solution now
  23. 23. Houston, we’ve got a problem.• Separate Deployment Configuration – Use WRKDIR for latest package – Only overwrite deployment settings
  24. 24. Q&A

×