-
-
Notifications
You must be signed in to change notification settings - Fork 395
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OH4.1M5: Very very slow first startup and initial exception (HTTP 404) #1616
Comments
@openhab/core-maintainers for your information. I hope this is not the new IP scan ? |
I do not get the same exception after a restart. So it happens apparently only at the very first start. |
Time of startup is finally similar between M3 and M5, around 4 minutes for me. So the problem I am reporting is only the time to start at the very first startup and the associated exception that is logged. |
This issue has been mentioned on openHAB Community. There might be relevant details there: https://community.openhab.org/t/openhab-4-1-milestone-discussion/149502/146 |
Even if that exception is thrown because a client requests a resource not available yet, I would say, that exception should be suppressed. |
I agree, @florian-h05. It definitely looks as if there was some HTTP request coming in while the system was starting up and couldn't yet serve the resources. I have created openhab/openhab-core#3931 to not log errors in such a case anymore. @lolodomo Wrt start times, I am not sure how to best investigate this. So it only happens at the very first start? Can you somehow reproduce it on a test system? Was it maybe slow to install the remote add-ons because our artifactory might have had network issues? |
I am using the kar file and remote is disabled. Hope that kar file is still used. |
Strange but maybe you're right. |
I have upgrade to the snapshot yesterday evening and also experienced an extremely slow start-up. |
Yes, I would guess so as well. With today's snapshot, you shouldn't see any such log messages anymore as openhab/openhab-core#3931 is now contained. |
Hmm, with the latest snapshot I am getting this error:
|
Looks as if we have to catch yet another exception type... |
I wonder why we use |
I don't see any good reason for it, @J-N-K. |
It was the same for me with M5, no log before a very long time. |
I have tried out several recent snapshots, including the latest one 3792, and with none I have experienced a slow (first) startup again. |
@lolodomo & @florian-h05 We have a new snapshot distro (3794) available now. |
When upgrading to that snapshot, startup took the same time as usual, great! |
Feedback in few minutes with snapshot 3794... |
First startup: 3min23 to get the log entry "Starting openHAB 4.1.0 (build Build #3794)". 5m18 to have another log entry (LSP service). Around 8min20 to have everything loaded and started !!! If I stop and restart the server: 45s to get the same first log entry and around 3min55 to start everything. This looks bigger than before I believe.
I will compare normal start with 4.1 M3 later this evening. |
4.1 M3
Comparing a (re)start of 4.1 M3 and snapshot 3794 (meaning not the initial startup) is relatively similar in duration. Stop of the server is 45s with 4.1 M3 while 56s with snapshot 3794. Maybe the real problem is the 8 minutes for the very first startup of snapshot 3794. Remember that I use a kar file for addons so there is even nothing to download. I will now compare every 4.1 milestones on my PC with a fully empty setup. |
Could it be related to the installation of the discovery |
On a Windows PC for the very first startup with a fully empty config and no kar file until "Rule engine started." is displayed:
|
Yes, but that is without .kar. Then the file get's installed from the remote location where the source feature is immediately available. |
What? We require an external feature for the whole core to start up? That's an issue, I would say - so far, the core is meant to be fully contained in the distro and not dependent on any externally sourced feature. |
If I try again on PC with snapshot 3794 but this time with the kar file in addons, still with an empty config, it takes around the same time (38s). |
I can try again on my RPI the very first startup without the kar file. |
Very first startup on my RPI without the kar file and with setting remote set to true: yes, it is faster, but still around 7 minutes. |
For the second start, I get approximatively the same start time if I have initially the kar file or not. This is logic as I guess the kar file is not used at the second start. |
My SD card is now old, I don't know if it could explain such durations. |
@kaikreuzer I don't know. The problem is that the file needs to be updated when the remote feature changes especially important for snapshots). This is done automatically when the feature is refreshed. The question is if there is a better place to put it. Unfortunately the feature never installed for me if I don't add it as a boot feature. |
Disabling the finders changes apparently nothing to the restart time. |
@J-N-K I was thinking of something like #1620.
I would actually prefer to package it in |
No, I don't think the user needs to adjust something there. We just need to make sure that it is always the newest version (i.e. replaced on update). |
Then I would indeed suggest to move it to the runtime folder. I'm just preparing a PR for core. |
With snapshot 3796: 3min55s to get the first log and around 9min to have everything loaded at the very first startup. I will buy and try with a new SD card next week. |
Thanks for testing so early. Pity that the change didn't do any noticeable difference. 😢 |
It takes a long time to get a first log and it started by a n exception !
It was never as long before.
I am curious to know what is this HTTP request returning 404.
But finally the server started properly. After the initial exception, the time to start is similar as before.
The text was updated successfully, but these errors were encountered: