Quantcast
Channel: VMware Communities : Discussion List - VMware ESXi 5
Viewing all articles
Browse latest Browse all 20614

How do I set vmkernel.log to 0 byte size

$
0
0

I am using ESXi 5.0 in a development environment.  Before an automated test is run I want to set the vmkernel.log file to be empty.  Then when the test completes the only thing in the log file is what occurred during the test. 

 

I tried the usual '> vmkernel.log' and 'cat /dev/null > vmkernel.log'.  This creates a file of size 0, but when the test runs VMware writes about 170,000 garbage characters (^@^@^@^@^@^@^  etc.) into the file before it starts logging.  This defeats the purpose of having a small file to parse.

 

I have looked into using the vMA CLI commands.  For example

esxcli --config bin/vMA_CLI.cfg system syslog config logger set --id=vmkernel --size=1 --rotate=1

and

esxcli --config bin/vMA_CLI.cfg system syslog reload

 

but nothing seems to set the file to 0, or 1, byte.  Nor can I find 'logrotate' to force the file to rotate.

 

I cannot believe there is not a way to zero a log file, so I need your help in how to do that.

 

Thanks.


Viewing all articles
Browse latest Browse all 20614

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>