A cognitive relay system in which a cognitive secondary source seeks to communicate with a secondary destination via an amplify-and-forward (AF) relay is considered. It is assumed that neither primary user activity nor the channel conditions are initially known. Both the source and relay nodes perform channel sensing in order to detect the primary user activity through energy detection. Following the channel sensing, source and relay nodes engage in channel training. Source transmits a pilot symbol which is amplified and forwarded by the relay. Upon the reception of the noisy pilot symbol, the destination employs linear minimum mean-square error (LMMSE) estimation to estimate the overall channel between the source and destination. In this setting, the effect of imperfect channel sensing results at both the source and relay on the performance of the linear MMSE estimation is analyzed. More specifically, the dependence and interactions between channel sensing parameters (e.g., detection thresholds, the probabilities of detection and false alarm) and the LMMSE estimator are studied.