Number of coordinates in coordinate file does not match topology file

GROMACS version:2023.2
GROMACS modification:
Fatal error:
number of coordinates in coordinate file (prot_solv.gro, 44904)
does not match topology (topol.top, 85125)

I am performing molecular dynamics for a protein and a ligand and my protein has got 2 chains .
How can I solve this error ?

Check the coordinate file: the names of the residues and of the atoms should be written with the same format in the whole file. I got the same error using a g96 configuration to start a run; that configuration was taken from a trr trajectory via trjconv, but it missed the names of the residues and of the atoms. I added these names, but it did not work. On the other hand, the g96 configuration written by mdrun at the end of the trajectory was recognised correctly by topol.top, and I could use it to start a new trajectory.