viernes, 12 de julio de 2019

My Home Theater PC

I wrote about my first self made PC build,  in which I talked about my first experience in getting PC parts myself and putting them together.  This PC however, became eventually outdated and was replaced as my daily driver by my current build (which is better in every way). But just because I don't use it everyday doesn't mean I have no use for it.

The Home Theater PC

With the passing of years I've found some purpose for it, like live backups, as a repository with file sharing, as a computer to lend others when in need, and most importantly as a computer I can give time consuming tasks in a way I won't notice it. Like downloading a lot of files over a few days uninterruptedly.

It also got the role of a Home Theater PC, which led me to move it to the living room and connect it to the TV and Speakers. Whenever we wanted to watch something from my PC, I would boot it up (Windows), play the file, set full screen and configured whatever was necessary. This approach got us through several years, albeit my not-so-tech-savvy family were always hesitant in using it without my presence. Now, my living room is not near my bedroom/office so when it came to managing the system I decided to control the PC over Windows' Remote Desktop Protocol.

However I wanted to manage my downloads on a Linux environment, and at the same time wanted to make it more transparent for all the people I live with to access the media contained within the PC.  After some time I discovered Plex.

The Content Distributor: Plex

Plex is amazing, in my opinion, for it takes my media files and present them over the local network through a platform similar to popular streaming services. Since my family is already used to streaming services like Netflix, this approach was definitely a right one. I installed it and we began to use it.

Unfortunately our living room smart TV isn't Android, and whatever OS it uses doesn't counts with the client application for Plex. So no Plex for the time being.   I would then go on to research for Android devices compatible with Plex that I could hook up to the TV. Eventually I found the Roku.

Plex and Roku

So I bought one. Fairly recently by the way. The Ultra version, and then an Express+ version for the non-smart kitchen TV.  They work quite well, though I get no web browsing on them. But they are quite fast, while some nice brand Smart TVs come with sluggish hardware.

Thanks to the Roku, my family no longer has to interact with my computer anymore. And although they have yet to use Plex on their own, I expect them to pick it up without too much hassle.

The Switch of Operating System

The separation between the Home Theater PC and the not-so-tech-savvy humans allowed me to switch the OS to a Linux distro. I was managing the Windows OS in a separate Solid State Drive. I decided to buy another SSD for the Linux and probably dual boot them. However I've never really like boot loaders, and on top of that this computer will no longer use a screen. Meaning that if I wanted to switch OS I would have to plug a screen and select the OS before going back to my computer and remote control it.

So I decided to install a SATA switch, therefore ending up with what seems like a hardware level dual boot. This device adds a few buttons on the back of my PC and each button represents a SATA drive. If it's pressed the SATA drive is powered with the system, otherwise not. It's a fun gadget and as long as I don't leave both drives set for use I won't have problems switching over and neither OS is aware the other exists. Each believes they are my one and only. Guess that makes me a two-timer. Shame on me.

Since the PC is still away from my usual premises, and even away from a screen, I was expecting to use xRDP for remote access.  Since I got it working once not so long ago on Mint with KDE, I chose to install Mint.

The Remote Access Problems

However . . .  never again did I manage to get xRDP working. This shattered my initial dreams of connecting to the IDE from my Windows daily driver via the RDP. This forced me to use an application that I don't really like that much: TeamViewer.

TeamViewer provides free use for non-commercial purposes. And that is fine, and generous too. But it's not smooth enough. Of course the experience depends on network quality.  If LAN connections isn't enforced in the server machine, then TeamViewer won't care if both machines are next to each other and will communicate them over their cloud service. After I made sure it was LAN only enforced and added the rules to the Firewall, the quality and response was not that different.  So I ditched TeamViewer. Actually, I decided to ditch the IDE all together.

Now that I decided that I won't be connecting to the IDE, I had to make sure to enable a few things and leave them ready so that I can still make use of the machine. So . . .  no IDE means I will use console.

For console, I installed ssh and then connect with Putty.  This allows me to open the console from my computer and since there is no IDE it is all very snappy.  This also needed a new rule for the firewall. So far so good.

Since Plex is a web application, I can manage it through my browser in an OS-agnostic manner.  Other needed cares since switching to Linux is auto-mounting the needed partitions with enough rights so that Plex can find the content sources when the system starts. Also, firewall.

But if I want to add stuff to Plex, then I need to move files.  And I might want to move the files across different systems over the network. I can use the console for this, but if becomes a bit complicated with long URL's or when more selectiveness needed.  So I decided I will be sharing the folders with authentication and enough privileges so that I can use any file explorer. So I installed SAMBA. Also, firewall.

For downloads, Linux comes with this pretty useful Torrent client, called Transmission. I think it's my favorite client ever since Opera stopped embedding one with their browser. So I installed a "client" version in my Windows machine, and configured it to connect to my Linux machine. In my Linux machine I set it up so it starts automatically because I haven't managed to start Transmission with the GUI from my ssh console. So, with this set up I can add magnet links from my computer and stop or start downloads. Of course, this also required a firewall rule.

Aftermath ? 

It's been a couple of months since I finished this set up. I like it. Can't say I pay much attention to it as much as I want to but maybe that's an indication that it works well. Guess my experience as a web application developer has helped me come up with good home experiment ideas.

No hay comentarios:

Publicar un comentario