Skip to content
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

New option for Homebridge_OPTS #1864

Closed
Nastras opened this issue May 21, 2018 · 6 comments
Closed

New option for Homebridge_OPTS #1864

Nastras opened this issue May 21, 2018 · 6 comments

Comments

@Nastras
Copy link

Nastras commented May 21, 2018

Hello everybody,
i have 24 Homebridge instances running as systemd service, one instance for each plugin.

What has always disturbed me and synonymous has reduced the system speed is that every instance starts all the plugins from global installed / usr / lib / node_modules.
By a note from another user, the solution became aware of the -P option to use. To test I have installed all the plugins local what a little more cumbersome the conventional way and started with the -P option.

Now each instance just launches the plugin it needs.
If I install the plugins globally in / usr / lib / node_modules I have a random access memory consumption when all 24 instances are started from 2.5GB.
With an installation of the plugins locally is that only each instance the plugin loads what it needs at 700 MB. Here is a huge performance difference especially for raspberry pi user.

My own hardware is an Intel nuc, because with the raspberry pi 3 the random access memory was no longer sufficient. On my raspberry pi 3 I could start a maximum of 10 instances. I think that many users use their Homebridge with multiple instances because the advantages are very big compared to the single instance.

I have also tried using the -P option to start the instances when the plugins are installed in / usr / lib / node_modules. Unfortunately all plugins will be loaded in every instance. I also received this message:

skipping plugin found at '/ usr / lib / node_modules / homebridge-sun-position' since we already loaded the same plugin from '/ usr / lib / node_modules / homebridge-sun-position'.

Would not it be useful here to create maybe a new option -X for the (config option) in homebridge which still allows the plugins globally to be installed under / usr / lib / node_modules. This would allow for each instance only the plugin to start what is needed without reinstalling all plugins to local.

For the ever larger Homebridge setups of the users I think that it would be a great new feature.

Greeting Nastra

@theo-69
Copy link

theo-69 commented May 21, 2018

Great Idea

@m4d-maNu
Copy link

Good idea, please intrigue in HB.

@seydx
Copy link
Contributor

seydx commented May 22, 2018

Very nice idea, i have submitted a pull request to make that possible

#1866

@Heiliger85
Copy link

Great idea. I hope it will come in next version of Homebridge.

@NSCHI
Copy link

NSCHI commented May 25, 2018

Great idea

@Nastras
Copy link
Author

Nastras commented Jun 6, 2018

#1880
solved!

@Nastras Nastras closed this as completed Jun 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants