Let $$(R, \mathfrak {m})$$ be a local ring and M a finitely generated R-module. It is shown that if M is relative Cohen–Macaulay with respect to an ideal $$\mathfrak {a}$$ of R, then $${\text {Ann}}_R(H_{\mathfrak {a}}^{{\text {cd}}(\mathfrak {a}, M)}(M))={\text {Ann}}_RM/L={\text {Ann}}_RM$$ and $${\text {Ass}}_R (R/{\text {Ann}}_RM)\subseteq \{\mathfrak {p}\in {\text {Ass}}_R M|\,\mathrm{cd}(\mathfrak {a}, R/\mathfrak {p})={\text {cd}}(\mathfrak {a}, M)\},$$ where L is the largest submodule of M such that $$\mathrm{cd}(\mathfrak {a}, L)< \mathrm{cd}(\mathfrak {a}, M)$$ . We also show that if $$H^{\dim M}_{\mathfrak {a}}(M)=0$$ , then $${\text {Att}}_R(H^{\dim M-1}_{\mathfrak {a}}(M))= \{\mathfrak {p}\in {\text {Supp}}(M)|\mathrm{cd}(\mathfrak {a}, R/\mathfrak {p})=\dim M-1\},$$ and so the attached primes of $$H^{\dim M-1}_{\mathfrak {a}}(M)$$ depend only on $${\text {Supp}}(M)$$ . Finally, we prove that if M is an arbitrary module (not necessarily finitely generated) over a Noetherian ring R with $$\mathrm{cd}(\mathfrak {a}, M)=\mathrm{cd}(\mathfrak {a}, R/{\text {Ann}}_RM)$$ , then $${\text {Att}}_R(H^{\mathrm{cd}(\mathfrak {a}, M)}_{\mathfrak {a}}(M))\subseteq \{\mathfrak {p}\in {\text {V}}({\text {Ann}}_RM)|\,\mathrm{cd}(\mathfrak {a}, R/\mathfrak {p})=\mathrm{cd}(\mathfrak {a}, M)\}.$$ As a consequence of this, it is shown that if $$\dim M=\dim R$$ , then $${\text {Att}}_R(H^{\dim M}_{\mathfrak {a}}(M))\subseteq \{\mathfrak {p}\in {\text {Ass}}_R M|\mathrm{cd}(\mathfrak {a}, R/\mathfrak {p})=\dim M\}$$ .