Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

custom-script-extension: cannot execute binary file: Exec format error #207

Open
abamoshes opened this issue Jan 25, 2023 · 1 comment
Open

Comments

@abamoshes
Copy link

dnsadmin@mxsfreebsd13:~ $ cat /etc/os-release
NAME=FreeBSD
VERSION="13.1-RELEASE-p5"
VERSION_ID="13.1"
ID=freebsd
ANSI_COLOR="0;31"
PRETTY_NAME="FreeBSD 13.1-RELEASE-p5"
CPE_NAME="cpe:/o:freebsd:freebsd:13.1"
HOME_URL="https://FreeBSD.org/"
BUG_REPORT_URL="https://bugs.FreeBSD.org/"
dnsadmin@mxsfreebsd13:~ $
waagent.log

mxsuser@moshes01-PC:~$ az vm extension set
--resour> --resource-group mxsfreebsd13_group
--vm-na> --vm-name mxsfreebsd13 --name customScript \

--publisher Microsoft.Azure.Extensions
-setting> --settings '{"CommandToExecute" : "echo hello>>hello"}'
(VMExtensionHandlerNonTransientError) The handler for VM extension type 'Microsoft.Azure.Extensions.customScript' has reported terminal failure for VM extension 'customScript' with error message: '[ExtensionOperationError] Non-zero exit code: 126, /var/lib/waagent/Microsoft.Azure.Extensions.customScript-2.1.7/bin/custom-script-shim install
[stdout]
/var/lib/waagent/Microsoft.Azure.Extensions.customScript-2.1.7/bin/custom-script-shim: line 60: lsof: command not found

  • /var/lib/waagent/Microsoft.Azure.Extensions.customScript-2.1.7/bin/custom-script-extension install
    /var/lib/waagent/Microsoft.Azure.Extensions.customScript-2.1.7/bin/custom-script-shim: line 124: /var/lib/waagent/Microsoft.Azure.Extensions.customScript-2.1.7/bin/custom-script-extension: cannot execute binary file: Exec format error

[stderr]
'.

'Install handler failed for the extension. More information on troubleshooting is available at https://aka.ms/vmextensionlinuxtroubleshoot'

@abamoshes
Copy link
Author

abamoshes commented Jan 25, 2023

Ran this on ubuntu 22 and everything is working great. Assuming my issue was trying to use an unsupported system.
Any feedback if Freebsd is supported would be great.
https://learn.microsoft.com/en-us/azure/virtual-machines/extensions/custom-script-linux#operating-system

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant