Macjutsu / super

S.U.P.E.R.M.A.N. optimizes the macOS software update experience.
Apache License 2.0
598 stars 81 forks source link

V4.0RC1 - JP 11.0 - macOS 14.0 to 14.1RC - MDM Push failing #159

Closed master-vodawagner closed 10 months ago

master-vodawagner commented 10 months ago

I've had this issue since I updated my local copy of Super V4.0b3 to V4.0b7 and the RC1 version.

Super starts the 5 minute delay for the MDM but I see no trace of any action on the device in JP in terms of MDM commands

super.log extract

Tue Oct 24 09:49:28 X2030488 super[6046]: Verbose Mode: Starting debug log for MDM client command progress at: /Library/Management/super/logs/mdm-command-debug.log Tue Oct 24 09:49:28 X2030488 super[6046]: Verbose Mode: Starting debug log for MDM update/upgrade workflow progress at: /Library/Management/super/logs/mdm-workflow-debug.log Tue Oct 24 09:49:28 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: jamf_api_update_workflow is: NEW Tue Oct 24 09:49:28 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: jamf_api_update_url is: https://.jamfcloud.com/api/v1/managed-software-updates/plans Tue Oct 24 09:49:28 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: jamf_api_update_json is: { "devices": [ { "objectType": "COMPUTER", "deviceId": "88" } ], "config": { "updateAction": "DOWNLOAD_INSTALL_RESTART", "versionType": "SPECIFIC_VERSION", "specificVersion": "14.1" } } Tue Oct 24 09:49:29 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: curl_response is: 201 Tue Oct 24 09:49:29 X2030488 super[6046]: MDM: Successful macOS update/upgrade command request. Tue Oct 24 09:49:29 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: install_macos_mdm_api_error is: FALSE Tue Oct 24 09:54:30 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: install_macos_mdm_start_error is: TRUE Tue Oct 24 09:54:30 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: install_macos_mdm_start_error is: TRUE Tue Oct 24 09:54:30 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: install_macos_mdm_start_timeout is: Tue Oct 24 09:54:30 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: install_macos_mdm_timeout_error is: Tue Oct 24 09:54:30 X2030488 super[6046]: Verbose Mode: Function install_macos_mdm: install_macos_mdm_phase is: Tue Oct 24 09:54:31 X2030488 super[6046]: Error: Push workflow for macOS update/upgrade via MDM failed. Tue Oct 24 09:54:31 X2030488 super[6046]: Error: Installation of update/upgrade via MDM failed, failing over to user authenticated workflow.

MDM Command extract

Tue Oct 24 09:49:16 X2030488 super[6046]: S.U.P.E.R.M.A.N. 4.0.0-rc1 - UPDATE MACOS 14.1 VIA MDM START Filtering the log data using "subsystem == "com.apple.ManagedClient" AND category == "HTTPUtil"" Timestamp Ty Process[PID:TID] 2023-10-24 09:49:28.984 Df mdmclient[4636:18eda] [com.apple.ManagedClient:HTTPUtil] [0:MDMDaemon:HTTPUtil:<0x18eda>] >>>>> Sending HTTP request (PUT) [MDM_RemoteManagement] >>>>> 2023-10-24 09:49:29.788 Df mdmclient[4636:18eda] [com.apple.ManagedClient:HTTPUtil] [0:MDMDaemon:HTTPUtil:<0x18eda>] <<<<< Received HTTP response (200) [MDM_RemoteManagement] <<<<< 2023-10-24 09:49:30.230 Df mdmclient[4636:18e5b] [com.apple.ManagedClient:HTTPUtil] [0:MDMDaemon:HTTPUtil:<0x18e5b>] >>>>> Sending HTTP request (PUT) [Idle] >>>>> 2023-10-24 09:49:30.879 Df mdmclient[4636:18e5b] [com.apple.ManagedClient:HTTPUtil] [0:MDMDaemon:HTTPUtil:<0x18e5b>] <<<<< Received HTTP response (200) [Idle] <<<<< Tue Oct 24 09:54:31 X2030488 super[6046]: S.U.P.E.R.M.A.N. 4.0.0-rc1 - UPDATE/UPGRADE MACOS VIA MDM FAILED Tue Oct 24 09:54:31 X2030488 super[6046]: Error: Push workflow for macOS update/upgrade via MDM failed.

master-vodawagner commented 10 months ago

Good news is the failover option is now working for me on RC1 :P

Macjutsu commented 10 months ago

So super is doing it's thing as you can see by the Jamf APIs acceptance of the request and the return of "201".

However, I'm not sure the new API can allow for beta installations.

This is why I can't fully test until the "real thing" is out.

master-vodawagner commented 10 months ago

So it was working with 4.0b3 in terms of Apple beta products and JP11.0.x but working on the cloud vendors like Jamf/Apple change things which causes these problems. :D

I'll chase this through the Jamf beta forums to see if they can see anything

Macjutsu commented 10 months ago

So... I'm pretty sure this problem is due to the Apple endpoint that MDMs vendors use to check version numbers. It only offers up shipping (non-beta) versions: https://gdmf.apple.com/v2/pmv

The previous Jamf Pro API did allow for beta updates... it literally allowed you to specify "don't do an Apple version check".

However, you are using the new API which has no such provision. In your previous tests did you have the new Software Update Beta enabled? I believe the change in Jamf Pro 11 is that it's enabled by default, but you can still switch it back to the legacy mode.

master-vodawagner commented 10 months ago

Correct, legacy version works flawlessly with Super V4

Macjutsu commented 10 months ago

Yeah.. I think it's just the combo of beta+new API...

I've had no problems attempting non-beta updates with the new API.

master-vodawagner commented 10 months ago

Well I've raised it on Jamf' s beta forum, also spoke to an Apple resource, if the build number is provided to the SW declaration it will update providing the machine is on the beta catalog.

Macjutsu commented 10 months ago

hrm... The Jamf API reference only claims to accept full version numbers....

https://developer.jamf.com/jamf-pro/reference/post_v1-managed-software-updates-plans

curl --request POST \
     --url https://yourserver.jamfcloud.com/api/v1/managed-software-updates/plans \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
{
  "devices": [
    {
      "objectType": "COMPUTER",
      "deviceId": "42"
    }
  ],
  "config": {
    "updateAction": "DOWNLOAD_INSTALL",
    "versionType": "SPECIFIC_VERSION",
    "specificVersion": "12.6.1"
  }
}
'
Macjutsu commented 10 months ago

https://github.com/Macjutsu/super/releases/tag/v4.0.0