Absit omen is a Latin expression and was used in ancient times to ward off evil, rather like the present day ‘God Forbid’ or the habit of saying ‘Touch wood’ and actively doing that. It literally means ‘may the evil be absent’ or ‘may the presentiment not become real’.
To touch wood is a superstitious action to ward off any evil consequences, or avert disaster or bad luck. It is usually said and done because of some untimely boasting about good fortune; it can also be a charm to bring good luck.
The origin is unknown but may be associated with pre-Christian rituals involving the spirits of sacred trees such as the oak, ash, holly or hawthorn. In Ireland it was believed that knocking on wood would let the little people know you were thanking them if you had some good luck - or in advance for some good fortune or aversion of disaster. The American equivalent is knocking on wood. In former times, touching iron was an equivalent preventative against ill-fortune.
The recording of the phrase itself is relatively modern, the oldest citation for the British version of the phrase, touch wood, appearing to be from 1899. The American equivalent knock on wood is roughly contemporary with the first example being from 1905.
But it almost certainly is a lot older. In 1805 , children used to play the chasing game Tiggy Touch Wood where you were considered safe if you 'Touch Wood'. This game was very popular and could have been the origin of the phrase or simply children making use of something far, far older.