warning: %postun(WALinuxAgent-2.0.16-2.noarch) scriptlet failed, signal 15
See original GitHub issueI’m provisioning a CentOs box 7.x from the Azure images in the portal. On startup I wan to update yum packages + install Tomcat ( this is POC for customer ).
I’m using CustomScriptExtension
to download and run this script containing:
#!/bin/bash
# some stuff
# Taken from: https://github.com/Azure/azure-quickstart-templates/blob/875d139c16c9c023dce519e6dd48c707e3473346/torque-cluster/azuredeploy.sh
sed -i "s/Defaults\s\{1,\}requiretty/Defaults \!requiretty/g" /etc/sudoers
sudo -u serveradmin sh -c "mkdir /home/serveradmin/.ssh/;echo Host worker\* > /home/serveradmin/.ssh/config; echo StrictHostKeyChecking no >> /home/serveradmin/.ssh/config; echo UserKnownHostsFile=/dev/null >> /home/serveradmin/.ssh/config"
if ! [ -f /home/serveradmin/.ssh/id_rsa ]; then
sudo -u serveradmin sh -c "ssh-keygen -f /home/serveradmin/.ssh/id_rsa -t rsa -N ''"
fi
sudo yum update -y > update_log.txt
sudo yum install tomcat -y > instal_log.txt
However - this fails always and we found the following in the execution in the .errout
of the script execution:
Non-fatal POSTUN scriptlet failure in rpm package WALinuxAgent-2.0.16-2.noarch
File location: /var/lib/waagent/Microsoft.OSTCExtensions.CustomScriptForLinux-1.4.1.0/download/0/stderr
Checking the update_log.txt
file shows the context of this error:
Loaded plugins: fastestmirror, langpacks
Determining fastest mirrors
Resolving Dependencies
--> Running transaction check
---> Package ModemManager-glib.x86_64 0:1.1.0-6.git20130913.el7 will be updated
---> Package ModemManager-glib.x86_64 0:1.1.0-8.git20130913.el7 will be an update
...
...
...
Updating : 1:iwl1000-firmware-39.31.5.1-43.el7.noarch 329/639
Updating : iwl5150-firmware-8.24.2.2-43.el7.noarch 330/639
Updating : iwl135-firmware-18.168.6.1-43.el7.noarch 331/639
Updating : iwl3160-firmware-22.0.7.0-43.el7.noarch 332/639
Updating : iwl7260-firmware-22.0.7.0-43.el7.noarch 333/639
Cleanup : WALinuxAgent-2.0.16-2.noarch 334/639
warning: %postun(WALinuxAgent-2.0.16-2.noarch) scriptlet failed, signal 15
The yum updates work but stop as soon as this error occurs. Can you guys point me to a solution?
Issue Analytics
- State:
- Created 7 years ago
- Comments:16 (7 by maintainers)
Top Results From Across the Web
Error with Custom Script Extension on Linux regarding 'yum
warning : %postun(WALinuxAgent-2.2.2-1.el7.centos.noarch) scriptlet failed, signal 15. Further Context. OS Version: CentOS 7.3 ...
Read more >RPM installation/Uninstall fails with scriptlet errors
Process to install / remove rpm packages fails during script execution ... %pos (postinstall)t, %postun (postuninstall) scriptlet as follow:.
Read more >On CentOS 4.4, how can I diagnose "scriptlet failed" errors ...
While uninstalling an RPM on CentOS 4.4, I see error: %preun(mypackage-1.0) scriptlet ...
Read more >s390 rawhide report: 20150623-1 changes
(Allen S. Rout) - Fail elegantly is the rpmbuild folder does not ... at redhat.com> - 0.5.15lorg3.95-16.git522 - Scriptlets replaced with ...
Read more >Untitled
Fix setup to deal with "WALinuxAgent-WALinuxAgent" naming scheme - Added files ... Move/add ldconfig post(un)install scriptlets to appropriate subpackages.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
For what it’s worth, I just experienced the exact same error. I’m using the RHEL 7.2 image. When I run the script with the “yum - y update” command manually, everything runs just fine with no errors. But when it runs as the CustomScriptForLinux OSTCExtension from an ARM Template, it always hangs with the exact error message above. I’m trying the “–exclude” work around mentioned above right now, but I thought someone would like to know that it is still a problem.
@deathcat05 the agent has an auto-update functionality. Your snippet from /var/log/messages shows that the agent already self-discovered an update (2.2.42) being the latest available version and updated itself, so there is no need to update it from an extension.
There are two agent handlers running on any VM, extension handler and daemon. More info on that here: https://github.com/Azure/WALinuxAgent/wiki/FAQ
When issuing
yum upgrade
, it updates the daemon (provision handler). However, as I said, if your goal is just to have a running up-to-date agent (extension handler), there is no need to do it manually as there’s an auto-update functionality.