vCenter Server Services Not Starting / Stopping

Recently came across an issue where a customers vCenter Server Services wouldn’t start.  I read up on a few KB article stating to Start / Restart the SSO Service, this didn’t fix the problem.  Even a couple of reboots of the vCenter Server failed.

After looking in the logs, found at  C:\ ProgramData\VMWare\VMware VirtualCenter\Logs the latest Log Entry contained this:

Image

 

Turns out that there is another application on the vCenter Server which runs IIS and the World Wide Web Publishing Service – this was taking Default Ports 80 and 443 on startup.  The vCenter Server Service was set to Automatic (Delayed Start) and therefore the ports where in use.

Stopping the World Wide Web Publishing Service allowed the vCenter Server Service to start.

If you need IIS to be running for any Web Apps, in my case Open Manage is installed on the vCenter Server.  You must change the Port Binding in IIS

Open Manage actually uses different Ports, it turns out that the Default Web Site uses Port 80

Go into IIS, select the Default Site and Select Edit Bindings

Image

Select http and select Edit.  Change the Port to something that isnt being used by vCenter (80, 443)

3

Now restart the Web Service and restart the vCenter Server service to ensure they both start and run at the same time

PT2

Just after this, the vCenter Service would just stop running.  It would start and then just fail

After looking in the logs, I can see this:

The SQL Express DB is full, this is due to the vCenter logs not being over written

Image

VMware Support gave me a few scripts to run in the SQL Database Mgmt Studio

WARNING – the vCenter Service must be stopped and you should always have a backup of the vCenter DB

Scripts to be run separately:

alter table VPX_EVENT_ARG drop constraint FK_VPX_EVENT_ARG_REF_EVENT,

FK_VPX_EVENT_ARG_REF_ENTITY

alter table VPX_ENTITY_LAST_EVENT drop constraint

FK_VPX_LAST_EVENT_EVENT

alter table VPX_EVENT_ARG drop constraint FK_VPX_EVENT_ARG_REF_EVENT,

FK_VPX_EVENT_ARG_REF_ENTITY

alter table VPX_ENTITY_LAST_EVENT drop constraint

FK_VPX_LAST_EVENT_EVENT

truncate table VPX_TASK

truncate table VPX_ENTITY_LAST_EVENT

truncate table

VPX_EVENT

truncate table VPX_EVENT_ARG

alter table VPX_EVENT_ARG add

constraint FK_VPX_EVENT_ARG_REF_EVENT foreign key

(EVENT_ID) references VPX_EVENT (EVENT_ID) on delete cascade,

constraint

FK_VPX_EVENT_ARG_REF_ENTITY foreign key (OBJ_TYPE) references VPX_OBJECT_TYPE

(ID)

alter table VPX_ENTITY_LAST_EVENT add

constraint FK_VPX_LAST_EVENT_EVENT foreign

key(LAST_EVENT_ID) references VPX_EVENT (EVENT_ID) on delete cascade

After Executing each of these, start the vCenter Server Service

Log into vCenter and go to vcenter server settings.

Ensure Statsistic Levels are set as follows:

Image

Make sure the Database Retention Policy settings are both ticked and a sensible number of days is listed:

Image

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s