All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
[How To] Install NewzNab on Ubuntu 12.04
**** Basic Tutorial on How To Install NewzNab on Ubuntu 12.04 64 bit. ****
This tutorial is optimized for speed and intended to be setup on a server dedicated to Newznab ONLY
Perform a clean installation of Ubuntu 12.04 64-bit.
Login as root and perform an 'apt-get update'.
Download minstall:
cd ~; rm -rf minstall; mkdir minstall; cd minstall; wget --no-check-certificate -O minstall.tar.gz http://www.github.com/downloads/KnightSwarm/Minstall/Latest.tar.gz; tar zxvf minstall.tar.gz; rm minstall.tar.gzRun: bash minstall.sh install-extra-repositories
bash minstall.sh clean-packages
bash minstall.sh install-sshReboot
'cd minstall' and run: bash minstall.sh install-extra-packages
Run: bash minstall.sh configure-general
bash minstall.sh configure-ssh
bash minstall.sh configure-upgrade
bash minstall.sh configure-usergpg --keyserver hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
gpg -a --export CD2EFD2A | apt-key add -sh -c "echo \"\n#Percona\" >> /etc/apt/sources.list"
sh -c "echo \"deb http://repo.percona.com/apt lenny main\" >> /etc/apt/sources.list"
sh -c "echo \"deb-src http://repo.percona.com/apt lenny main\" >> /etc/apt/sources.list"nano /etc/apt/preferences.d/percona
and put this inside:
Package: *
Pin: release l=percona
Pin-Priority: 700
apt-get update
apt-get install -y php5 php5-dev php-pear php5-gd php5-curl nginx php5-fpm mc percona-server-client-5.5 percona-server-server-5.5 libmysqlclient-dev php5-mysqlmkdir -p /var/log/nginx
chmod 755 /var/log/nginx
mkdir -p /var/www/newznab
chmod 777 /var/www/newznabnano /etc/nginx/sites-available/newznab
server {
# Change these settings to match your machine
listen 80 default_server;
server_name SERVER_IP_HERE or LOCALHOST;
# Everything below here doesn't need to be changed
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
root /var/www/newznab/www/;
index index.html index.htm index.php;
location ~* \.(?:ico|css|js|gif|inc|txt|gz|xml|png|jpe?g) {
expires max;
add_header Pragma public;
add_header Cache-Control "public, must-revalidate, proxy-revalidate";
}
location / { try_files $uri $uri/ @rewrites; }
location @rewrites {
rewrite ^/([^/\.]+)/([^/]+)/([^/]+)/? /index.php?page=$1&id=$2&subpage=$3 last;
rewrite ^/([^/\.]+)/([^/]+)/?$ /index.php?page=$1&id=$2 last;
rewrite ^/([^/\.]+)/?$ /index.php?page=$1 last;
}
location /admin { }
location /install { }
location ~ \.php$ {
include /etc/nginx/fastcgi_params;
fastcgi_pass 127.0.0.1:9000;
# The next two lines should go in your fastcgi_params
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
unlink /etc/nginx/sites-enabled/default
ln -s /etc/nginx/sites-available/newznab /etc/nginx/sites-enabled/newznabnano /etc/php5/cli/php.ini
edit: max_execution_time = 120
edit: memory_limit = -1
edit: date.timezone = Europe/Amsterdam (for example)nano /etc/php5/fpm/php.ini
edit: max_execution_time = 120
edit: memory_limit = -1
edit: date.timezone = Europe/Amsterdam (for example)nano /etc/php5/fpm/pool.d/www.conf
Each process takes about 60Mb. Keep this in mind when configuring FPM. These settings are for a 512MB Linode. Adjust as necessary.
pm = dynamic
pm.max_children = 7
pm.start_servers = 1
pm.min_spare_servers = 1
pm.max_spare_servers = 2
pm.max_requests = 500
listen = 127.0.0.1:9000
- wget http://www.newznab.com/newznab-0.2.3.zip
unzip newznab-0.2.3.zip
mv newznab-0.2.3 newznab
mv newznab /var/www/
19.chmod 777 /var/www/newznab/www/lib/smarty/templates_c
chmod 777 /var/www/newznab/www/covers/movies
chmod 777 /var/www/newznab/www/covers/music
chmod 777 /var/www/newznab/www
chmod 777 /var/www/newznab/www/install
chmod 777 /var/www/newznab/nzbfiles/
nano /var/www/newznab/www/lib/framework/basepage.php
Find: $this->serverurl = (isset($_SERVER["HTTPS"]) ? "https://" : "http://").$_SERVER["SERVER_NAME"].($_SERVER["SERVER_PORT"] != "80" ? ":".$_SERVER["SERVER_PORT"] : "").WWW_TOP.'/';
Replace HTTPS with HTTPReboot
Open Webbrowser http://yourip/install and follow instructions
Delete install dir: rm -rf /var/www/newznab/www/install
Comments
AaarrGGhhh, Markdown seriously. Why can't we be friends!?
How do I properly list code? I now used < pre > tags but look at the mess.
The ' trick isn't working properly when using code on multiple lines
< code > is crappy too.
Indent code, should work
Cool, what are you gonna use newznab for?
Isn't indent code the ' trick?
In combination with SickBeard and CouchPotato to automatically download my favorite TV Shows/Series and Movies from Usenet
Thanks Freek.
Nice tutorial. Thanks Freek
@Freek: Ah I see, its like running your own nzbsrus for SickBeard / CouchPotato?
Correct!
PS: If a mod could fix the Markdown in my TS that would be great!
Why go with a self-hosted one instead of NZBMatrix, DogNZB, etc etc?
Newzbin recently closed it's door so the only real alternative right now is NZBMatrix, sinds NZB.org & DogNZB is on invite basis only. NZBsRus does not have backlog functionality.
And ofcourse, because you can! Playing with servers is fun
Bear in mind it consumes pretty much RAM. 512MB is probably only enough for personal use.
If you want an invite for DOGnzb just PM me your email address. Btw SickBeard has an integrated Newznab service that works pretty well
PM Sent
True but it doesn't support backlog searches.
Has anyone tried to install on Ubuntu 12.10? After I run bash minstall.sh clean-packages and reboot all I get is a blank desktop with the default wallpaper...no icons nothing. Does this only work on 12.04?
Only designed to work with 12.04 server!
Since I can't edit the OP anymore, updated version available here:
http://freek.ws/2012/12/02/basic-tutorial-on-how-to-install-newznab-on-ubuntu-12-04-64-bit/
I think I know what I'm doing with my Kimsufi tonight, thanks!
Hi
Just followed this to the letter, but seem to have a permissions issue ...
403 Forbidden when trying to get to the install page, and this in the logs:
2012/12/10 20:09:38 [error] 2151#0: *2 open() "/var/www/newznab/www/install" failed (13: Permission denied), client: IP, server: IP, request: "GET /install HTTP/1.1", host: "IP"
I have double checked and re-ran:
chmod 777 /var/www/newznab/www/install
Any ideas ?
Thanks
Nik
@nikc You need to change the owner of the folder to that of your web server:
chown www-data:www-data /var/www/newznab -R
I'd love to see a config for an nginx server running multiple sites. I'm tinkering around with it but I'm far from an nginx config expert.
lenny?
I've setup newznab with these settings on a 1GB RAM VPS, and during the update, the MySQL process takes up more and more ram and eventually crashes. Is there a way of limiting the amount of resources the DB takes up?
Just configure it as a vhost, @mattgrif.
@funtek Yes, try and limit pm.max_children to lets say 3 for testing.
Anyone had any luck with generating releases? Everything else upto and including getting the binaries seems to be working, but when I run the script to generate releases, it runs through but none are created.
chown www-data:www-data /var/www/newznab -R
Didn't help Any other suggestions ?
For folks not getting any releases....you need to pay for the plus version which comes with the REGEXS needed to create releases out of the headers. The free version is worthless without these.
@Freek
A hefty bit of googling brought me to the same conclusion (probably would have worked it out quicker if the SABnzbd forums hadn't been temporarily closed), seems a bit weird that the free version doesn't processes anything though, it's hardly an incentive to buy.
I ran the classic version before I bought the plus version and it worked fine? I was getting releases so...
I guess it may depend on the groups you chose to index, and how far back you went. Obviously nothing in the classic version could match to the groups I tested it with, because I grabbed the headers just fine.
The 16USD for the plus version (one off fee) wouldnt be the problem for me if it could replace nzbmatrix and such in my sickbeard ea :P