...
Code Block |
---|
language | bash |
---|
theme | DJango |
---|
title | webpa |
---|
collapse | true |
---|
|
root@RaspberryPi-Gateway:~# ps aux | grep webpa
5827 root 0:01 /usr/bin/parodus --hw-model=RPI --hw-serial-number=00000000a31b564c --hw-manufacturer=Raspberry --hw-last-reboot-reason= --fw-name=rdkb-generic-broadband-image_rdk-next_20210813103706 --boot-time=1629896069 --hw-mac=B8:27:EB:1B:56:4C --webpa-ping-time=180 --webpa-interface-used=erouter0 --webpa-url=http://54.148.37.189:8080 --webpa-backoff-max=9 --parodus-local-url=tcp://127.0.0.1:6666 --partner-id=comcast --ssl-cert-path=/etc/ssl/certs/ca-certificates.crt --force-ipv4
5884 root 0:02 /usr/bin/webpa &
28195 root 0:00 webpa
28608 root 0:00 grep webpa
root@RaspberryPi-Gateway:~# |
Curl Commands
WebPA Set
Code Block |
---|
language | bash |
---|
theme | DJango |
---|
title | curl - set |
---|
|
root@RaspberryPi-Gateway:~# curl -X PATCH http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config -d '{"parameters": [ {"dataType": 0, "name": "Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadURL", "value": "http://192.168.0.10"}]}' -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK'
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadURL","message":"Success"}],"statusCode":200}
root@RaspberryPi-Gateway:~#
root@RaspberryPi-Gateway:~# curl -X PATCH http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config -d '{"parameters": [ {"dataType": 0, "name": "Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareToDownload", "value": "rdkb-generic-broadband-image_rdk-next_20210818080531.rootfs.wic"}]}' -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK'
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareToDownload"{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareToDownload","message":"Success"}],"statusCode":200}
root@RaspberryPi-Gateway:~# root@RaspberryPi-Gateway:~# curl -X PATCH http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config -d '{"parameters": [ {"dataType": 3, "name": "Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadNow", "value": "true"}]}' -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK'
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadNow","message":"Success"}],"statusCode":200}
root@RaspberryPi-Gateway:~#
|
WebPA Get
Code Block |
---|
language | bash |
---|
theme | DJango |
---|
title | curl - Get |
---|
collapse | true |
---|
|
root@RaspberryPi-Gateway:~# curl -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK' -i http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config?names=Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadURL
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
X-Scytale-Build: 0.1.4-1
X-Scytale-Flavor: mint
X-Scytale-Region: east
X-Scytale-Server: 54.148.37.189
X-Scytale-Start-Time: 23 Jul 19 11:55 UTC
X-Talaria-Build: 0.1.3-1
X-Talaria-Flavor: mint
X-Talaria-Region: east
X-Talaria-Server: 54.148.37.189
X-Talaria-Start-Time: 22 Jul 19 09:34 UTC
X-Tr1d1um-Build: 0.1.2-1
X-Tr1d1um-Flavor: mint
X-Tr1d1um-Region: east
X-Tr1d1um-Server: 54.148.37.189
X-Tr1d1um-Start-Time: 22 Jul 19 07:07 UTC
X-Webpa-Transaction-Id: fC0LI-meLU0OIKStT94L_w
X-Xmidt-Span: "http://localhost:8080/api/v2/device/send","2021-08-25T14:03:21Z","252.811878ms"
Date: Wed, 25 Aug 2021 14:03:22 GMT
Content-Length: 181
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadURL","value":"http://192.168.0.10","dataType":0,"parameterCount":1,"message":"Success"}],"statusCode":200}
root@RaspberryPi-Gateway:~#
|
Code Block |
---|
language | bash |
---|
theme | DJango |
---|
title | curl - Get |
---|
collapse | true |
---|
|
root@RaspberryPi-Gateway:~# curl -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK' -i http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config?names=Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadURLFirmwareToDownload
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
X-Scytale-Build: 0.1.4-1
X-Scytale-Flavor: mint
X-Scytale-Region: east
X-Scytale-Server: 54.148.37.189
X-Scytale-Start-Time: 23 Jul 19 11:55 UTC
X-Talaria-Build: 0.1.3-1
X-Talaria-Flavor: mint
X-Talaria-Region: east
X-Talaria-Server: 54.148.37.189
X-Talaria-Start-Time: 22 Jul 19 09:34 UTC
X-Tr1d1um-Build: 0.1.2-1
X-Tr1d1um-Flavor: mint
X-Tr1d1um-Region: east
X-Tr1d1um-Server: 54.148.37.189
X-Tr1d1um-Start-Time: 22 Jul 19 07:07 UTC
X-Webpa-Transaction-Id: fC0LIjpdlC7t-meLU0OIKStT94L_wS8vMwLjENt1niA
X-Xmidt-Span: "http://localhost:8080/api/v2/device/send","2021-08-25T14:0306:21Z59Z","252254.811878ms980233ms"
Date: Wed, 25 Aug 2021 14:0306:2259 GMT
Content-Length: 181224
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadURLFirmwareToDownload","value":"http://192.168.0.10rdkb-generic-broadband-image_rdk-next_20210818080531.rootfs.wic","dataType":0,"parameterCount":1,"message":"Success"}],"statusCode":200}
root@RaspberryPi-Gateway:~# curl -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK' -i http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config?names=Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareToDownload FirmwareDownloadProtocol
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
X-Scytale-Build: 0.1.4-1
X-Scytale-Flavor: mint
X-Scytale-Region: east
X-Scytale-Server: 54.148.37.189
X-Scytale-Start-Time: 23 Jul 19 11:55 UTC
X-Talaria-Build: 0.1.3-1
X-Talaria-Flavor: mint
X-Talaria-Region: east
X-Talaria-Server: 54.148.37.189
X-Talaria-Start-Time: 22 Jul 19 09:34 UTC
X-Tr1d1um-Build: 0.1.2-1
X-Tr1d1um-Flavor: mint
X-Tr1d1um-Region: east
X-Tr1d1um-Server: 54.148.37.189
X-Tr1d1um-Start-Time: 22 Jul 19 07:07 UTC
X-Webpa-Transaction-Id: jpdlC7t-S8vMwLjENt1niAMS7xPwO8ZsClcJpUSkqxjQ
X-Xmidt-Span: "http://localhost:8080/api/v2/device/send","2021-08-25T14:0610:59Z13Z","254253.980233ms576482ms"
Date: Wed, 25 Aug 2021 14:0610:5913 GMT
Content-Length: 224171
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareToDownloadFirmwareDownloadProtocol","value":"rdkb-generic-broadband-image_rdk-next_20210818080531.rootfs.wicHTTP","dataType":0,"parameterCount":1,"message":"Success"}],"statusCode":200}
root@RaspberryPi-Gateway:~# curl -H 'Authorization:Basic d3B1c2VyOndlYnBhQDEyMzQ1Njc4OTAK' -i http://54.148.37.189:9003/api/v2/device/mac:B8:27:EB:1B:56:4C/config?names=Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadProtocolFirmwareDownloadStatus
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
X-Scytale-Build: 0.1.4-1
X-Scytale-Flavor: mint
X-Scytale-Region: east
X-Scytale-Server: 54.148.37.189
X-Scytale-Start-Time: 23 Jul 19 11:55 UTC
X-Talaria-Build: 0.1.3-1
X-Talaria-Flavor: mint
X-Talaria-Region: east
X-Talaria-Server: 54.148.37.189
X-Talaria-Start-Time: 22 Jul 19 09:34 UTC
X-Tr1d1um-Build: 0.1.2-1
X-Tr1d1um-Flavor: mint
X-Tr1d1um-Region: east
X-Tr1d1um-Server: 54.148.37.189
X-Tr1d1um-Start-Time: 22 Jul 19 07:07 UTC
X-Webpa-Transaction-Id: MS7xPwO8ZsClcJpUSkqxjQPzFVh-jdOQoM4BkeJxz32Q
X-Xmidt-Span: "http://localhost:8080/api/v2/device/send","2021-08-25T14:1032:13Z35Z","253332.576482ms992262ms"
Date: Wed, 25 Aug 2021 14:1032:1336 GMT
Content-Length: 171174
{"parameters":[{"name":"Device.DeviceInfo.X_RDKCENTRAL-COM_FirmwareDownloadProtocolFirmwareDownloadStatus","value":"HTTPCompleted","dataType":0,"parameterCount":1,"message":"Success"}],"statusCode":200}
|
RPi - Board
- Flash the RDKB image supported for Firmware upgrade feature in the Rpi and verify the 2 partitions(ex. mmcblk0p1, mmcblk0p2) present under dev folder (use command ls /dev)
- Device auto-reboots and verify there are 2 more additional partitions are created (ex. mmcblk0p3, mmcblk0p4).
- Verify the image version ( cat /version.txt) displays the flashed image version
- Verify FwUpgradeManagerLog.txt file is generated in /rdklogs/logs directory.
- Verify the http download is happening by noticing the change of file size using below command : cd /firmware/imagedwld ls -lh(use this command frequently to verify the file size change)
- Once image download completed, the Rpi board will auto reboot and come up with downloaded image
- Verify the version of booted image which shows the downloaded image version
...
Code Block |
---|
language | bash |
---|
theme | DJango |
---|
title | version txt |
---|
collapse | true |
---|
|
root@RaspberryPi-Gateway:~# cat /version.txt
imagename:rdkb-generic-broadband-image_rdk-next_20210818080531
BRANCH=rdk-next
YOCTO_VERSION=dunfell
VERSION=4.08.18.21
SPIN=0
BUILD_TIME="2021-08-18 08:05:31"
Generated on Wed Aug 18 08:05:31 UTC 2021
root@RaspberryPi-Gateway:~#
|
Limitation
Every Firmware Upgrade , it's boots with default values of all dmcli parameters & LastRebootReason value always return as "unknown" because rpi doesn't have the support of NVRAM.