The books were taken away by the students.

Literal

Books [topic-は] students [by-に] carried-away-[passive-られた].

Standard morphological passive: 持ち去る ('carry away') + られる (passive) + た (past) → 持ち去られた. The agent of a passive is marked with に — the 'by whom' particle. 持ち去る is a masu-stem compound: 持つ ('hold') + 去る ('leave'), meaning 'take away, remove.'