Lattice dynamics of the cluster chain compounds M2Mo6Se6