Problem with stream component setup

Hey,

I have a small problem with the stream component.
If I write it in the configuration, I get many errors in the console.
Errors: https://pastebin.com/igjrcYRF
(Maybe its helpful to know, before the errors appear, homeassistant gets stuck at “installing av==6.1.2” sometimes and continue after a few seconds)
The errors disappear as soon as I remove the stream component out of the configuration.
I installed Homeassistant on a Windows Server in a virtual python environment.
I hope you guys can help me I tried to fix this since days but no success.

(I hope my english is good enough to understand my problem ^^)

but where is your stream config itself?

I need a stream configuration file?
I only can read that I need to put stream: in the configuration.yaml (Source: https://www.home-assistant.io/components/stream/)
I didn’t configured anything else except that. Can’t configurate more because home assistant crashes with errors (See first Post)

Or do you mean my configuration.yaml ?

I meant ALL that is related to your issue. Can’t tell you exactly what as it’s your system after all…

So ?
Don’t know what I can do :frowning:

Looks like a dependency problem.
You can install the dependencies manually by entering this in the console:

sudo apt-get install -y python-dev pkg-config libavformat-dev libavcodec-dev libavdevice-dev libavutil-dev libswscale-dev libavresample-dev libavfilter-dev

Let me know if it solved the problem.

Edit: I see you use Windows, may I advise you to move to a linux distro instead? They are much more stable and need a lot less configuring. Many things like zeroconf and autoconf do not play very well with windows without using proxies and portforwarding. It is just advice ofc.

Mhh ok.
I’ll think about it ^^
Do you think it’s possible to install an virtual environment with Ubuntu on a Windows Server ?
Would everything work then? (autoncof and zeroconf)
And can I use my old configuration from the Windows Server ?

Yes yes and yes. I have Windows Server 2016 and use Hyper-V. Within Hyper-V I installed Ubuntu 18.04 and from there I did the steps for a python venv. It works perfectly fine. No ports, no proxies, everything works just as if it was a “real” ubuntu install.

Ok I’ll give it a try!
I let you know if everythings worked fine ^^
(First have to read how I can setup a Hyper-V wih Ubuntu)

Hyper-v is just a package within windows/windows server. You can enable this by adding features in Windows. Then start Hyper-V manager and set it up to your likings. (Default settings are probably fine).
Then download Ubuntu as an ISO. Second add a VM in Hyper-V manager and make sure to select generation 1 (gen 2 will not work at least it didn’t for me). Then choose a location for your virtual hdd and add the ubuntu iso as the install medium for your OS.
Start the VM and install Ubuntu as you normally would. That is it!

Good luck!

Do you have any suggestions of how to install stream on a mac?

Hey jimz,
Are 4GB Ram and 60GB Disk enough for the Ubuntu Distribution for only HA ?

@WolfsW3lp3 60GB will be fine, 2GB RAM should be sufficient, however if you can allocate 4GB I would. Just keep in mind that you will need to purge your database (history, event log etc) every so often as it will take up a lot of space eventually. You can find how to do that in the docs (I use an external DB, MariaDB on another disk, but if you use the standard one you should be aware of this).

@RobDYI I am sorry but I haven’t used macs for this in the past so I wouldn’t know. I’m sorry.

I have a little problem starting up homeassistant!
During the first startup with the copied configuration it ran into errors:
https://pastebin.com/TKeS4vu2

Alright, I see 2 things when reading over it quickly. It is missing some dependencies and the ssl certificate used is either invalid, in the wrong location or unreadable.

Tbh, when starting up a fresh install best practice would be to add the components one by one, but I can understand this might be a lot of work. If you happen to know which components require separate dependencies you can look in the docs for that specific component on how to install those. For example: IKEA Tradfri requires autoconf, stream requires a bunch of dependencies and there are several other components that will require something.

To start off with I would suggest fixing the SSL certificate first (or remove it all together for the time being) so that you can at least access the frontend. That will save a lot of headache as you can see in the frontend which components did not load, or which components would require extra setup. For example, IKEA Tradfri requires you to enter a code in the frontend before you can use it. Some integrations can be installed from the UI, but there are too many to name them all here.

What I would do is start Home Assistant clean with the default configuration and work from there. This way you will at least know if HA starts at all or not and from there you can add things one by one. Most of the time, integrations are done via the UI (unless there is not one available yet). Most sensors do not require a setup as they are in core HA. For example if you use MQTT with discovery, you will have to do this in the UI. If you enter MQTT config manually then you can only use autodiscovery if you only setup the broker and not the entities.

I hope this helps a bit. I did a complete fresh install of HA a few weeks ago (I have over 18.000 lines of code in my config files combined). What I did was to let HA auto discover everything first and work from there. Cutting snippets of my old code into the new one (the ones that can’t be discovered automatically etc).

After you reconfigured everything, copy your ui-lovelace.yaml file back (or if you use storage mode do it from there). I would also recommend you to start HA with the states UI, as Lovelace can bug if there are entities that do not exist or if there are entities with a different name.

I will have to add though that this process might take a bit of time depending on the size of your setup. It took me a whole evening to do my setup, I chose for a fresh setup and only copying stuff I needed from my old setup as I did not want old unused stuff to be copied over as well.

Oh I forgot to mention, you will only have to do this for components, you will not need to rewrite your entire lovelace setup. Just make sure the entity names are corresponding after the initial configuration. Sometimes entities get a different name after a fresh install (but probably most will stay the same).

Yeah srry for the long text, not easy to explain. Anyways try this, not sure if it will work, but you could try:

sudo apt install ffmpeg

Edit: I guess you figured it out already as your post is withdrawn :smiley:

Haha yes I figured it out ^^

Thank you very much for your help <3
I really love this Community :smiley:

1 Like

You are most welcome!

Edit: if by any chance you are looking for ideas you can check my github repo:

1 Like

I already did ^^
I’m using your vertical-stack-in-card template ^^ Loving it :smile:

Have a nice evening from Germany(To avoid confusion ^^)