msupdatehelper
msupdatehelper copied to clipboard
Script fails to update after recent update to MAU and/or Office 365 apps
When run as a script executed from Self Service msu-date runs through too quickly (movement in dock indicating activity) to actually be doing anything and nothing gets updated. But running msupdate manually from the command line shows updates available, and actually updates them.
Nothing has changed in my setup except new versions of O365 where it worked previously. Issue has also been reported on #microsoft_autoupdate on MacAdmins Slack group.
It looks like the script (lines 223-259) needs to be updated to include new Application IDs for Office 2019.
mswd2019
xcel2019
ppt32019
opim2019
onmc2019
I updated the ids and still having the same issue. If add an override for one of the apps with the build number and don't use the default "latest" it will find the updates.
@dash4385 for clarification, if you use the build numbers as listed at https://macadmins.software/msupdate then the update works. But, if you don't specify the build number, then no updates are found? What about from the command-line directly (rather than the script)?
As of last night when I entered in 16.29.1 as the override for word and ran the script the msupdate tool itself would run and show me the list of updates. When I came back to this in the morning this seems to no longer be the case. when the script is run with blank or with override (tried 16.29.1 and 16.29.19091700) I see flashes of an app opening on the dock but nothing happens. Logs will say there are no updates. when i run msupdate --list
i constantly get a list of updates. Will try and troubleshoot more if i have time.
This morning I tried using the v1.5 listed as a pending pull request but netted the same results.
Here is the debug out but from Jamf
Script result: Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_WORD: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_EXCEL: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_POWERPOINT: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_OUTLOOK: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_SKYPEBUSINESS: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_ONENOTE: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>OVERRIDE_REMOTEDESKTOP: <br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_WORD: true<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_WORD: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_EXCEL: true<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_EXCEL: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_POWERPOINT: true<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_POWERPOINT: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_OUTLOOK: true<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_OUTLOOK: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_SKYPEBUSINESS: true<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_SKYPEBUSINESS: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_ONENOTE: true<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_ONENOTE: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved UPDATE_REMOTEDESKTOP: false<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved VERSION_REMOTEDESKTOP: latest<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Company Portal is not installed<br/>User USERNAME is logged in<br/>Wed Sep 25 10:44:28 EDT 2019<br/>Resolved CMD_PREFIX: sudo -u USERNAME <br/>Wed Sep 25 10:44:28 EDT 2019<br/>Going for Word update<br/>Wed Sep 25 10:44:28 EDT 2019<br/>RegisterApp: Params - /Applications/Microsoft Word.app MSWD2019<br/>Wed Sep 25 10:44:29 EDT 2019<br/>Final TARGET_VERSION: <br/>Wed Sep 25 10:44:29 EDT 2019<br/>PerformUpdate: sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps MSWD2019 --wait 600 2>/dev/null<br/>Detecting and downloading updates...<br/>No result returned from Update Assistant<br/>Wed Sep 25 10:44:30 EDT 2019<br/>Going for Excel update<br/>Wed Sep 25 10:44:30 EDT 2019<br/>RegisterApp: Params - /Applications/Microsoft Excel.app XCEL2019<br/>Wed Sep 25 10:44:30 EDT 2019<br/>Final TARGET_VERSION: <br/>Wed Sep 25 10:44:30 EDT 2019<br/>PerformUpdate: sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps XCEL2019 --wait 600 2>/dev/null<br/>Detecting and downloading updates...<br/>No result returned from Update Assistant<br/>Wed Sep 25 10:44:30 EDT 2019<br/>Going for PowerPoint update<br/>Wed Sep 25 10:44:30 EDT 2019<br/>RegisterApp: Params - /Applications/Microsoft PowerPoint.app PPT32019<br/>Wed Sep 25 10:44:30 EDT 2019<br/>Final TARGET_VERSION: <br/>Wed Sep 25 10:44:30 EDT 2019<br/>PerformUpdate: sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps PPT32019 --wait 600 2>/dev/null<br/>Detecting and downloading updates...<br/>No result returned from Update Assistant<br/>Wed Sep 25 10:44:30 EDT 2019<br/>Going for Outlook update<br/>Wed Sep 25 10:44:30 EDT 2019<br/>RegisterApp: Params - /Applications/Microsoft Outlook.app OPIM2019<br/>Wed Sep 25 10:44:30 EDT 2019<br/>Final TARGET_VERSION: <br/>Wed Sep 25 10:44:30 EDT 2019<br/>PerformUpdate: sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps OPIM2019 --wait 600 2>/dev/null<br/>Detecting and downloading updates...<br/>No result returned from Update Assistant<br/>Wed Sep 25 10:44:31 EDT 2019<br/>Going for OneNote update<br/>Wed Sep 25 10:44:31 EDT 2019<br/>RegisterApp: Params - /Applications/Microsoft OneNote.app ONMC2019<br/>Wed Sep 25 10:44:31 EDT 2019<br/>Final TARGET_VERSION: <br/>Wed Sep 25 10:44:31 EDT 2019<br/>PerformUpdate: sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps ONMC2019 --wait 600 2>/dev/null<br/>Detecting and downloading updates...<br/>No result returned from Update Assistant<br/>Wed Sep 25 10:44:31 EDT 2019<br/>Going for SfB update<br/>Wed Sep 25 10:44:31 EDT 2019<br/>RegisterApp: Params - /Applications/Skype for Business.app MSFB16<br/>Wed Sep 25 10:44:31 EDT 2019<br/>Final TARGET_VERSION: <br/>Wed Sep 25 10:44:31 EDT 2019<br/>PerformUpdate: sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps MSFB16 --wait 600 2>/dev/null<br/>Detecting and downloading updates...<br/>No result returned from Update Assistant<br/>Wed Sep 25 10:44:31 EDT 2019<br/>Update for Remote Desktop disabled<br/>Wed Sep 25 10:44:31 EDT 2019<br/>Update for Company Portal disabled<br/
Here are the updates that msupdate --list
finds
Checking for updates... Updates available: ONMC2019 OneNote Update 16.29.0 (19090802) OPIM2019 Outlook Update 16.29.0 (19090802) MSFB16 Skype For Business Update 16.28.116 MSWD2019 Word Update 16.29.1 (19091700) XCEL2019 Excel Update 16.29.1 (19091700) PPT32019 PowerPoint Update 16.29.1 (19091700)
Same exact issue, this script is not finding any updates when manually running the msupdate -l shows multiple updates pending and I can run them succesfully with msupdate -i manually.
We are seeing the same behavior too. As well as the issue I describe in https://github.com/pbowden-msft/msupdatehelper/issues/11
running a stand alone one liner in terminal does work. For example I just ran
sudo -u USERNAME /Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate --install --apps MSFB16 --wait 600 2>/dev/null
and it found and updated without issue. Still can't figure out what it causing it not find update when run from the script itself.
@dash4385 does the 'one-liner' also run properly when implemented as a Jamf script? Also, one other thought - do you have the correct PPPC profile in place that allows the Jamf Agent to send events to MAU? It's at https://github.com/pbowden-msft/MobileConfigs/tree/master/Jamf-MSUpdate
I do have that config profile in place already. I have not tested the one liner above.
Can confirm the one-liner works via Jamf policy just fine. Going to start using that as a work around until this is sorted.
@hkabik Odd Tried running the one liner and returned no results when trigger through jamf.
Scratch that... the one-liner SOMETIMES works in Jamf. yesterday it worked fine, today it reported back "Detecting and downloading updates... No result returned from Update Assistant" on a Machine that did need updates. I was able to run them by SSHing and running the one-liner manually.
@hkabik Seems more like a bug with Jamf or MAU then the script if even a single line command run consistently. Guess We will have to wait for an update to MAU and test it again.
I am seeing the same issue trying to run MSUpdate from Jamf - both with the simple one line script or with pbowden's script, returns no updates found every time. If I run the command or script locally it pulls and installs the updates just fine. I also have the PPPC profile in place. Hopefully this can be addressed somehow.
Installed the MAU 4.16 (19101301) Hopping issues would resolve this but getting that same results. Running msupdate --list shows there are updates available but they are not found by the script
Update on a method I used to get it to work for anyone having the same issue, had to add a variable to pull the current user and then ran the command as su currentuser. Script I used below worked great!
#!/bin/bash
#variable for storing the current users name
currentuser=`stat -f "%Su" /dev/console`
#substituting as user stored in variable to modify plist
su "$currentuser" -c "/Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate -i"
sleep 600
Update on a method I used to get it to work for anyone having the same issue, had to add a variable to pull the current user and then ran the command as su currentuser. Script I used below worked great!
#!/bin/bash #variable for storing the current users name currentuser=`stat -f "%Su" /dev/console` #substituting as user stored in variable to modify plist su "$currentuser" -c "/Library/Application\ Support/Microsoft/MAU2.0/Microsoft\ AutoUpdate.app/Contents/MacOS/msupdate -i" sleep 600
@SurgEm Do the users need to have admin rights for this to work?
@SurgEm Do the users need to have admin rights for this to work?
I should have mentioned that yes in our environment mac users have admin rights. and just to expand on my reply - it worked on MOST of them but a handful still returned no updates found for whatever reason. I ended up doing these ones manually. Frustrating :\
@SurgEm Do the users need to have admin rights for this to work?
I should have mentioned that yes in our environment mac users have admin rights. and just to expand on my reply - it worked on MOST of them but a handful still returned no updates found for whatever reason. I ended up doing these ones manually. Frustrating :\
We limit most of our user to not have admin so this was great to allow them to update through self-service was great. May just have to scrap this script an go back to using the GUI seem to be the only reliable tool.
Looks like the command line updater does not work at all. Running version 4.17 (19111002) and the command line finds "No result returned from Update Assistant" but if I run the GUI it finds 6 updates available. At this point, I don't think it is an issue with the script but rather a poorly implemented command-line tool from Microsoft. At this point, I am giving up on it and will revert back to using the GUI
Looks like the command line updater does not work at all. Running version 4.17 (19111002) and the command line finds "No result returned from Update Assistant" but if I run the GUI it finds 6 updates available. At this point, I don't think it is an issue with the script but rather a poorly implemented command-line tool from Microsoft. At this point, I am giving up on it and will revert back to using the GUI
I am still having partial success with it - I think there is some sort of timing issue? as it seems to work "eventually" if you run it enough times. The way I have it set up now is working well enough for me - running the currentuser based script I posted above set to run once per day in the jamf policy on Smart group of any machine with office out of date. The main caveat as I said before is our mac users have admin privileges.