VMware Cloud Community
trodemaster
Hot Shot
Hot Shot
Jump to solution

CentOS 7 Guest Customization with vCD 5.5.2 Not working

Looks like CentOS 7 is not supported and Guest Customization is not working with 5.5.2/vCenter 5.5u2/esxi 5.5u2. Has anybody found a workaround for this??<br> Currently I'm using the OS provided open-vm-tools + the deployPkg plug-in from this KB http://kb.vmware.com/kb/2075048 . I have used VMware provided tools and had the same results as well. IP address is not configured Hostname is not configured Looks like the guest customization script runs but fails because of networking being down. Searching the /var/log/messages file for "customize-guest" doesn't show any usable errors. <br>Any insight is appreciated. Thanks, Blake

1 Solution

Accepted Solutions
trodemaster
Hot Shot
Hot Shot
Jump to solution

Yeah we are using this hack now and its working well with vCD and straight vSphere. https://lonesysadmin.net/2015/01/06/centos-7-refusing-vmware-vsphere-guest-os-customizations/

View solution in original post

Reply
0 Kudos
10 Replies
IamTHEvilONE
Immortal
Immortal
Jump to solution

Correct in CentOS not being directly supported.  the shell script detects major version numbers and doesn't have a toggle for RHEL or CentOS 7 in the version you are running.  This is why you don't see anything in /var/log/messages.  If you want to look at the script it is in the install folder on any cell in vCloud Director, under guest customization.  I'm pretty sure it'll be there, but you'll have to review it on your own to know exactly what it does and if you want to make changes.

I also don't think that we test with the Open tools.  They might work, but the version code numbers show up weird when the host detects the version number of tools running inside the guest.

Reply
0 Kudos
trodemaster
Hot Shot
Hot Shot
Jump to solution

The message I'm getting from VMware support is to use open-vm-tools with the deploypkg for newer versions of linux. The linux tools installer included with esxi even requires a new flag to silently install now on newer linux flavors. Hacking up the guest customization script is something I will look into. Might even crack open the one that's included with the 5.8 service provider edition to see what that looks like. Thanks for the help!

Reply
0 Kudos
alexlee2014
Contributor
Contributor
Jump to solution

I have the same issue. I looked at ifconfig's output on CentOS 7 and it seems to output something that's slightly different than previous versions.

The output looks something like:

eno12346579: bla bla bla ....

....

ether 00:22:33:44:55:66 ...

1. the interface name doesn't start with eth

2. there’s now a different format (e.g. a colin after the interface name)

It seems the scripts today might have used something like `ifconfig | awk '/^eth/ { print $1}’` attempting to extract all the interface names. But then this approach on the current ifconfig output will lead to extracting the “ether” line value from the output. This might be why in /etc/sysconfig/network-scripts the ifcfg file is generated as “ifcfg-ether”.

Fixing this before VMWare comes out with a patch could potentially be actually a trivial task if I could actually locate the right script(s) in vCloud.

Reply
0 Kudos
trodemaster
Hot Shot
Hot Shot
Jump to solution

I was looking at the scripts yesterday and it's a big blob of perl. These scripts identify the OS version then select the correct perl script to run. Some comments exist on how to add new OS's in the main perl script /opt/vmware/vcloud-director/guestcustomization/default/linux/Customize.pl Looks like you could build a new spec for centos7 and then customize the code as needed.

Reply
0 Kudos
RedHatFan
Contributor
Contributor
Jump to solution

I had the same problem. I found solution here:

http://serverfault.com/questions/653052/from-vsphere-5-5-deploying-centos-7-from-template-ignores-cu...

All you need is to change /etc/redhat-release. Remove "CentOS" and put "Red Hat Enterprise" and it should be ok.

jbroome
Contributor
Contributor
Jump to solution

I've changed my network interface name back to the standard "eth0" convention and it's still adding GATEWAYDEV=ether in /etc/sysconfig/network.

Once I change that to eth0, i'm able to get online.  Not exactly something I want to touch on every VM deployed.

Reply
0 Kudos
maxel
Enthusiast
Enthusiast
Jump to solution

i get this error during customisation of CentOS 6.6

DEBUG: Command: '/bin/chmod u+x /tmp/.vmware/linux/deploy//script6382669019368556171.bat'

DEBUG: Result:

DEBUG: Exit Code: 0

INFO: Executing pre-customization script...

INFO: precustomization

DEBUG: Command: '/bin/sh /tmp/.vmware/linux/deploy//script6382669019368556171.bat "precustomization"'

DEBUG: Result:

DEBUG: Exit Code: 256

ERROR: Fatal error occoured during customization !! Customization halted.

ERROR: Error : Execution of precustomization failed! at /tmp/.vmware/linux/deploy/scripts/Customization.pm line 388.

DEBUG: Command: '/bin/grep '^answer[ \t]* SBINDIR' /etc/vmware-tools/locations | /usr/bin/tail -1 | /usr/bin/awk '{ print $3 }''

DEBUG: Result: /usr/sbin

DEBUG: Exit Code: 0

DEBUG: Command: '/usr/sbin/vmtoolsd --cmd "info-set guestinfo.gc.status Execution of precustomization failed! at /tmp/.vmware/linux/deploy/scripts/Customization.pm line 388.

"'

DEBUG: Result:

DEBUG: Exit Code: 0

INFO: Return code is 250.

Setting generic error status in vmx.

Transitioning from state INPROGRESS to state ERRORED.

ENTER STATE ERRORED

EXIT STATE INPROGRESS

Setting deploy error: Deployment failed. The forked off process returned error code.

Deployment failed. The forked off process returned error code.

No nics to enable.

Launching cleanup.

Command to exec : /bin/rm

sizeof ProcessInternal is 56

Returning, pending output from stdout

Returning, pending output from stderr

Process exited normally after 0 seconds, returned 0

No more output from stdout

No more output from stderr

Customization command output:

Deploy error: Deployment failed. The forked off process returned error code.

Package deploy failed in DeployPkg_DeployPackageFromFile

## Closing log

Whats going wrong?

Reply
0 Kudos
jbroome
Contributor
Contributor
Jump to solution

i get this error during customisation of CentOS 6.6

[SNIP]

Whats going wrong?

Other than piggy-backing your CentOS 6 question onto a thread about CentOS 7? 

I'm not sure.

Reply
0 Kudos
maxel
Enthusiast
Enthusiast
Jump to solution

Sorry..saw only CentOS

Continue here: CentOS 6.6 Guest Customisation with vCD 5.5.2 Error

Reply
0 Kudos
trodemaster
Hot Shot
Hot Shot
Jump to solution

Yeah we are using this hack now and its working well with vCD and straight vSphere. https://lonesysadmin.net/2015/01/06/centos-7-refusing-vmware-vsphere-guest-os-customizations/

Reply
0 Kudos