{"id":271,"date":"2020-01-21T16:02:20","date_gmt":"2020-01-21T16:02:20","guid":{"rendered":"https:\/\/pure-media.info\/?p=271"},"modified":"2020-01-21T16:04:06","modified_gmt":"2020-01-21T16:04:06","slug":"increase-tcp-connections-for-plex-on-ubuntu","status":"publish","type":"post","link":"https:\/\/pure-media.info\/index.php\/2020\/01\/21\/increase-tcp-connections-for-plex-on-ubuntu\/","title":{"rendered":"Increase TCP Connections for Plex on Ubuntu"},"content":{"rendered":"\n<p>Increase the number of simultaneous connections will help with importing Metadata at a faster rate and resolve issues where plex will run out of connections and Queue them in Memory. This could lead to a lockup of the system.<\/p>\n\n\n\n<p>Check the TPC Connection Limit<\/p>\n\n\n\n<p>The default max is 128 open sockets and can be seen by<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo sysctl -a | grep somaxconn<\/pre>\n\n\n\n<p>Now that we see the limit is so low. We can increase the limit.<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo nano \/etc\/sysctl.conf<\/pre>\n\n\n\n<p>Add the code below to the bottom to increase the limit.<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">net.core.somaxconn=65535<\/pre>\n\n\n\n<p>Use Ctrl + X to save and now reload the sysctl<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\"> sudo sysctl --system <\/pre>\n\n\n\n<p>Now the new limit is active and can be verified using the first step<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sudo sysctl -a | grep somaxconn<\/pre>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Increase the number of simultaneous connections will help with importing Metadata at a faster rate and resolve issues where plex<\/p>\n","protected":false},"author":1,"featured_media":273,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[85],"tags":[357,359,2,360,361,358,7],"class_list":["post-271","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tech-tip","tag-connection","tag-increase","tag-plex","tag-socket","tag-sysctl","tag-tcp","tag-ubuntu"],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/pure-media.info\/wp-content\/uploads\/2020\/01\/tcp.png?fit=309%2C163&ssl=1","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p7oBs4-4n","jetpack-related-posts":[],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/posts\/271","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/comments?post=271"}],"version-history":[{"count":2,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/posts\/271\/revisions"}],"predecessor-version":[{"id":274,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/posts\/271\/revisions\/274"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/media\/273"}],"wp:attachment":[{"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/media?parent=271"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/categories?post=271"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pure-media.info\/index.php\/wp-json\/wp\/v2\/tags?post=271"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}