# Segment Rebuilt Error Message

**URL:** <https://forum.mautic.org/t/segment-rebuilt-error-message/29733>\
**Category:** Product Support\
**Tags:** mautic-4\
**Created:** [October 23, 2023, 4:32am UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733 "2023-10-23T04:32:31Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![team](https://avatars.discourse-cdn.com/v4/letter/t/b5a626/32.png) [@team](https://forum.mautic.org/u/team)\
**Post date:** [October 23, 2023, 4:32am UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/1 "2023-10-23T04:32:31Z")

</div>

Hi Everyone,

How do I clear my Mautic cache, i.e., ‘This segment has not been rebuilt in 78 hours’:

 ![Mautic Tasks](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/b/b48e82af6c9fd96110ea4ec23debe7c61da7f73b.png)

The CLI command ‘regerate the cache by warming it up’ did not work (i.e., sudo -u mautic php bin/console cache:warmup). See the screenshot error messages:

 ![2023-10-22 21.18.53 cpanel.devced.com 64ee05f699e6](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/c/c5179bc2e218962b90c29ab2a4110250d2de3e77.png)

 ![2023-10-22 21.18.38 cpanel.devced.com 23001cb733e2](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/7/798d00ba53bf41af49fef729d66baeed5700fd52.png)

See the sf.mautic-emails-send file:

> /home/mautic/public\_html/mautic.devced.com/var/cache/run/sf.mautic-emails-send.f8887da39a17dfb1ee96a61884260c394951b7a56925ffc98f03399e9f5028fa.lock

1. 2243116

 ![2023-10-22 21.18.11 cpanel.devced.com 70ace3b215b2](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/0/09f597e8236bcb9c54ab96eb6a71255ccd7eec48.png)

 ![2023-10-22 21.17.45 cpanel.devced.com 559ec85e6b13](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/7/7025c575f6e6981cd3ec5930cc6b117cb082b713.png)

The error source:

> [22-Oct-2023 22:18:42 UTC] PHP Warning: Undefined array key “path” in /home/mautic/public\_html/mautic.devced.com/app/bundles/CoreBundle/Controller/ExceptionController.php on line 111:

> 111: ‘route’ =\> $urlParts[‘path’],  
> 112: ],  
> 113: ‘responseCode’ =\> $code,

See, reference source, [Full guide to permissions and cache in Mautic – Joey Keller](https://joeykeller.com/full-guide-to-permissions-and-cache-in-mautic/)

Regards,  
Hal  
DevCED Team

---

<div class="post-metadata">

**Author:** ![Leon\_Oltmanns](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/leon_oltmanns/32/10629_2.png) [@Leon\_Oltmanns](https://forum.mautic.org/u/Leon_Oltmanns)\
**Post date:** [October 23, 2023, 9:22am UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/2 "2023-10-23T09:22:41Z")

</div>

Hi @team,  
usually that message disappears asap when the Segment has been updated .

The Cache clears itself by default every 10 minutes - you can set a timer in the System Settings:

 ![image](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/f/f41ef3fbde2c1554a92f1d54f108cd5fb50fe3ed.png)

Would you mind checking wether the Segment gets actually updated correctly by creating a dummy-contact that matches the Segment-Filters?

Best  
Leon

---

<div class="post-metadata">

**Author:** ![team](https://avatars.discourse-cdn.com/v4/letter/t/b5a626/32.png) [@team](https://forum.mautic.org/u/team)\
**Post date:** [October 23, 2023, 11:31am UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/3 "2023-10-23T11:31:24Z")

</div>

Leon\_Oltmanns,

The default timer in the System Settings is set at 10 Minutes:

 ![2023-10-23 04.20.20 mautic.devced.com 7635088c4d40](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/f/f477e0933482beb8912b48011544f5e4e29a1426.png)

Last 15 Cron Jobs:

> [mautic@team ~]$ sudo grep mautic /var/log/cron | tail -15  
> Oct 23 10:50:01 team CROND[2264511]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:emails:send \>/dev/null 2\>&1)  
> Oct 23 10:55:01 team CROND[2264797]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:rebuild --batch-limit=1200 \>/dev/null 2\>&1)  
> Oct 23 10:55:01 team CROND[2264798]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:reports:scheduler \>/dev/null 2\>&1)  
> Oct 23 11:00:02 team CROND[2265014]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:trigger --batch-limit=1200 \>/dev/null 2\>&1)  
> Oct 23 11:00:02 team CROND[2265013]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:broadcasts:send \>/dev/null 2\>&1)  
> Oct 23 11:05:01 team CROND[2265172]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:import --limit=500 \>/dev/null 2\>&1)  
> Oct 23 11:05:01 team CROND[2265171]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:emails:send \>/dev/null 2\>&1)  
> Oct 23 11:10:02 team CROND[2265401]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:reports:scheduler \>/dev/null 2\>&1)  
> Oct 23 11:10:02 team CROND[2265402]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:rebuild --batch-limit=1200 \>/dev/null 2\>&1)  
> Oct 23 11:15:02 team CROND[2265607]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:broadcasts:send \>/dev/null 2\>&1)  
> Oct 23 11:15:02 team CROND[2265609]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:trigger --batch-limit=1200 \>/dev/null 2\>&1)  
> Oct 23 11:20:02 team CROND[2265839]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:import --limit=500 \>/dev/null 2\>&1)  
> Oct 23 11:20:02 team CROND[2265840]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:emails:send \>/dev/null 2\>&1)  
> Oct 23 11:25:01 team CROND[2266164]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:reports:scheduler \>/dev/null 2\>&1)  
> Oct 23 11:25:01 team CROND[2266166]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:rebuild --batch-limit=1200 \>/dev/null 2\>&1)  
> [mautic@team ~]$

Regards,  
Hal  
DevCED Team

---

<div class="post-metadata">

**Author:** ![Leon\_Oltmanns](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/leon_oltmanns/32/10629_2.png) [@Leon\_Oltmanns](https://forum.mautic.org/u/Leon_Oltmanns)\
**Post date:** [October 23, 2023, 12:26pm UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/4 "2023-10-23T12:26:29Z")

</div>

Hi @team,  
I dont see any segment-updates in your last 15 runs.  
How often do you let them run?

Greets  
Leon

---

<div class="post-metadata">

**Author:** ![team](https://avatars.discourse-cdn.com/v4/letter/t/b5a626/32.png) [@team](https://forum.mautic.org/u/team)\
**Post date:** [October 23, 2023, 1:02pm UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/5 "2023-10-23T13:02:51Z")

</div>

> [@team](#):
>
> Leon\_Oltmanns,

Leon\_Oltmanns,

Checkout the Mautic cron jobs:

 ![2023-10-23 06.00.27 cpanel.devced.com b539b0c7ec31](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/f/faf647ace297b5622022265ebb24053c51a514fc.png)

Regards,  
Hal  
DevCED Team

---

<div class="post-metadata">

**Author:** ![Leon\_Oltmanns](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/leon_oltmanns/32/10629_2.png) [@Leon\_Oltmanns](https://forum.mautic.org/u/Leon_Oltmanns)\
**Post date:** [October 23, 2023, 1:04pm UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/6 "2023-10-23T13:04:47Z")

</div>

Hi @team,  
Yeah, there is no mautic:segments:update there. So your segments dont get updated.  
If a segment has not been updates since X hours (This is configurable in the Config), that message appears.

You should add the missing cronjob.

Best  
Leon

---

<div class="post-metadata">

**Author:** ![team](https://avatars.discourse-cdn.com/v4/letter/t/b5a626/32.png) [@team](https://forum.mautic.org/u/team)\
**Post date:** [October 23, 2023, 4:44pm UTC](https://forum.mautic.org/t/segment-rebuilt-error-message/29733/7 "2023-10-23T16:44:19Z")

</div>

Hi Leon\_Oltmanns,

The segment error message is gone.

Mautic cron job command: mautic:segment:update:

> [mautic@team ~]$ /usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:segment:update --batch-limit=900  
> Rebuilding contacts for segment 2  
> 0 total contact(s) to be added in batches of 900  
> 0 total contact(s) to be removed in batches of 900  
> 0 contact(s) affectedRebuilding contacts for segment 9  
> 0 total contact(s) to be added in batches of 9000 total contact(s) to be removed in batches of 900  
> 0 contact(s) affectedRebuilding contacts for segment 6  
> 0 total contact(s) to be added in batches of 9000 total contact(s) to be removed in batches of 900  
> 0 contact(s) affectedRebuilding contacts for segment 10  
> 0 total contact(s) to be added in batches of 9000 total contact(s) to be removed in batches of 900  
> 0 contact(s) affectedRebuilding contacts for segment 11  
> 0 total contact(s) to be added in batches of 9000 total contact(s) to be removed in batches of 900  
> 0 contact(s) affectedRebuilding contacts for segment 13  
> 0 total contact(s) to be added in batches of 900  
> 0 total contact(s) to be removed in batches of 900  
> 0 contact(s) affected  
> Rebuilding contacts for segment 12  
> 0 total contact(s) to be added in batches of 900  
> 0 total contact(s) to be removed in batches of 900  
> 0 contact(s) affected  
> Rebuilding contacts for segment 3  
> 0 total contact(s) to be added in batches of 900  
> 0 total contact(s) to be removed in batches of 900  
> 0 contact(s) affected  
> [mautic@team ~]$

Last 60 cron job commands:

> [mautic@team ~]$ sudo grep mautic /var/log/cron | tail -60Oct 23 15:59:24 team crontab[2279480]: (mautic) LIST (mautic)  
> Oct 23 15:59:24 team crontab[2279481]: (mautic) REPLACE (mautic)Oct 23 15:59:24 team crontab[2279483]: (mautic) LIST (mautic)  
> Oct 23 15:59:28 team crontab[2279485]: (mautic) LIST (mautic)Oct 23 15:59:28 team crontab[2279486]: (mautic) REPLACE (mautic)  
> Oct 23 15:59:29 team crontab[2279488]: (mautic) LIST (mautic)Oct 23 15:59:34 team crontab[2279492]: (mautic) LIST (mautic)  
> Oct 23 15:59:34 team crontab[2279493]: (mautic) REPLACE (mautic)Oct 23 15:59:34 team crontab[2279495]: (mautic) LIST (mautic)  
> Oct 23 15:59:41 team crontab[2279505]: (mautic) LIST (mautic)Oct 23 15:59:41 team crontab[2279506]: (mautic) REPLACE (mautic)  
> Oct 23 15:59:42 team crontab[2279508]: (mautic) LIST (mautic)Oct 23 16:00:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:00:27 team crontab[2279561]: (mautic) LIST (mautic)Oct 23 16:00:27 team crontab[2279562]: (mautic) REPLACE (mautic)  
> Oct 23 16:00:27 team crontab[2279564]: (mautic) LIST (mautic)Oct 23 16:01:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:01:04 team crontab[2279607]: (mautic) LIST (mautic)Oct 23 16:01:04 team crontab[2279608]: (mautic) REPLACE (mautic)  
> Oct 23 16:01:04 team crontab[2279610]: (mautic) LIST (mautic)Oct 23 16:02:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:02:22 team crontab[2279644]: (mautic) LIST (mautic)  
> Oct 23 16:02:22 team crontab[2279645]: (mautic) REPLACE (mautic)  
> Oct 23 16:02:22 team crontab[2279647]: (mautic) LIST (mautic)  
> Oct 23 16:03:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:03:40 team crontab[2279687]: (mautic) LIST (mautic)  
> Oct 23 16:03:40 team crontab[2279688]: (mautic) REPLACE (mautic)  
> Oct 23 16:03:41 team crontab[2279691]: (mautic) LIST (mautic)  
> Oct 23 16:04:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:04:21 team crontab[2279729]: (mautic) LIST (mautic)  
> Oct 23 16:04:21 team crontab[2279730]: (mautic) REPLACE (mautic)  
> Oct 23 16:04:21 team crontab[2279732]: (mautic) LIST (mautic)  
> Oct 23 16:05:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:05:01 team CROND[2279775]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:emails:send–message-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:05:05 team crontab[2279890]: (mautic) LIST (mautic)  
> Oct 23 16:05:05 team crontab[2279891]: (mautic) REPLACE (mautic)  
> Oct 23 16:05:05 team crontab[2279895]: (mautic) LIST (mautic)  
> Oct 23 16:05:41 team crontab[2279919]: (mautic) LIST (mautic)  
> Oct 23 16:05:41 team crontab[2279920]: (mautic) REPLACE (mautic)  
> Oct 23 16:05:41 team crontab[2279922]: (mautic) LIST (mautic)  
> Oct 23 16:06:01 team crond[2036]: (mautic) RELOAD (/var/spool/cron/mautic)  
> Oct 23 16:10:01 team CROND[2280095]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:reports:scheduler \>/dev/null 2\>&1)  
> Oct 23 16:10:01 team CROND[2280096]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:rebuild --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:15:02 team CROND[2280362]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:segment:update --batch-limit=900 \>/dev/null 2\>&1)  
> Oct 23 16:15:02 team CROND[2280363]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:broadcasts:send --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:15:02 team CROND[2280364]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:trigger --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:20:01 team CROND[2280821]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:emails:send–message-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:20:01 team CROND[2280823]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:import --limit=500 \>/dev/null 2\>&1)  
> Oct 23 16:25:01 team CROND[2281073]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:rebuild --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:25:01 team CROND[2281080]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:reports:scheduler \>/dev/null 2\>&1)  
> Oct 23 16:30:01 team CROND[2281369]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:broadcasts:send --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:30:01 team CROND[2281370]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:segment:update --batch-limit=900 \>/dev/null 2\>&1)  
> Oct 23 16:30:01 team CROND[2281372]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:trigger --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:35:02 team CROND[2281717]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:emails:send–message-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:35:02 team CROND[2281719]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:import --limit=500 \>/dev/null 2\>&1)  
> Oct 23 16:40:02 team CROND[2282069]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:reports:scheduler \>/dev/null 2\>&1)  
> Oct 23 16:40:02 team CROND[2282068]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:rebuild --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:45:02 team CROND[2282340]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:segment:update --batch-limit=900 \>/dev/null 2\>&1)  
> Oct 23 16:45:02 team CROND[2282337]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:campaigns:trigger --batch-limit=1000 \>/dev/null 2\>&1)  
> Oct 23 16:45:02 team CROND[2282338]: (mautic) CMD (/usr/local/bin/php /home/mautic/public\_html/mautic.devced.com/bin/console mautic:broadcasts:send --batch-limit=1000 \>/dev/null 2\>&1)  
> [mautic@team ~]$

Do you see any further issues with the revised cron jobs:

 ![2023-10-23 09.41.10 cpanel.devced.com 06387fc41ac3](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/2X/e/eef1a661328495ceaa9df0d18674a237e929f634.png)

Thanks,  
Hal  
DevCED Team
