MPI based parallelism

I am trying to use LAMMPS MPI for parallel computation in a single workstation having windows operating system. I have installed MPICH2 from the link https://www.mpich.org/static/downloads/1.4.1p1/mpich2-1.4.1p1-win-x86-64.msi.
But when I was trying to run lammps from command prompt using the command line
mpiexec -np 4 lmp -in “input file”
the system is showing the error “Credentials for DESKTOP-GTALCVB\USER rejected connecting to DESKTOP-GTALCVB”. Is it a problem of compilation? Kindly suggest me how to compile LAMMPS.

You have to provide more details.
How did you install/compile LAMMPS?
Which version of LAMMPS?
What Windows version do you have?

Please note, that the MPICH version you are referring to requires some special setup steps as discussed on this page in the “Running LAMMPS on Windows” section: LAMMPS Windows Installer Repository

Have you tried using: mpiexec -localonly 4 lmp -in “input file”?