Bad file descriptor error

I am trying to get Paraview to run on an HPC Linux server.
Calling either pvpython or pvbatch from any of the two most recent pre-compiled versions
ParaView-5.7.0-osmesa-MPI-Linux-Python3.7-64bit and
ParaView-5.7.0-MPI-Linux-Python3.7-64bit,
I get the following error message.

[cli_0]: write_line error; fd=14 buf=:cmd=init pmi_version=1 pmi_subversion=1
:
system msg for write_line failure : Bad file descriptor
[cli_0]: Unable to write to PMI_fd
[cli_0]: write_line error; fd=14 buf=:cmd=get_appnum
:
system msg for write_line failure : Bad file descriptor
Fatal error in PMPI_Init: Other MPI error, error stack:
MPIR_Init_thread(565): 
MPID_Init(175).......: channel initialization failed
MPID_Init(463).......: PMI_Get_appnum returned -1
[cli_0]: write_line error; fd=14 buf=:cmd=abort exitcode=1094415
:
system msg for write_line failure : Bad file descriptor

ParaView (and other executables as pvbatch) should be started with the MPI they were built with.
In the distributed binaries you can find a compatible mpirun executable.
It is mainly OK for desktop use BUT in your case, you probably have a specific mpi for your HPC server, so will need to build your own ParaView.