I'll start with some hints and can elaborate as required
Have a look at the output from these commands to see what's useful for you:
date +%d%m%Y
echo "some text"
echo "some text" | sed 's/^some/#&/'
touch somefile.txt
cat somefile.txt
echo "a line of text" >> somefile.txt
cat somefile.txt
echo "another line of text" >> somefile.txt
cat somefile.txt
echo "a third line of text but a different > command" > somefile.txt
cat somefile.txt
If you wish to run commands against multiple hosts, create a file that lists each of your hosts (one per line). In the script example below, I've used "hostfile".
I've decided to connect to each host via ssh and run a couple of commands. In order to do so, they are passed to the ssh command INSIDE quotation marks. There are many limitations to this - you are welcome to experiment.
Start by running something simple:
for host in `cat hostfile`; do ssh $host "uname -n; touch /tmp/file.`date +%d%m%y`"; done;
Then test it by running:
for host in `cat hostfile`; do echo $host; ssh $host ls -trail /tmp; done
Expand and test where you can. The command `date +%d%m%y` is getting the date from the host where you are running the script - not from the host that you are ssh'ing in to.