[CMake] Problem writing on GPFS.

P. A. Cheeseman aai at purdue.edu
Tue Feb 10 13:11:49 EST 2015


     System: RHEL6   (2.6.32-504.8.1.el6.x86_64)
     Hardware: Various cluster nodes.

      We recently deployed GPFS storage and have discovered that
Cmake fails when writing to files in the GPFS storage.  The source
of the problem, identified by using strace(1), appears to be a NULL
pointer in the first entry of writev(2) iovec argument.  The line
below is representative of what we see in the strace output.

--------
writev(3, [{NULL, 0}, {"\n#ifdef __cplusplus\n# error \"A C"..., 15135}], 2)
= -1 EINVAL (Invalid argument)
--------

     On non-GPFS storage, the files are written w/o problem.  The
NULL pointer in the first iovec entry is silently ignored.

     The failures occur for Cmake installations made using Gcc 4.4.7,
4.7.2, 4.9.2, and all Intel compilers we've tried so far.  

     We have worked around the problem by building Cmake 3.1.1
with PGI 11.8-0 which does not use the writev() system calls in its
run-time.

     Has anyone else observed this symptom with GPFS?

     Is anyone familiar enough with the Cmake code to know why
the g++ compiler run-time uses writev() in the first place?  I have not
been able to reproduce the writev() system calls with a short C++
program so far.

     The problem reproduces for us by attempting to build Cmake
from source with the source tree on GPFS.  For instance ...

        ./bootstrap  --prefix=someinstallpoint

with CWD at the top of the source tree, using g++.

     A C code with explicit writev() calls, with a NULL pointer in
the first iovec entry, also reproduces the behavior.  When the
NULL is part of any entry other than the first, the code runs
identically for all storage.

				Thanks,
				Phil

				P. A. Cheeseman
				aai at purdue.edu
				765.496.8224





More information about the CMake mailing list