Content nZEDb Self Hosted Ubuntu Ubuntu 16.04 Usenet

How to Set up nZEDb Usenet Indexer on Ubuntu 16.04/17.04

nzedb ubuntu 16.04

Beforehand we mentioned how to set up SABnzbd Usenet shopper on Ubuntu 16.04/17.04. This tutorial goes to present you ways to set up your personal nZEDb Usenet indexer on Ubuntu 16.04/17.04 to be able to discover content material on Usenet conveniently. nZEDb is a free and open-source (GPL-licensed) Usenet indexer. It’s a fork of NewzNab plus, which is closed-source and business Usenet indexer.

Why set up your personal Usenet indexer? There are a selection of causes:

  • It’s freed from cost.
  • You possibly can obtain as many NZB information as you want.
  • Limitless API calls.
  • Third-party Usenet indexers can disappear.
  • You don’t have to give your private info to anybody when utilizing your personal Usenet indexer.


So as to comply with this tutorial, you’ll need a Ubuntu 16.04/17.04 pc operating with LAMP or LEMP stack. In the event you haven’t already accomplished so, please take a look at one of many following tutorials.

As soon as LAMP or LEMP is put in, come again right here and skim on. You additionally want to have a Usenet account, the small print of which can want to be entered within the nZEDb net installer. Now comply with the directions under to set up nZEDb on Ubuntu 16.04/17.04.

Configuring MariaDB

Edit MariaDB server configuration file utilizing nano textual content editor.

sudo nano /and so on/mysql/mariadb.conf.d/50-server.cnf

Add the next strains within the [mysqld] part.

# configurations by nZEDb
innodb_file_per_table = 1
max_allowed_packet = 16M
group_concat_max_len = 8192

Save and shut the file. Then restart MariaDB for the modifications to take impact.

sudo systemctl restart mysql

Making a Database and Consumer in MariaDB

Log into MariaDB database server with the next command:

mysql -u root -p

Then create a database for nZEDb. This tutorial identify the database nzedb. You should use no matter identify you want.

create database nzedb;

Create the database consumer and grant this consumer all privileges on nzedb database. Exchange your-password together with your most popular password.

grant all privileges on nzedb.* to ‘nzedb’@’localhost’ recognized by ‘your-password’;

Additionally grant file permission to this consumer.

grant file on *.* TO ‘nzedb’@’localhost’;

Flush privileges and exit.

flush privileges;


Telling AppArmor to Ignore MariaDB

AppArmor is a Linux safety module enabled by default on Ubuntu. Nevertheless, it prevents nZEDb from utilizing the SQL’s LOAD DATA instructions. We’d like to inform AppArmor to ignore MariaDB utilizing the instructions under.

sudo apt set up apparmor-utils

sudo aa-complain /usr/sbin/mysqld

You may encounter the next error. It tells you that MariaDB isn’t restricted by AppArmor so simply go to the subsequent step.

ERROR: /and so on/apparmor.d/usr.sbin.mysqld incorporates no profile

Putting in Media Instruments

Run the next command.

sudo apt-get set up unrar p7zip-full mediainfo lame ffmpeg libav-tools

Subsequent, execute the next instructions to obtain, compile and set up yEnc, which speeds up header and message processing throughout indexing.

cd ~
mkdir yenc
cd yenc
tar xzf yydecode-Zero.2.10.tar.gz
cd yydecode-Zero.2.10
sudo apt set up gcc make
sudo make set up
cd ../..
rm -rf ~/yenc

Set up php-yenc extension for even quicker header and message processing.


sudo dpkg -i php7.Zero-yenc_1.three.0_amd64.deb

Putting in nZEDb

Make a listing for nZEDb.

sudo mkdir /var/www/nZEDb/

Set net server consumer (www-data) because the proprietor and grant write permission to www-data group.

sudo chown www-data:www-data /var/www/nZEDb -R
sudo chmod g+w /var/www/nZEDb/ -R

Add your consumer account to www-data group.

sudo adduser username www-data

Sign off and log again in for this alteration to take impact. Then run the next command to change the present login group to www-data.

newgrp www-data

We’ll use the git software to clone nZEDb repository from Github. So set up git on Ubuntu 16.04/17.04 with the next command.

sudo apt set up git

Change listing to /var/www/.

cd /var/www/

Then clone nZEDb repository.

git clone

Beneath /var/www/nZEDb/_install/ listing there’s a set up script for nZEDb. We’d like to copy it to /var/www/.

sudo cp /var/www/nZEDb/_install/set /var/www/

Add execute permission.

sudo chmod a+x /var/www/set

Earlier than operating this script, we’d like to set up some PHP extensions.

sudo apt set up php7.Zero-mcrypt php-imagick php-pear php7.Zero-curl php7.Zero-gd php7.Zero-json php7.Zero-dev php7.Zero-gd php7.Zero-mbstring php7.Zero-xml

Now be sure to are in /var/www/ listing and run the set up script.

cd /var/www/


In the course of the set up, Composer will set up all wanted PHP dependencies and you will have to enter your sudo password to set permissions. As soon as the script completed, we’d like to set up the online server. You should use both Apache or Nginx.

Setting up Apache Digital Host

Create a digital host in /and so forth/apache2/sites-available/ listing for nZEDb.

sudo nano /and so on/apache2/sites-available/nzedb.conf

Put the next textual content into the file. Substitute together with your Ubuntu server’s IP handle. You may as well use a website identify.

<VirtualHost *:80>
ServerAdmin [email protected] ServerName
DocumentRoot “/var/www/nZEDb/www”
LogLevel warn
ServerSignature Off
ErrorLog /var/log/apache2/error.log
<Listing “/var/www/nZEDb/www”>
Choices FollowSymLinks
AllowOverride All
Require all granted
Alias /covers /var/www/nZEDb/assets/covers

Save and shut the file. Then disable default digital host and allow the brand new digital host.

sudo a2dissite 000-default

sudo a2ensite nzedb.conf

Allow rewrite module.

sudo a2enmod rewrite

Reload Apache for the modifications to take impact.

sudo systemctl reload apache2

Now go to the next URL to entry nZEDb set up wizard.

your-server-ip/set up

or up

Setting up Nginx Server Block

Create a brand new server block file in /and so forth/nginx/conf.d/ listing for nZEDb.

sudo nano /and so forth/nginx/conf.d/nzedb.conf

Put the next textual content into the file. Exchange together with your Ubuntu server’s IP handle. You can too use a website identify.

pay attention 80;

access_log /var/log/nginx/nzedb-access.log;
error_log /var/log/nginx/nzedb-error.log;

root /var/www/nZEDb/www/;
index index.html index.htm index.php;

location ~* .(?:css|eot|gif|gz|ico|inc|jpe?g|js|ogg|oga|ogv|mp4|m4a|mp3|png|svg|ttf|txt|woff|xml)$
expires max;
add_header Pragma public;
add_header Cache-Management “public, must-revalidate, proxy-revalidate”;

location /
try_files $uri $uri/ @rewrites;

location ^~ /covers/
# That is the place the nZEDb covers folder must be in.
root /var/www/nZEDb/assets;

location @rewrites
rewrite ^/([^/.]+)/([^/]+)/([^/]+)/? /index.php?web page=$1&id=$2&subpage=$three final;
rewrite ^/([^/.]+)/([^/]+)/?$ /index.php?web page=$1&id=$2 final;
rewrite ^/([^/.]+)/?$ /index.php?web page=$1 final;

location /admin

location /set up

location ~ .php$
embrace /and so on/nginx/fastcgi_params;
fastcgi_param  SCRIPT_FILENAME    $request_filename;

# Uncomment the next line and remark the .sock line if you need to use TCP.
#fastcgi_pass 127.Zero.Zero.1:9000;
fastcgi_pass unix:/run/php/php7.Zero-fpm.sock;

