When were the first Hadiths recorded?

Was there ever a period of time in which they were not allowed to be recorded? If so, why?
7 answers 7