Technical Tip: How to resolve FortiClient EMS upgrade failure due to the error 'getcwd() failed: No such file or directory'
| Description | This article describes how to resolve FortiClient EMS upgrade failure due to the error 'getcwd() failed: No such file or directory'. |
| Scope | FortiClient EMS v7.4. |
| Solution | When upgrading FortiClient EMS in version 7.4, the following error may be encountered:
Unpacking forticlientems (7.4.4.2034) over (7.4.3.1926) ...
getcwd() retrieves the absolute path of the current working directory from where the upgrade executable was run: getcwd(3) - Linux manual page.
In this case, the upgrade executable was run from /opt/forticlientems:
root@hostname:/opt/forticlientems# ./forticlientems_7.4.4.2034.F.amd64.bin - - --allowed_hosts '*' --enable_remote_https
This conflicts with the upgrade operation, as the archiving and restoration of the /opt/forticlientems directory will be performed during the process.
Running the upgrade executable from any directory other than /opt/forticlientems and /tmp should resolve this issue. |