# Restarting the PFC200 application if it crashes

**URL:** <https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582>\
**Category:** Hardware and Linux\
**Tags:** pfc200, linux\
**Created:** [February 13, 2025, 3:44pm UTC](https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582 "2025-02-13T15:44:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ThomasM](https://avatars.discourse-cdn.com/v4/letter/t/50afbb/32.png) [@ThomasM](https://www.wago.community/u/ThomasM)\
**Post date:** [February 13, 2025, 3:44pm UTC](https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582/1 "2025-02-13T15:44:57Z")

</div>

Hello,

I would like to restart automatically codesys if its application crashes.

Is writing a daemon the best way to do this?

I can use for this :

- /usr/bin/getledstate - a for the status
- /etc/init.d/runtime stop
- /etc/init.d/runtime start or restart

Thanks.

---

<div class="post-metadata">

**Author:** ![edwin](https://avatars.discourse-cdn.com/v4/letter/e/73ab20/32.png) [@edwin](https://www.wago.community/u/edwin)\
**Post date:** [February 17, 2025, 8:06am UTC](https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582/2 "2025-02-17T08:06:21Z")

</div>

Hi Thomas,

The pfc200 has a Linux OS, which has a **watchdog**.  
Your application could setup the watchdog and kick it from the plc cycle.  
The pfc200 **controller** is reset, when the watchdog times out.

Regards,

---

<div class="post-metadata">

**Author:** ![Levenpastejs](https://avatars.discourse-cdn.com/v4/letter/l/ce7236/32.png) [@Levenpastejs](https://www.wago.community/u/Levenpastejs)\
**Post date:** [April 26, 2025, 8:02am UTC](https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582/3 "2025-04-26T08:02:34Z")

</div>

Is it possible to restart the PLC 8212 with 2.3 if an error occurs and stops the PLC?  
And how do you do that?  
How do you set up the watchdog function?

---

<div class="post-metadata">

**Author:** ![AdamReeve](https://sea2.discourse-cdn.com/flex016/user_avatar/www.wago.community/adamreeve/32/59_2.png) [@AdamReeve](https://www.wago.community/u/AdamReeve)\
**Post date:** [April 28, 2025, 12:47pm UTC](https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582/4 "2025-04-28T12:47:44Z")

</div>

I just posted a HowTo that is quite similar to this. Take a look and see if it may help you:

> [@HowTo: Monitor CODESYS runtime process and restart](https://www.wago.community/t/howto-monitor-codesys-runtime-process-and-restart/1802):
>
> This guide was made for specific application, but it may be useful as a starting point for others. It monitors both the CODESYS runtime process and a PFC RUN led and will attempt to restart the stored bootproject if possible. [How To Monitor CODESYS runtime process and restart.docx](https://www.wago.community/uploads/short-url/pZGERK7L8V420HGztTGHVIme9lb.docx) (90.1 KB)

---

<div class="post-metadata">

**Author:** ![Levenpastejs](https://avatars.discourse-cdn.com/v4/letter/l/ce7236/32.png) [@Levenpastejs](https://www.wago.community/u/Levenpastejs)\
**Post date:** [April 28, 2025, 2:39pm UTC](https://www.wago.community/t/restarting-the-pfc200-application-if-it-crashes/1582/5 "2025-04-28T14:39:05Z")

</div>

Thank you!  
I’ll look in to this!
