|
SageTV Downloads & Instructions This forum is for discussions containing Downloads and Instructions related to the Open Source version of SageTV. Please do not post questions in this forum. |
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
Basic Linux V9 Build and Walkthrough - Version 1
Seeing all the great work on Sage v9, I wanted to try and document a basic Linux install and setup. Its not complete, but I thought I would share what I have. I am going to try and re-run this tonight to verify it, and I will be making ongoing updates to this post. Suggestions, fixes, ideas are welcome and appreciated. Thanks!
Note: A posting about basic linux commands is available here (here) Note2: This has now been surpassed by a V2 install page and an automatic install script, available here (http://forums.sagetv.com/forums/showthread.php?p=585773) ** Important Note: At present, I can not get the SageTV client working on the linux host (no sound). This has not been an issue for me as I do not use my server as a playback system. If you have fixed this or need help, please post. 1) Backup your current install Backup anything you want to save on your computer (insert link to the upgrade sage thread). This is typically your entire sagetv directory, your media directory and any custom configurations (ir remote install, primenet encoder, sagedct, etc). 2) Install Linux See the post below for how (http://forums.sagetv.com/forums/show...92&postcount=2) 3) Configure the base OS If you installed the server version like I did, there is some extra work you have to do to install some basic gui support. If you've used the Desktop version, skim this, but you probably can skip most of this. As these are all apt-get commands, even if you have the desktop version, it should not hurt your install to run any of these commands. Log in as the user you created as part of the install process. You will be presented with a command line interface Install a basic GUI Execute the following command to install a very minimal gui Code:
sudo apt-get install xorg gnome-core gnome-system-tools gnome-app-install To explain the command: sudo or "superuser do" executes the following command as a super user. You must have sudo privileges to do this. by default the user created during install will have sudo privileges. apt-get is the ubuntu package manager. This command allows you to install, manage or remove linux software packages in linux. In this command, we are using the install keyword to install several packages. apt-get will automatically identify and install any missing dependancies for the software you ask it to install. It will also validate with you, after it has figured out what it needs to do, but before it installs anything. xorg: the xwindows base application gnome-core: the gnome window manager core packages gnome-system-tools: basic gnome system tools gnome-app-install: basic gnome applications Install a firewall config widget Code:
sudo apt-get install firewall-applet Code:
sudo apt-get install sysinfo Code:
sudo reboot 4) Check for updates Before going further, have your system check for updates. The OS install images are updated only for specific releases and as expected there patches and updates for your system that should be installed.
Its icon is a circular arrow in front of 4 cardboard boxes. Do not confuse this with the either the "Software Update" widget (with unfortunately the exact same icon), the "Software" icon (4 boxes) or the "Software & Updates" icon (a globe and a box). When you run this, you may get an error saying that it failed. Close the error window, the applet normally will keep running anyway. You will then get a progress window which will install updates and tell you as it does so. Command Line Alternative Code:
sudo apt-get update # Fetch the list of available updates sudo apt-get upgrade # Upgrade current packages sudo apt-get dist-upgrade # Installs updates (new ones) 4b) Configure your network settings If you were not prompted to configure your network settings during Linux install, you should configure it now. Open a terminal Select "Activities" -> "Show Applications" -> "Byobu Terminal" First get the current Network configuration by running the ifconfig command Code:
ifconfig Open the network interfaces configuration file in a simple editor Code:
sudo nano /etc/network/interfaces Code:
# This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5). # The loopback network interface auto lo iface lo inet loopback # The primary network interface auto eth0 iface eth0 inet dhcp Code:
# The primary network interface auto eth0 iface eth0 inet static address 192.168.0.27 netmask 255.255.255.0 gateway 192.168.0.1 dns-nameservers 192.168.0.1 8.8.4.4 Validate IP in hosts file Validate your computers IP. When using a static IP, Ubuntu expects your IP to be set correctly in the /etc/hosts file. This must be done for java to be able to auto detect your computers ip. Your local host should be listed second with your static ip. If it is not, you need to edit this file and set it. Code:
user@computer:~$ cat /etc/hosts 127.0.0.1 localhost 192.168.1.12 sagetvserver <-- edit this line if it = 127.0.1.1 ... Reboot so everything takes effect 5) Install Java Following directions from the Linux SageTV thread, install Java http://forums.sagetv.com/forums/showthread.php?t=62324 Open a terminal Select "Activities" -> "Show Applications" -> "Byobu Terminal" Code:
sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install -y oracle-java8-installer Add Java Environment Variables Installing Java does not appear to add the needed environment variables. This will add them to your ".bashrc" file. The ".bashrc" file is automatically run every time you create a new bash shell (it is your default login shell). If you use currently or choose to use a different logon shell, you should add these commands to a startup script for that shell. Code:
echo "" >> .bashrc echo "export JDK_HOME=/usr/lib/jvm/java-8-oracle/" >> .bashrc echo "export JAVA_ARCH=amd64" >> .bashrc echo "" >> .bashrc Code:
echo "" >> .bashrc echo "export JDK_HOME=/usr/lib/jvm/java-8-oracle/" >> .bashrc echo "export export JAVA_ARCH=i386" >> .bashrc echo "" >> .bashrc 6) Install Sage Dependancies Install ubuntu SageTV Dependancies (From the linux build thread http://forums.sagetv.com/forums/showthread.php?t=62324) Code:
sudo apt-get install libx11-dev libxt-dev libraw1394-dev libavc1394-dev sudo apt-get install libiec61883-dev libfreetype6-dev yasm autoconf libtool sudo apt-get install build-essential libaudio-dev libpulse-dev libasound-dev sudo apt-get install madplay libasound2 xorg libfaad-dev Reboot again to make sure all the libraries load appropriately Code:
sudo reboot 7) Install Sage Create a directory for sage Code:
mkdir sagetv cd sagetv http://forums.sagetv.com/forums/showthread.php?t=62422 NOTE: The below link is correct as of 22Nov2015. If a new version has come out, simply check the above thread for the lastest download. Download SageTV 9 JAR Code:
wget https://bintray.com/artifact/download/opensagetv/sagetv/sagetv/9.0.3.178/sagetv-server_9.0.3_amd64.tar.gz Code:
tar vfxz sagetv-server_9.0.3_amd64.tar.gz Unzip and extract the files Code:
unzip SageJar-9.0.3.178.zip 8) Install an updated Lucene Jar (From the windows install thread http://forums.sagetv.com/forums/show...056#post578056) Code:
cd JARs wget https://github.com/google/sagetv/raw/master/third_party/Lucene/lucene-core-3.6.0.jar mv lucene-core-3.6.0.jar lucene-core-3.6.0.jar.old mv lucene-core-3.6.0.jar.1 lucene-core-3.6.0.jar cd .. If you have a valid Window or Linux SageTV license key, create a file named "activkey" in the sagetv folder containing your key (from the following thread http://forums.sagetv.com/forums/show...406#post577406) Code:
echo "your key" > activkey Code:
echo "DF68I5-XXXXXX-XXXXXX-XXXXXX-XXXXXX" > activkey 10) Open network ports (UPDATED) Dec 6, 2015 - Command Line Firewall Config (UPDATED) Jan 1, 2016 - Notes (UPDATED) Jan 28, 2016 - iptables UDP Source Port To allow the client to talk to the server, you need to open ports on the server. Ubuntu is using the firewalld control for iptables. The following commands will use "firewall-cmd" to add ongoing exceptions to your firewall. Once complete, you will need to restart to ensure all changes have taken. Code:
sudo firewall-cmd --permanent --add-port=31100/udp sudo firewall-cmd --permanent --add-port=31099/tcp sudo firewall-cmd --permanent --add-port=8018/tcp sudo firewall-cmd --permanent --add-port=8080/tcp sudo firewall-cmd --permanent --add-port=7818/tcp sudo firewall-cmd --reload Code:
sudo iptables -I INPUT -p udp -m udp --sport 65001 -j ACCEPT Alternate/previous Way to Modify the firewall Quote:
Start the Sagetv Server Code:
sudo ./startsage 12) Install the Sagetv Client NOTE: I have not yet succeeded in getting the client to work consistently. Currently I am using the legacy (known working) clients as they are all compatible with the v9 server. Still working it.... Go back to your base directory Code:
cd .. Now create a sage client directory and switch to it. Code:
mkdir sageclient cd sageclient Code:
wget https://bintray.com/artifact/download/opensagetv/sagetv/sagetv/9.0.3.178/sagetv-client_9.0.3_amd64.tar.gz Code:
tar vfxz sagetv-client_9.0.3_amd64.tar.gz Run the miniclient Code:
./sageclient.sh Code:
cat /tmp/miniclient.log A draft walkthrough of installing an HDHomeRun Prime with PrimeNetEncoder is available in the following post http://forums.sagetv.com/forums/show...267#post581267 TODO: Figure out other ports that need to be opened for streaming or other (please holler in comments) Last edited by SageWizdom; 03-05-2016 at 07:04 PM. |
#2
|
|||
|
|||
Basic Linux Install
This is a walkthrough of a basic Debian Server Installation. Download Ubuntu Linux Reading through the forum, Ubuntu appears to be the desired OS for SageTV. Ubuntu is a Debian flavored distribution (version) of Linux which uses the ".deb" packages and the "apt-get" package manager. It is separate and different from the Red Hat flavor of Linux which uses ".rpm" packages and the "YUM" package manager. I mention this so that if you are looking for package dependancies, try to download the *.deb versions as it will be much easier to install. This will install a very minimal linux installation using "Ubuntu Server 14.04.3 LTS" version. LTS stands for Long Term Support (April 2019). This walk through should also work for the Ubuntu Desktop install. I would recommend installing the same version so that all the dependancies and build steps are/should be the same. http://www.ubuntu.com/download/server http://www.ubuntu.com/download/desktop Before Starting: Download the base image and burn to disk Have your system connected online Know your desired IP (if you want it to be static) An important note: In Linux, everything is case sensitive. This includes directory names, application names, host names, etc. Begin the Install: Boot with the install disk Select your Language Select "Install Ubuntu Server" Select your Install Language Select your Location Detect or Select your keyboard Layout Provide your system hostname: (ex. sagebox) Create a new user - Enter a full name: (ex. your name) - Enter a user name: (ex. your first name) - Enter a password: - ReEnter your password: - Do you want to encrypt your home directory: (Probably No) Select your time zone Set up your drive and partitions - You will be asked if you want to unmount any currently mounted partitions. This is where you are about to destroy anything currently on your computer. To be able to resize or adjust your system you need to say yes. Partition Disks - If you will be changing your disk layout in the future, use LVM (Logical Volume Management). - In this case use "Guided - use entire disk and set up LVM" - Select your primary disk "SCSI1 (0,0,0) (sda) - 1.0 TB ATA Hitachi HDS72101)" - You will be prompted to verify that you want to proceed -- Read carefully and proceed only when you are comfortable. If you are not sure wait and post questions first. - You will be asked if you are ready to write the changes to disk - Decide how much of the drive you want to use: we will use the entire drive (999.9 GB) - Select yes to write changes to disk The system will run for several minutes while installing and copying data You will be prompted if your computer sites behind a web proxy. This is uncommon enough that you should know if you do. If you are behind an http proxy, enter it now and continue The system will configure apt and begin to install software Do you want automatic updates? - I recommend yes Choose Software to Install: (Some good basics are) - OpenSSH - Samba file server The system will now install for a while ... Install the GRUB boot loader: Yes There will be some final installation and then the system will prompt for reboot. Remove the install disk and hit continue. After reboot, you will be prompted to login. ** There is now an automated install script for Sage and OpenDCT here (http://forums.sagetv.com/forums/showthread.php?p=585773) Last edited by SageWizdom; 03-05-2016 at 07:02 PM. |
#3
|
||||
|
||||
Looks good so far. I will add that the license key information is not entirely correct - in that you can use ANY SageTV server key, not just a SageTV Linux key - this key is only used to identify the server to the SageTV EPG server, so you can use Linux and/or Windows server keys interchangeably for this purpose.
__________________
Buy Fuzzy a beer! (Fuzzy likes beer) unRAID Server: i7-6700, 32GB RAM, Dual 128GB SSD cache and 13TB pool, with SageTVv9, openDCT, Logitech Media Server and Plex Media Server each in Dockers. Sources: HRHR Prime with Charter CableCard. HDHR-US for OTA. Primary Client: HD-300 through XBoxOne in Living Room, Samsung HLT-6189S Other Clients: Mi Box in Master Bedroom, HD-200 in kids room |
#4
|
|||
|
|||
Placeholder for Installing Network Tuners
TODO : Walkthrough for installing network tuners
|
#5
|
|||
|
|||
Quote:
|
#6
|
|||
|
|||
I've run this a couple of times now, I believe I have caught and fixed most of the bugs. There are a couple steps that have a user use the GUI (most notably firewall config) in this case, I could not figure out how to make the command line process anything other than very confusing.
|
#7
|
||||
|
||||
To me this just confusing for some one who may only want install the Sagetv Client only
|
#8
|
|||
|
|||
Quote:
Excellent detail. Thanks k |
#9
|
|||
|
|||
Here's another big "thanks!".
It's been awhile since I've done a fresh Linux install, so I really appreciate a straight-forward, step by step, set of instructions. The plan is to install this on a VM, primarily so I can verify that the Linux binaries can be built after I've made a change to native code.
__________________
System #1: Win7-64, I7-920, 8 GB mem, 4TB HD. Java-64 1.8.0_141. Sage-64 v9.2.1 ATSC: 2x HDHR-US (1st gen white) tuners. HD-200. System #2: Win7-64, I7-920, 8 GB mem, 4TB HD. Java 1.8.0_131. Sage v9.1.6.747. ClearQAM: 2x HDHR3-US tuners. HD-200. System #3: Win7-64, I7-920, 12 GB mem, 4TB HD. Java-64 1.8.0_141. Sage-64 v9.2.1 ATSC: 2x HVR2250; Spectrum Cable via HDPVR & USB-UIRT. 3x HD-200. |
#10
|
||||
|
||||
Quote:
https://github.com/stuckless/sagetv-vagrant There are 4 auto-configuring vms in that project for 32/64bit, console and ui. I each of those vms to test SageTV from time to time depending on the needs.
__________________
Batch Metadata Tools (User Guides) - SageTV App (Android) - SageTV Plex Channel - My Other Android Apps - sagex-api wrappers - Google+ - Phoenix Renamer Downloads SageTV V9 | Android MiniClient |
#11
|
||||
|
||||
@sagewizdom BooYaa! Followed you howto. Awesome thread. I knew just enough about linux to be dangerous. This was perfect!
Thanks Again!!
__________________
Home DVR: SageTV v9.2.6(64) i7-6700 3.4ghz, 8GB RAM, Win10 Pro, 1@ SSD +1@6TB WD Blue, 1 Quad HDHR, ( OTA Winegard HD8200U, CM4221HD), 1@ STP-HD200, 1@ Nvidia Shield , 1 @ Nvidia Shield new round version, 70" & 55" Sony's RV DVR: 2@SageTV v9.2.6, NUC8i5BEK 16GB, SS980Pro NVMe, 5TB Passport, 1@olderNUC, 2 Dual HDHR, , Winegard BatWing, 40", 32", 28" Sony's, Max Transit |
#12
|
|||
|
|||
Quote:
I don't mind making it "choose your own adventure style" if that could help, or I can just make a client only version. |
#13
|
|||
|
|||
Quote:
|
#14
|
|||
|
|||
Quote:
Things like: df -h (available space on all your partitions on the HD?) or other? |
#15
|
||||
|
||||
Just reg a Ubuntu Desktop ver with fresh install OS
|
#16
|
|||
|
|||
Quote:
__________________
System #1: Win7-64, I7-920, 8 GB mem, 4TB HD. Java-64 1.8.0_141. Sage-64 v9.2.1 ATSC: 2x HDHR-US (1st gen white) tuners. HD-200. System #2: Win7-64, I7-920, 8 GB mem, 4TB HD. Java 1.8.0_131. Sage v9.1.6.747. ClearQAM: 2x HDHR3-US tuners. HD-200. System #3: Win7-64, I7-920, 12 GB mem, 4TB HD. Java-64 1.8.0_141. Sage-64 v9.2.1 ATSC: 2x HVR2250; Spectrum Cable via HDPVR & USB-UIRT. 3x HD-200. |
#17
|
|||
|
|||
I've made several updates to the original post, including fixing the expected key format and adding some more pre-requisites to the step where they are installed. Note that with apt-get, you can always ask it to re-install the full list, and it will only install what you need.
|
#18
|
|||
|
|||
Updated v2 walkthrough
Hopefully in the near, near future, I'm going to update this walkthrough to include...
My goal is to have a walkthrough that works every time... Please comment if there are any additional features that folks would like to see included in the walkthrough (ex. commands / other) |
#19
|
|||
|
|||
I'm writing up v2 of this guide (using the .deb files... etc). Is there a preference of how to post? Should I replace the current guide? Put the current in a reply? Create a new thread and and just name it v2. Let me know if there is a preference. Thanks.
|
#20
|
|||
|
|||
Can you add links for non ubuntu deb directories. I personally use LMDE2 & I think there are others that use Linux Mint flavor of Linux over Ubuntu.
Keep up the good work. Cheat sheets are always welcome. Galaxysurfer |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Build SageTV (Linux Specific) + GitHub primer | stuckless | SageTV Github Development | 81 | 09-04-2016 12:27 PM |
Supported USB Wireless Adapters: Compiling a definitive list. | neurocis | Hardware Support | 1 | 07-16-2011 11:30 PM |
BMT Walkthrough | gabe1475 | Batch Metadata Tools | 42 | 11-12-2010 06:16 AM |
New SageTV Server Build (First Draft) - Opinions Please | makko | Hardware Support | 8 | 10-07-2010 07:01 PM |
New SageTV Client Build basic question | AWS | Hardware Support | 2 | 02-08-2005 08:03 PM |