Use space in datadir for temporary files instead of assuming /tmp has free space.