firewalld – managing firewall from command line

In some ways, firewalld on systemd systems is easier to manage and configure than iptables.

Managing Firewalld and Configuring Rules

Now that we have firewalld running, we can get down to set the configuration. We can open ports, allow services, whitelist IPs for access, and more. In all of these examples, we include the –permanent flag. This is important to make sure a rule is saved even after you restart firewalld, or reboot the server. Once you’re done adding new rules, you need to reload the firewall to make the new rules active.

Add a Port for TCP or UDP

You do have to specify TCP or UDP and to open a port for both. You will need to add rules for each protocol.

Read More

How to install qbittorrent-nox [Note]

qBittorrent is a free, open-source, fast and lightweight P2P BitTorrent client written in C++ / Qt, available for Linux, FreeBSD, MacOS and Windows. qbittorrent-nox – bittorrent client based on libtorrent-rasterbar (without X support). I try to install on my Raspberry PI.

qBittorrent is included in the default Ubuntu software repository. You can easily install it by running the following command in a terminal window:

sudo apt install qbittorrent-nox
Read More

Install Samba on Raspberry PI

Samba is available in Raspbian’s standard software repositories. We’re going to update our repository index, make sure our operating system is fully updated, and install Samba using apt-get. Open a Terminal and type:

sudo apt update
sudo apt upgrade
sudo apt install samba samba-common-bin
Read More

Raspberry Pi Media Server – MiniDLNA

Before post, I wrote to you about how I tried to install Gerbera on a Raspberry pi. Now let’s try to install minidlna. Let’s do it.

First, I recommend updating and upgrading your raspberry pi. You can do this by using the following commands:

sudo apt update 
sudo apt upgrade

Once this is finished we can install the media server software. Use the next command to do this.

sudo apt install minidlna
Read More

How to I try to install Gerbera UPnP Server

Gerbera is a free open source, powerful, flexible and full-featured UPnP (Universal Plug and Play) media server. It comes with a simple and intuitive web user interface for easily configuring your web server.

We strongly advise using the packages provided by your distribution if available. Please see below for guides on how to install Gerbera on various distributions. I try to install to Ubuntu/Debian OS on Raspberry.

Read More

Securely Overwriting Free Space on Windows

When you delete a file from the recycle bin in Windows, rather than deleting the actual file, the space the file is occupying is simply marked as free so that another file can come and use those blocks on your hard drive. One way of making sure that your data is not recoverable is to simply overwrite all the free space with random data.

Read More

How to create a DDRescue Image and save space

As disk sizes explode, I’ve found myself having to mirror disks which I don’t have enough storage for. My tool of choice is ddrescue. However, it doesn’t support compression because it needs to be able to seek through the output as it rescues data. A solution I’ve found is to create a sparse file, format it btrfs, and mount it with the compression=lzo option. This allows ddrescue to operate normally, while giving me fast + decent compression.

Read More

Postfix – subject, from and to log

This is a little trick for Postfix, it lets you log the subject, from and to of all the emails postfix sends (or which pass through it if you run it as a relay). It comes in handy when you need to debug an email issue and need to confirm your mailserver has sent the message.

First create the file /etc/postfix/header_checks and insert this into it:

/^subject:/      WARN
/^to:/           WARN
/^from:/         WARN
/^Subject:/      WARN
/^To:/           WARN
/^From:/         WARN
Read More