When trying to install the AWS Application Migration service agent I get the following error:
Error: Failed Installing the AWS Replication Agent
Installation failed.
Unexpected error while making agent driver! Are kernel linux headers installed correctly?
Learn more about installation issues in our documentation at https://docs.aws.amazon.com/mgn/latest/ug/Troubleshooting-Agent-Issues.html#Error-Installation-Failed
Here is the result of the log file: (I already tried all the step in the URL to rectify the issue)
Any assistance is greatly appreciated!
--- Building software
running: ['chmod', '0770', './configure']
retcode: 0
running: ['/bin/sh', 'configure', '--with-srcdir=/lib/modules/3.10.0-1127.19.1.el7.x86_64/build']
retcode: 0
running: 'which zypper'
retcode: 256
running: ['make'] with environment set to {'SRCDIR': '/lib/modules/3.10.0-1127.19.1.el7.x86_64/build', 'PWD': '/tmp/tmpgdy945nw/AgentDriver'}
retcode: 2
--- Make failed. Trying again with CONFIG_CC_STACKPROTECTOR_STRONG disabled
StdOut from driver make: make -C /lib/modules/3.10.0-1127.19.1.el7.x86_64/build M=/tmp/tmpgdy945nw/AgentDriver modules
StdErr from driver make: make: *** /lib/modules/3.10.0-1127.19.1.el7.x86_64/build: No such file or directory. Stop.
make: *** [AgentDriver] Error 2
running: ['make', 'CONFIG_CC_STACKPROTECTOR_REGULAR=1'] with environment set to {'SRCDIR': '/lib/modules/3.10.0-1127.19.1.el7.x86_64/build', 'PWD': '/tmp/tmpgdy945nw/AgentDriver'}
retcode: 2
Unexpected error while making agent driver! Are kernel linux headers installed correctly?
StdOut from driver make second run: make -C /lib/modules/3.10.0-1127.19.1.el7.x86_64/build M=/tmp/tmpgdy945nw/AgentDriver modules
StdErr from driver make second run: make: *** /lib/modules/3.10.0-1127.19.1.el7.x86_64/build: No such file or directory. Stop.
make: *** [AgentDriver] Error 2
Installation returned with code 1
Installation failed due to unspecified error:
Traceback (most recent call last):
File "shared/installer_linux/install_agent.py", line 1202, in main
SystemExit: 1
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "cirrus/installer_shared/installer_main.py", line 1092, in _main
File "cirrus/installer_shared/installer_main.py", line 961, in main
File "cirrus/installer_shared/installer_main.py", line 787, in install
File "cirrus/installer_shared/installer_main.py", line 370, in run_agent_installer
shared.installer_utils.cloud_utils.Error: Failed Installing the AWS Replication Agent [agent_version: 5.0.0.2023.187.1349, installation_id: *******, mac_addresses: *****, _origin_client_type: installer]
aws_replication_agent_installer.log (END)
2
Answers
I had a similar issue and it was down to secure boot. Disabling this allowed me to install the agent and start replicating. This doc shows the full compatibility reference for MGN source servers 🙂 https://docs.aws.amazon.com/mgn/latest/ug/Supported-Operating-Systems.html
The error that you see:
Is likely because the agent cannot install the kernel-devel packages. To fix this and according to the official documentation, you need to manually download the kernel-devel package for your OS. Once you re-download the package, you can run the installation again.
The bottom of this article here demonstrates this a bit further.
Under the Error: Unexpected error while making agent driver! Are kernel linux headers installed correctly? header.
Hope this helps! 🙂