Emby streaming choppy

aunsoenr

Dabbler
Joined
Jan 6, 2017
Messages
32
I have a freenas server and have been running into issues after the 11.2 upgrade.

I have my emby setup in iocage on 11.2, but for some reason cannot stream video that require greater than 3mb/s bandwidth. The playback is choppy.

Videos play fine if I transcode. However I can sustain a steady 1.6 MB/s upload from my other plugins (my bandwidth is 30mb/s upload).

I can also play videos fine in my LAN. My WAN connection outside my network has plenty of bandwidth and have not had issues with other services.

How do I diagnose the issue?
 
D

dlavigne

Guest
Hardware specs?
How many plugins/jails/vms installed?
Anything in /var/log/messages when the choppiness occurs?
What's the full output of ifconfig within code tags?
 

aunsoenr

Dabbler
Joined
Jan 6, 2017
Messages
32
I have a quad core e5 processor (e5-1603), 32gb of ram, 8 jails - mostly idle, except emby.

/var/log/messages inside the emby jail?

I don't know where ifconfig is.
 

DrKK

FreeNAS Generalissimo
Joined
Oct 15, 2013
Messages
3,630
"ifconfig" is a UNIX command she would like you to issue and report the results on.

And I would check those files both in the jail, and in the host, same with issuing ifconfig in both. Just for completeness.
 

aunsoenr

Dabbler
Joined
Jan 6, 2017
Messages
32
No messages inside the jail:

1549949365972.png


Ifconfig inside jail:

1549949412500.png


No messages in main either, ifconfig in main:


em0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 150 0
options=2098<VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_MAGIC>
ether 90:b1:1c:93:73:9a
hwaddr 90:b1:1c:93:73:9a
inet 192.168.0.101 netmask 0xffffff00 broadcast 192.168.0.255
nd6 options=9<PERFORMNUD,IFDISABLED>
media: Ethernet autoselect (1000baseT <full-duplex>)
status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
inet 127.0.0.1 netmask 0xff000000
nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
groups: lo
bridge0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
ether 02:26:88:7f:b7:00
nd6 options=1<PERFORMNUD>
groups: bridge
id 00:00:00:00:00:00 priority 32768 hellotime 2 fwddelay 15
maxage 20 holdcnt 6 proto rstp maxaddr 2000 timeout 1200
root id 00:00:00:00:00:00 priority 32768 ifcost 0 port 0
member: vnet0:9 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 12 priority 128 path cost 2000
member: vnet0:8 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 11 priority 128 path cost 2000
member: vnet0:7 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 10 priority 128 path cost 2000
member: vnet0:6 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 9 priority 128 path cost 2000
member: vnet0:5 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 8 priority 128 path cost 2000
member: vnet0:4 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 7 priority 128 path cost 2000
member: vnet0:3 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 6 priority 128 path cost 2000
member: vnet0:2 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 5 priority 128 path cost 2000
member: vnet0:1 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 4 priority 128 path cost 2000
member: em0 flags=143<LEARNING,DISCOVER,AUTOEDGE,AUTOPTP>
ifmaxaddr 0 port 1 priority 128 path cost 20000
vnet0:1: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: unifi
options=8<VLAN_MTU>
ether 02:ff:60:87:00:b4
hwaddr 02:6c:d0:00:04:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:2: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: madsonic
options=8<VLAN_MTU>
ether 02:ff:60:df:35:cc
hwaddr 02:6c:d0:00:05:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:3: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: rslsync
options=8<VLAN_MTU>
ether 02:ff:60:51:f4:ac
hwaddr 02:6c:d0:00:06:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:4: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: sonarr
options=8<VLAN_MTU>
ether 02:ff:60:a5:a4:7e
hwaddr 02:6c:d0:00:07:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:5: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: lidarr
options=8<VLAN_MTU>
ether 02:ff:60:ba:f6:9a
hwaddr 02:6c:d0:00:08:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:6: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: radarr
options=8<VLAN_MTU>
ether 02:ff:60:c1:df:ca
hwaddr 02:6c:d0:00:09:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:7: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: transmission
options=8<VLAN_MTU>
ether 02:ff:60:03:aa:46
hwaddr 02:6c:d0:00:0a:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:8: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: emby
options=8<VLAN_MTU>
ether 02:ff:60:79:aa:5f
hwaddr 02:6c:d0:00:0b:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
vnet0:9: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
description: associated with jail: jackett
options=8<VLAN_MTU>
ether 02:ff:60:b1:b8:71
hwaddr 02:6c:d0:00:0c:0a
nd6 options=1<PERFORMNUD>
media: Ethernet 10Gbase-T (10Gbase-T <full-duplex>)
status: active
groups: epair
 

anmnz

Patron
Joined
Feb 17, 2018
Messages
286
cannot stream video that require greater than 3mb/s bandwidth. The playback is choppy.

Videos play fine if I transcode.

I don't have experience with Emby, just Plex, but thought I would mention this as perhaps the same thing could be happening.

A thing that happens with Plex is that when transcoding it serves up data in a large number of tiny chunks, compared to the much much larger chunks it serves up when playing directly. This means that sometimes clients will play back *much* more smoothly from a transcoded stream than from a direct play stream at a similar bit rate. I definitely see this in action when streaming at 1080p to a Samsung TV at home.

I imagine the effect is most pronounced for relatively resource-constrained clients like a smart TV. You don't mention what kind of client you are streaming to though.
 

aunsoenr

Dabbler
Joined
Jan 6, 2017
Messages
32
I don't have experience with Emby, just Plex, but thought I would mention this as perhaps the same thing could be happening.

A thing that happens with Plex is that when transcoding it serves up data in a large number of tiny chunks, compared to the much much larger chunks it serves up when playing directly. This means that sometimes clients will play back *much* more smoothly from a transcoded stream than from a direct play stream at a similar bit rate. I definitely see this in action when streaming at 1080p to a Samsung TV at home.

I imagine the effect is most pronounced for relatively resource-constrained clients like a smart TV. You don't mention what kind of client you are streaming to though.


I am using a Firetv box, 2nd gen 4k. These devices can play without issue inside the LAN without transcoding.
 

aunsoenr

Dabbler
Joined
Jan 6, 2017
Messages
32
Just as an update..

This problem only happened when I was out of country or out of province. It works fine in the same city or province. I can comfortably stream videos requiring over 20mbps, with no delay. Must be some odd thing my ISP is doing (or issue with latency)?

I have also decided to move my jails to a dedicated ssd, move my downloads to a separate 1tb raid, add 128gb of ram and a 8core processor (e5-2680). Will start with a fresh install, this setup has been unstable since the change from jails to iocage.
 
Top