KBEC-00258 - An attempt was made to create more links on a file than the file system supports

Article ID:360033191671
1 minute readKnowledge base

Summary

A CloudBees CD (CloudBees Flow) step may fail with an error such as:

Step error [ec:AgentFailedCreateWorkspace]: unable to run the command on the agent
The agent was unable to create the workspace directory: couldn’t create directory "\\\workspace\Job name agent name (1505181)": An attempt was made to create more links on a file than the file system supports (error code 1142).

This is because the file system being used as the workspace has reached its maximum count of files/directories within a directory.

Solution

For Linux, switching the filesystem from ext2 or ext3 to ext4 will allow more files and directories within a directory.

Additional tips:

  • Split one root workspace into several workspaces to distribute files within a directory

  • Purge files and directories within the workspace regularly to reduce files in the workspace.

Applies to

  • Product versions: All

  • OS versions: All

This article is part of our Knowledge Base and is provided for guidance-based purposes only. The solutions or workarounds described here are not officially supported by CloudBees and may not be applicable in all environments. Use at your own discretion, and test changes in a safe environment before applying them to production systems.