<YYYY-MM-DD>T<TIME> warning vpxd [7F447FF7E700] [Originator@6876 sub=Default opID=StatsTruncateExpiredPartitions-7460ee5a]
[VdbStatement] Connection diagnostic data from driver is HY000:0:110:
<YYYY-MM-DD>T<TIME> error vpxd[7F44865F3700] [Originator@6876 sub=Default] [VdbStatement] Execute result code: -1
<YYYY-MM-DD>T<TIME> warning vpxd[7F44865F3700] [Originator@6876 sub=Default] [VdbStatement] SQL execution failed: INSERT INTO
VPX EVENT (EVENT_ID, CHAIN_ID, EVENT_TYPE, EXTENDED_CLASS, CREATE_TIME, USERNAME, CATEGORY, VM_ID, VM_NAME, HOST_ID, HOST_NAME,
COMPUTERESOURCE_ID, COMPUTERESOURCE TYPE, COMPUTERESOURCE NAME, DATACENTER_ID, DATACENTER NAME, DATASTORE_ID, DATASTORE NAME,
NETWORK_ID, NETWORK_NAME, NETWORK_TYPE, DVS_ID, DVS_NAME, STORAGEPOD_ID, STORAGEPOD_NAME, CHANGE_TAG_ID) VALUES (?, ?, ?, ?, ?,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, ?, ?, ?, ?)
<YYYY-MM-DD>T<TIME> warning vpxd[7F44865F3700] [Originator@6876 sub=Default] [VdbStatement] Execution elapsed time: 3 ms
<YYYY-MM-DD>T<TIME> warning vpxd[7F44865F3700] [Originator@6876 sub=Default] [VdbStatement] Statement diagnostic data from
driver is 53100:0:7:ERROR: could not extend file "pg_tblspc/16396/PG_9.3_201306121/16384/16641": No space left on device;
-- > Error while executing the query
yyyy-mm-ddThh:mm:ss info vpxd[24517] [Originator@6876 sub=vpxdVdb] WarningThreshold: 80% ErrorThreshold: 95%.
yyyy-mm-ddThh:mm:ss error vpxd[24517] [Originator@6876 sub=vpxdVdb] Insufficient free space for the Database (used: 96%; threshold: 95%)
yyyy-mm-ddThh:mm:ss info vpxd[07808] [Originator@6876 sub=vpxdvpxdSignal] Signal 15 received, exiting
yyyy-mm-ddThh:mm:ss info vpxd[07808] [Originator@6876 sub=Default] Initiating VMware VirtualCenter shutdown
yyyy-mm-ddThh:mm:ss info vpxd[07711] [Originator@6876 sub=Default] Shutting down VMware VirtualCenter
yyyy-mm-ddThh:mm:ss info vpxd[18939] [Originator@6876 sub=vpxdVdb] WarningThreshold: 80% ErrorThreshold: 95%.
yyyy-mm-ddThh:mm:ss error vpxd[18939] [Originator@6876 sub=vpxdVdb] Space used on storage partition of Database exceeds
threshold (used: 95%; threshold: 95%). Service-control request will stop vpxd
yyyy-mm-ddThh:mm:ss info vpxd[18917] [Originator@6876 sub=vpxdvpxdSignal] Signal 15 received, exiting
yyyy-mm-ddThh:mm:ss info vpxd[18917] [Originator@6876 sub=Default] Initiating VMware VirtualCenter shutdown
yyyy-mm-ddThh:mm:ss info vpxd[18442] [Originator@6876 sub=Default] Shutting down VMware VirtualCenter
To resolve this issue, you need to find which ESXi host is causing the events table to be filled. After this is done, the events tables must be truncated.
shell.set --enabled true
service-control --stop vmware-vpxd, service-control --stop vmware-content-library
/opt/vmware/vpostgres/current/bin/psql -d VCDB -U postgres
SELECT COUNT(EVENT_ID) AS NUMEVENTS, EVENT_TYPE, USERNAME FROM VPX_EVENT GROUP BY EVENT_TYPE, USERNAME ORDER BY NUMEVENTS DESC LIMIT 10;
vCenter Server Appliance 6.5/6.7/7.0
SELECT COUNT(EVENT_ID) AS NUMEVENTS, EVENT_TYPE, USERNAME FROM VPXV_EVENT_ALL GROUP BY EVENT_TYPE, USERNAME ORDER BY NUMEVENTS DESC LIMIT 10;
Sample output
vmfs.heartbeat.timedout |192.0.2.1 | 12191576
vim.event.UserLogoutSessionEvent |192.0.2.1 | 1219121
vim.event.VmAcquiredTicketEvent |192.0.2.1 | 15568
su -c "/opt/vmware/vpostgres/current/bin/vacuumdb -d VCDB -e -v -f -U postgres > /tmp/vacuumdb.log"
truncate table vpx_event cascade;
truncate table vpx_event_arg cascade;
vCenter Server Appliance 6.5/6.7/7.0:
VCDB# SELECT nspname || '.' || relname AS "relation", pg_size_pretty(pg_total_relation_size(C.oid)) AS "total_size" FROM pg_class C LEFT JOIN pg_namespace N ON (N.oid = C.relnamespace) WHERE nspname NOT IN ('pg_catalog', 'information_schema') AND C.relkind <> 'i' AND nspname !~ '^pg_toast' ORDER BY pg_total_relation_size(C.oid) DESC LIMIT 20;
This will display the top 20 largest tables within the vCenter Server database. Truncate large tables individually.
Sample output:
VCDB=# truncate table vc.vpx_event_1 cascade;
Note: The Solution on this KB is truncating only vc.vpx_event_x tables.
\q
service-control --start vmware-vpxd