-
Notifications
You must be signed in to change notification settings - Fork 9
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
Feature request: add support for firmware uploads #138
Comments
Hi @LRSFC-DanJ, Yes... $body = @{
"url" = "http://192.168.244.48/YA_16_11_0016.swi"
"file_type" = "FTT_FIRMWARE"
"action" = "FTA_DOWNLOAD"
"boot_image" = "BI_PRIMARY_IMAGE"
}
Invoke-ArubaSWWebRequest -method POST -body $body -uri "file-transfer" and for Check status (Invoke-ArubaSWWebRequest -method GET -uri "file-transfer/status").content For example : $body = @{
"url" = "http://192.168.244.48/YA_16_11_0016.swi"
"file_type" = "FTT_FIRMWARE"
"action" = "FTA_DOWNLOAD"
"boot_image" = "BI_PRIMARY_IMAGE"
}
Invoke-ArubaSWWebRequest -method POST -body $body -uri "file-transfer"
StatusCode : 202
StatusDescription : Accepted
Content : {"message":"File transfer initiated"}
RawContent : HTTP/1.1 202 Accepted
Server: eHTTP
Server: v2.0
Connection: close
Transfer-Encoding: chunked
RequestId:
Content-Type: application/json
{"message":"File transfer initiated"}
Headers : {[Server, System.String[]], [Connection, System.String[]], [Transfer-Encoding, System.String[]], [RequestId, System.String[]]…}
Images : {}
InputFields : {}
Links : {}
RawContentLength : 37
RelationLink : {}
(Invoke-ArubaSWWebRequest -method GET -uri "file-transfer/status").content
{"uri":"/file-transfer/status","status":"FTS_IN_PROGRESS","result":"File transfer still in progress"}
#retry after some seconds/minutes...
(Invoke-ArubaSWWebRequest -method GET -uri "file-transfer/status").content
{"uri":"/file-transfer/status","status":"FTS_COMPLETED"} I accept with pleasure patch for adding cmdlet for this :) |
Thank you, this is actually really helpful as I didn't know there was an API function to check the file transfer status (finding documentation about this API seems really difficult for some reason). |
Do you happen to know what software version is required for the |
What your switch model and firmware ? You can look this for doc about API : |
PowerArubaSW currently doesn't provide a command that can do firmware uploads to HP/Aruba AOS-S switches.
The process for doing this using the REST API is described on the HPE website here:
https://support.hpe.com/hpesc/public/docDisplay?docId=sf000095706en_us&docLocale=en_US
It would be great if this could be added as this would be a step towards being able to script/schedule switch updates in bulk.
The text was updated successfully, but these errors were encountered: