Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I have a load balanced setup having 2 servers running Umbraco 7.1.9
Master : editors work on this server and have a url for accessing this server like editor.mydomain.comSlave : not editor work will be done on this server
My domain www.mydomain.com will go through a load balancer and load will be distributed between master and slave.
We have set up load balancing according to this : https://our.umbraco.org/documentation/Installation/load-balancing#Correctconfigforscheduledpublishing&tasks
This is myconfig :
<!-- the id of the user who's making the calls -->
<!-- needed for security, umbraco will automatically look up correct login and passwords -->
<server serverName="Slave1">internaldomain2.com</server> </servers>
The domains used here are internal domains that only work behind the loadbalancer. This setup works fine. When a user publishes something on the Master server the cache of the Slave server get's updated.
We have noticed that scheduled tasks are not running for some reason. So scheduled publishing of content does not work.
We tried adding a baseUrl for the scheduled taks as described here : https://our.umbraco.org/documentation/Using-Umbraco/Config-files/umbracoSettings/#ScheduledTasks
But that didn't have any effect.
<scheduledTasks baseUrl="internaldomain1.com/umbraco"> <!-- add tasks that should be called with an interval (seconds) -->
<!-- <task log="true" alias="test60" interval="60" url="http://localhost/umbraco/test.aspx"/>-->
I also tried setting the baseUrl to editor.mydomain.com/umbraco but that also didn't have any effect.
There are also no entries in the log for the task scheduler (searched for Umbraco.Web.Scheduling.Scheduler , Umbraco.Web.Scheduling.ScheduledTasks)
If I run the same application in a non load balanced setup everything works as it should.
Anybody got an idea what i'm missing here ?
Still need some help on this. All help is appreciated.
Bumping this up again.
After some more digging throug the logs I found this :
2015-04-02 09:27:38,103  DEBUG Umbraco.Web.Scheduling.Scheduler - [Thread 48] Scheduling interval executing
2015-04-02 09:27:38,119  DEBUG Umbraco.Web.Scheduling.Scheduler - [Thread 48] Current server (XXXX) detected as a slave, no scheduled processes will execute on this server
2015-04-02 09:27:38,119  DEBUG Umbraco.Web.Scheduling.Scheduler - [Thread 48] Scheduling interval complete (took 4ms)
With this information I went on search throught the Umbraco source.
If the server is detected as Slave instance than it will not start the scheduled tasks :
So in this file (https://github.com/umbraco/Umbraco-CMS/blob/7.1.9/src/Umbraco.Core/NetworkHelper.cs) we see that the machine name or dns hostname is used to determine if a instance is the master instance.
After updating the serverName attribute to match the machine name scheduled publishing started working.
I made a pull request to update the documentation.
Awesome - I've been having this issue with a load balanced version of 7.2.2 - this fixed things up nicely! Thanks heaps, Dave :)
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted