Logging in a batch file is quite easy (unless I am misunderstanding your question):
Echo anything that you want logged, and add to the end of the line “>> yourfile.file” (without quotes).
This will write a new line in the text file every time the batch is run. Use “> yourfile.file” to rewrite the file each time it runs.
This can be inserted in nearly every process that runs from batch. You can also customize with your own text like “echo “Maintenance now starting” %t > myfile.txt
Hope this helps!