What overall meaning or message, if any, was Tolkien trying to convey with each of his books (The Hobbit, The Silmarillion, LOTR)?
Tolkien says in the very introduction to LoTR that he has no "message", and that he hates allegory:
As for any inner meaning or 'message', it has in the intention of the author none. It is neither allegorical nor topical.
But I cordially dislike allegory in all its manifestations... I think that many confuse "applicability" with "allegory"; but the one resides in the freedom of the reader, and the other in the purposed domination of the author.
Whether or not he was trying to convey a message, he did so. In fact, Tolkien's work is full of meanings and messages, he just didn't like to admit what those meanings and messages were. We can identify at least a few of them without much difficulty.
In a letter to his publisher, Milton Waldman, Tolkien admitted to inserting meaning and messages into his work:
Myth and fairy-story must, as all art, reflect and contain in solution elements of moral and religious truth... but not explicit, not in the known form of the primary "real" world.
-Tolkien, Letter #131
In the same letter, he also says that he is having difficulty keeping the letter brief, because when discussing his work,
"...the egoist and artist [in me] at once desires to say... what (he thinks) he means and is trying to represent by it all".
Obviously, there is meaning, there are messages, and they are intentional. We will have to work out for ourselves just what they are, however.
There is the obvious message of good triumphing over evil, and the virtues of humility, courage, resolve, determination, selflessness, perseverance, loyalty, love, and so on.
On a deeper level, he glorifies simplicity and rural life, and the common people who live in little farming villages and keep to themselves. Samwise Gamgee exemplifies this ideal, and was considered to be the "chief hero" of the story by Tolkien himself.
This pastoral idealism is contrasted with the dehumanizing effects of industrialization and modernization. Progress is not a good thing in Tolkien's works. In The Hobbit, Tolkien even goes so far as to say that most of the modern weaponry that allows for the massacring of large numbers of people in a short period of time were probably invented by Orcs. And in "The Scouring of the Shire", one of the many crimes committed by Saruman/Sharkey is the expansion of the mill and the resulting pollution of the river and surrounding lands.
All of the above is summed up well in Peter Beagle's preface to the American version of The Lord of the Rings.
And Tolkien's themes are undeniably Conservative in nature - the heroes are striving to reestablish the old monarchical order, and defeat the ruthless mechanical evils that beset them.
Tolkien usually shied away from acknowledging his intended messages and meanings, but occasionally gave us a few glimpses of such things. Again, from the same letter:
I dislike Allegory – the conscious and intentional allegory – yet any attempt to explain the purport of myth or fairytale must use allegorical language. (And, of course, the more 'life' a story has the more readily will it be susceptible of allegorical interpretations: while the better a deliberate allegory is made the more nearly will it be acceptable just as a story.) Anyway all this stuff is mainly concerned with Fall, Mortality, and the Machine. With Fall inevitably, and that motive occurs in several modes. With Mortality, especially as it affects art and the creative (or as I should say, sub-creative) desire which seems to have no biological function, and to be apart from the satisfactions of plain ordinary biological life, with which, in our world, it is indeed usually at strife. This desire is at once wedded to a passionate love of the real primary world, and hence filled with the sense of mortality, and yet unsatisfied by it. It has various opportunities of 'Fall'. It may become possessive, clinging to the things made as 'its own', the sub-creator wishes to be the Lord and God of his private creation. He will rebel against the laws of the Creator – especially against mortality. Both of these (alone or together) will lead to the desire for Power, for making the will more quickly effective, – and so to the Machine (or Magic). By the last I intend all use of external plans or devices (apparatus) instead of development of the inherent inner powers or talents — or even the use of these talents with the corrupted motive of dominating: bulldozing the real world, or coercing other wills. The Machine is our more obvious modern form though more closely related to Magic than is usually recognised.
-Tolkien, Letter #131
It is worth reading the whole letter, because this is about as close as Tolkien comes to openly discussing the meanings and messages in his work. You can read it here.
Note: It appears that Tolkien uses the term "the Machine" in the sense of the Ancient Greek dramatic concept of "Deus Ex Machina", or "God from the Machine". This used to have a more literal meaning - in plays in Ancient Greece, actors portraying gods would be lifted above the stage by cranes (i.e., machines), to deliver monologues that would conclude the play or resolve plot points. In modern parlance, it refers to a plot device by which a formidable problem is resolved by sudden intervention by new characters, forces, or an unforeseen turn of events. Wikipedia describes it as follows:
The term has evolved to mean a plot device whereby a seemingly unsolvable problem is suddenly and abruptly resolved by the contrived and unexpected intervention of some new event, character, ability or object.