just a comment (or two): it was not the
dd, so your title is misleading (you stated in your first post, without
date it worked).
in similar cases I would suggest to generate the filename first, put/store it into a variable and use that:
Code:
MY_FILE=$(date +"windows-%Y%m%d_%H%M.img.gz")
dd ... | gzip ... > "/this/dir/${MY_FILE}" # << use " here
This make it more readable, (you can use set -xv to check how does it really works) and yes, more stable - as you can see.
And finally if your problem is solved, please mark the thread solved. Also if you wish to say thanks to someone just click on yes.