You need to use either backticks (` - not an apostrophe: ') or the $() construct to evaluate the cat /path/file? commands:
Code:
LOG=$(cat /path/file1)
LOG1=$(cat /path/file2)
I prefer $() as it's more readable and you can nest them more easily.
I addition, to get the contents of a file into a variable, there's no need to use an external program (cat). You can simply use standard input:
Code:
LOG=$(< /path/file1)
The rest of the code should work ok.