Cleaning up the startup process / renaming rules (windows possible)

For me this works perfectly well on 2.5 - the numbers behind the bundles mean at what load level should the binding be loaded - ie. the rule engine at 98%.

/var/lib/openhab2/etc/scripts/startup.script

bundle:start-level org.openhab.core.model.thing 83
bundle:start-level org.openhab.core.model.thing.ide 83
bundle:start-level org.openhab.core.model.thing.runtime 83
bundle:start-level org.openhab.core.persistence 85
bundle:start-level org.openhab.core.model.item 90
bundle:start-level org.openhab.core.model.item.ide 90
bundle:start-level org.openhab.core.model.item.runtime 90
bundle:start-level org.openhab.core.model.sitemap 91
bundle:start-level org.openhab.core.model.sitemap.ide 91
bundle:start-level org.openhab.core.model.sitemap.runtime 91
bundle:start-level org.openhab.core.model.rule 98
bundle:start-level org.openhab.core.model.rule.ide 98
bundle:start-level org.openhab.core.model.rule.runtime 98

Nevertheless, there still might be some items which are not updated yet when your rules are triggered and they contain items which are not yet initialized/updated (thus are still NULL) - this can still cause error messages, but those ones can be avoided with this fix:

Item:
Switch SystemStarting

Rule:
var Timer startedTimer
rule “Start-Up”
when System started
then
SystemStarting.sendCommand(ON)
startedTimer = createTimer(now.plusMinutes(15)) [|
SystemStarting.sendCommand(OFF)
]

Start other rules which have caused error messages with ie.
Rule “Example”
when Item Example changed
then
if (SystemStarting.state == OFF)
{
// your code here
}
end