# Updating firmware through Shell

**URL:** <https://www.wago.community/t/updating-firmware-through-shell/593>\
**Category:** Hardware and Linux\
**Tags:** linux, cc100\
**Created:** [September 13, 2023, 11:12am UTC](https://www.wago.community/t/updating-firmware-through-shell/593 "2023-09-13T11:12:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sommerz](https://avatars.discourse-cdn.com/v4/letter/s/db5fbb/32.png) [@sommerz](https://www.wago.community/u/sommerz)\
**Post date:** [September 13, 2023, 11:12am UTC](https://www.wago.community/t/updating-firmware-through-shell/593/1 "2023-09-13T11:12:50Z")

</div>

Hi,

Is there a shell tool available to update the firmware of CC100 controllers?  
I tried looking through the functions in /etc/config-tools, but I may be a bit out of my depth here.

---

<div class="post-metadata">

**Author:** ![WagoGrim](https://sea2.discourse-cdn.com/flex016/user_avatar/www.wago.community/wagogrim/32/60_2.png) [@WagoGrim](https://www.wago.community/u/WagoGrim)\
**Post date:** [September 13, 2023, 12:14pm UTC](https://www.wago.community/t/updating-firmware-through-shell/593/2 "2023-09-13T12:14:50Z")

</div>

Hi,

my quick answer here is to look at both firmware update/restore in /etc/config-tools and the onboard rauc-tool. Unpack firmware .wup with e.g. 7zip and you get the .rauc-file. I did not test this in a while…

---

<div class="post-metadata">

**Author:** ![sommerz](https://avatars.discourse-cdn.com/v4/letter/s/db5fbb/32.png) [@sommerz](https://www.wago.community/u/sommerz)\
**Post date:** [September 13, 2023, 1:24pm UTC](https://www.wago.community/t/updating-firmware-through-shell/593/3 "2023-09-13T13:24:34Z")

</div>

Well, that solved my problems!  
I was trying to get fwupdate to run using the wup file.

For anyone stumbling over this in the future:

1. Download firmware and unpack WUP file
2. Upload .raucb file to /tmp/fwupdate
3. Navigate to /etc/config-tools and run:
4. ./fwupdate activate
5. ./fwupdate start (you should not have to specify a path when uploaded to /tmp/fwupdate)
6. The update should now start running. To check the status, run ./fwupdate status
7. Controller will restart
8. When status is “unconfirmed” run ./fwupdate finish, and the update should be complete

EDIT:  
It looks like step 4 _might_ have to be done before step 2 if the directory doesn’t exist.

EDIT 2:  
Came back to this two years later and had an issue.  
When I uploaded the .rauchb file, I also inadvertently created the fwupdate folder.  
This lead to the fwupdate activate command failing and returning an error code 7.  
To remidy this, I moved the .rauchb file out of the folder, deleted it and ran activate again.  
That worked. I assume it has to do with directory permissions or something.

Corrected flow is:

1. Download & unpack firmware
2. Run ./fwupdate activate
3. Move .rauchb to /tmp/fwupdate/
4. ./fwupdate start
5. Check status using ./fwupdate status
6. Controller will reboot at some point. When back up, check that status is “unconfirmed” and run ./fwupdate finish.
