Error "Cannot fork" Is Reported When CANN Is Installed in a Container

Symptom

When the CANN package is installed in a container of the Ubuntu system, the error message "Cannot fork" is displayed.

Solution

  1. Run the following command to check whether the file to which the soft link points is dash:
    1
    ls -l /bin/sh
    
  2. If dash is displayed in the command output, run the following command to change the /bin/sh link to /bin/bash and run the installation command again:
    1
    ln -sf bash /bin/sh
    

    Command output: