0

Hello most helpful humans. I have read endless other threads on this subject, and typed a myriad of commands in terminal, but have caused myself more trouble than benefit it seems.

The problem is Plex, and its ability to find my external drive. Or that was the problem. Now the problem is that I can't seem to update or install anything.

Full error message is:

E: Type 'wget' is not known on line 1 in source list /etc/apt/sources.list.d/plexmediaserver

Please could somebody help me sort this out? I'm afraid I'm not much clued up on how to use Ubuntu properly - my usual approach when problems arise is to search online and copy code/follow instructions that someone else has written, which usually does whatever trick I'm hoping it will. I don't care at this point if I get Plex working (though it would be an added bonus for sure), but being able to update the computer again would be nice.

I realise it would be more helpful if this post had more information, but I'm afraid I need help knowing what to type in to get such information!

Thank you in advance for any help.

EDITS:

john@john-Inspiron-15-3552:~$ cat /etc/apt/sources.list.d/plexmediaserver
cat: /etc/apt/sources.list.d/plexmediaserver: No such file or directory
  • I have read the malformed line thread, but I find it really hard to understand a lot of the time. Not sure if it pertains to my issue or not. Sorry.

    john@john-Inspiron-15-3552:~$ cat /etc/apt/sources.list.d/plexmediaserver.list wget -q https://downloads.plex.tv/plex-keys/PlexSign.key -O - | sudo apt-key add - deb https://downloads.plex.tv/repo/deb public main

16
  • 1
    Please post the output of cat /etc/apt/sources.list.d/plexmediaserver Oct 15, 2018 at 10:22
  • cat: /etc/apt/sources.list.d/plexmediaserver: No such file or directory Oct 15, 2018 at 10:24
  • Welcome to Ask Ubuntu!!, try to re-download again your Plex package with wget. Oct 15, 2018 at 10:37
  • 1
    Try cat /etc/apt/sources.list.d/plexmediaserver.list. The .list extension is left off by the apt error message, which confuses things.
    – Jos
    Oct 15, 2018 at 10:51
  • 1
    @JohnLumley Paste them into the question. Anyway the contents of the .list file are plain commands that you should have executed, not put into the .list file.
    – Jos
    Oct 15, 2018 at 11:01

2 Answers 2

1

For the OP's situations :

remove the list first to follow

sudo rm -f /etc/apt/source.list.d/plexmediaserver.list

and add a key of Plex Package

wget -q https://downloads.plex.tv/plex-keys/PlexSign.key -O - | sudo apt-key add -

and make a list of Plex Package

echo deb https://downloads.plex.tv/repo/deb public main | sudo tee /etc/apt/sources.list.d/plexmediaserver.list

and then update your apt and install the Plex Package

sudo apt update && sudo apt install plexmediaserver

OR

Try to get Plex Package with repository way.

curl https://downloads.plex.tv/plex-keys/PlexSign.key | sudo apt-key add -
echo deb https://downloads.plex.tv/repo/deb public main | sudo tee /etc/apt/sources.list.d/plexmediaserver.list

install Plex Package

sudo apt update
sudo apt install plexmediaserver

and verify your installation

sudo systemctl status plexmediaserver

then config your firewall to allow traffic on Plex

sudo nano /etc/ufw/applications.d/plexmediaserver

and add

[plexmediaserver]
title=Plex Media Server (Standard)
description=The Plex Media Server
ports=32400/tcp|3005/tcp|5353/udp|8324/tcp|32410:32414/udp

[plexmediaserver-dlna]
title=Plex Media Server (DLNA)
description=The Plex Media Server (additional DLNA capability only)
ports=1900/udp|32469/tcp

[plexmediaserver-all]
title=Plex Media Server (Standard + DLNA)
description=The Plex Media Server (with additional DLNA capability)
ports=32400/tcp|3005/tcp|5353/udp|8324/tcp|32410:32414/udp|1900/udp|32469/tcp

saved and update your profile list

sudo ufw app update plexmediaserver

and then allow your firewall rule

sudo ufw allow plexmediaserver-all

verify your firewall rule

sudo ufw status verbose

and then make the directories that will store data of Plex

sudo mkdir -p /opt/plexmedia/{movies,series}
sudo chown -R plex: /opt/plexmedia

so we can proceed it with server configuration and open your browser with type

http://YOUR_SERVER_IP:32400/web

Hope this helps.

1
  • Thank you. This seems to be allowing my computer to update as normal now, and no system error messages have been received as per the last few days. Still can't access my hdd through plex, but will keep searching the forum before I ask any more questions. Thank you and @Jos again. Oct 15, 2018 at 23:56
1

This is a preliminary answer because comments are not sufficient to clear up the OP's situation.

The contents of the file plexmediaserver.list should look like:

deb http://download-address/

Meaning: the contents of the package plexmediaserver can be downloaded as a deb file. In your case however, the file contains commands that (probably) should have been executed once. (They involve downloading the public key to the software and adding it to your ring of trusted keys.) Not seeing a line like the above, the apt process complains about the .list file being malformed.

Re-read the instructions carefully, or provide us with the link, to see where exactly you have gone wrong.

Not the answer you're looking for? Browse other questions tagged .