# The subsequent two strains ought to go in your fastcgi_params
fastcgi_index index.php;

Save and shut the file. Subsequent, edit fastcgi_params file.

sudo nano /and so forth/nginx/fastcgi_params

Discover the next line.

fastcgi_param  REDIRECT_STATUS    200;

Remark out this line by placing # image at first.

#fastcgi_param  REDIRECT_STATUS    200;

Save and shut the file. Then check Nginx configuration.

sudo nginx -t

If the check is profitable, reload Nginx for the modifications to take impact.

sudo systemctl reload nginx

Now go to the next URL to entry nZEDb set up wizard.

your-server-ip/set up

or up

Ending the Set up in Net Browser

nzedb ubuntu 16.04


Click on the button on the backside.  In step one, the set up wizard checks your PHP extensions and settings.

install nZEDb ubuntu

We already put in all wanted PHP extensions earlier. For greatest efficiency, we additionally want to configure some PHP settings. In case you use Apache and the PHP7 module, then open the next file.

sudo nano /and so on/php/7.Zero/apache2/php.ini

Should you use Nginx and PHP-FPM, then open the next file.

sudo nano /and so on/php/7.Zero/fpm/php.ini

Change the worth of max_execution_time from 30 to 120.

max_execution_time = 120

Change the worth of memory_limit from 128M to 1024M.

memory_limit = 1024M

Outline a timezone like America/New_York. 

date.timezone = America/New_York

Save and shut the file. For those who use Apache and PHP7 module, you then want to reload Apache for the above modifications to take impact.

sudo systemctl reload apache2

When you use Nginx and PHP-FPM, you then want to reload PHP-FPM service for the above modifications to take impact.

sudo systemctl reload php7.Zero-fpm

Now reload nZEDb wizard and all standing must be OK. We will go to the 2nd step to set up the database. Enter the database particulars like so.

install nzedb ubuntu 16.04 server

Step three is to set up OpenSSL. we’d like to obtain a certificates bundle to confirm your Usenet supplier’s certificates.

sudo wget -P /and so on/ssl/certs/

Then make it readable by all customers.

sudo chmod 744 /and so forth/ssl/certs/cacert.pem

Now within the nZEDb setup wizard, enter the CA bundle path (/and so on/ssl/certs/cacert.pem) and certificates folder (/and so on/ssl/certs/). Be sure Confirm peer and Confirm host are checked. Do NOT examine Permit self-signed certificates.

nzedb openssl setup

In step four enter the server particulars of your Usenet supplier similar to giganews.

nzedb usenet indexer

Subsequent, set up an admin account for nZEDb.

nzedb install ubuntu

The ultimate step is about up file paths. You possibly can settle for default values.

nzedb file paths

Indexing Usenet Content material

As soon as the setup is full, it is possible for you to to go to nZEDb admin web page and comply with the directions there to activate some newsgroups, get newest headers of your chosen teams and replace releases.

To get newest headers, run

cd /var/www/nZEDb/misc/replace

php update_binaries.php

Then create releases and NZB information utilizing the next command.

cd /var/www/nZEDb/misc/replace/nix/multiprocessing

php releases.php

Importing PreDB into MariaDB Database

Import day by day dumps from nZEDb since 2014.

cd /var/www/nZEDb/cli

php knowledge/predb_import_daily_batch.php Zero native true

Fetching Film and TV Covers From IMDB, TMDB

To show covers on your nZEDb website, you want to get your personal API key from IMDB or TMDB. When you get your API key, go to nZEDb admin panel > website settings > edit website > third social gathering API keys and enter the API keys there.

I hope this tutorial helped you set up nZEDb Usenet indexer on Ubuntu 16.04/17.04.

Fee this tutorial

[Total: 20 Average: 3.7]

(perform(d, s, id)
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); = id;
js.src = “//”;
fjs.parentNode.insertBefore(js, fjs);
(doc, ‘script’, ‘facebook-jssdk’));