Auto update Pi-hole lists

One way of updating the lists on a Pi-hole system is to edit the /etc/cron.d/pihole file.

However there is another way. You can use the php script “/home/pi/” below

#!/usr/bin/env python
# run this directly on the pihole in cron:
# 00 07 * * * /usr/bin/python3 /home/pi/

import json
import urllib
import csv
from time import strftime
from urllib.request import urlopen
from subprocess import call

# set date
tdate = strftime("%d.%m.%Y")
# dns requests and blocked domains
ddata = urlopen('').read()
dbody = ddata.decode('utf-8')
ddata = json.loads(dbody)
queries = ddata['dns_queries_today']
blocked = ddata['ads_blocked_today']

# before update
bdata = urlopen('').read()
bbody = bdata.decode('utf-8')
bdata = json.loads(bbody)
before = bdata['domains_being_blocked']

# listupdate
call(["/usr/local/bin/pihole", "-g"])

# after update
adata = urlopen('').read()
abody = adata.decode('utf-8')
adata = json.loads(abody)
after = adata['domains_being_blocked']
domains_change = after - before

# append csv
outrow = [tdate,queries,blocked,before,after,domains_change]
with open(r'/home/pi/domainchange.csv', 'a') as f:
writer = csv.writer(f)

Don´t forget to add the script to the crontab (crontab -e).

Visitor Score
[Total: 0 Average: 0]

Prep Raspberry for Pi-hole

Raspberry Pi is great for filtering adds (and more). Build your Pi-hole on a Raspberry Pi !

First purchase your Raspberry Pi (starterkit with all you need or grab the stuff you need yourselves).

During the first boot of Raspbian (the operating system), answer all questions (defaults are OK in most cases).

Now launch the settings menu and set a fixed IP address and enable SSH

Update all packages on you Raspberry (from a terminal) :

$ sudo apt-get update && dist-upgrade or sudo apt-get update && sudo apt-get upgrade

open a terminal and install “Webmin” for easy maintenance :

$ sudo apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl apt-show-versions python
$ wget -qO- | sudo apt-key add
$ sudo add-apt-repository "deb sarge contrib"
$ sudo apt update
$ sudo apt -y install webmin

Install Pi-hole (still in the terminal) :

$ curl -sSL | bash

answer all questions (again defaults are OK in most cases).


Visitor Score
[Total: 0 Average: 0]

Kodi TVAddons

Kodi is an open source media player software developed by the XBMC Foundation. It is now on it’s fifteenth version and works on a wide variety of platforms and devices ranging from home computers, to tablets and mobile phones, to set top boxes.

Once you’ve installed Kodi, you’ll need to enable third party add-ons in order to gain access to all that endless content you want to watch.
Instead of searching for the addons manually and then install them one by one, there is an easier solution :

There are a few different ways to install add-ons to your Kodi setup, but first you’ll need to configure the Fusion Installer server onto your device. Once that’s done, go ahead and use the Config Wizard (best) or the Addon Installer tool to get all the goodies.

Enjoy, greetz M.

Visitor Score
[Total: 0 Average: 0]

How to change soft returns with hard returns in Microsoft-Word and Libre Office Writer

How to change soft returns with hard returns using the Microsoft-Word find-and-replace function.
How do I do this?
Open the find-and-replace window (CTRL-H) and Find ^l (lower case L) and Replace with ^p (lower case P).

When using Libre Office Writer :

Open the find-and-replace window (CTRL-H) and Find \n (lower case N) and Replace with \n (lower case n). Under More Options check Regular Expressions

I know, both parameters are the same ! Don’t ask me why, but it works ….

Easy as that ! Greetz, M.

Visitor Score
[Total: 0 Average: 0]

The promised free Windows 10 upgrade can become a real disappointment

So Microsoft got you really exited about the free Windows 10 upgrade. Unfortunately not all systems are able to run the new Windows 10 OS, even if the Windows 10 upgrade is presented.
Here’s what Microsoft says you need to run Windows 10 :

  • Processor: 1 GHz or faster
  • RAM: 1 GB for 32-bit or 2 GB for 64-bit
  • Free hard disk space: 16 GB for 32-bit or 20 GB for 64-bit
  • Graphics card: Microsoft DirectX 9 graphics device with WDDM driver
  • A Microsoft account and Internet access

So in order to be able to run Windows 10 (or Windows 8/8.1), you need a processor that supports PAE, NX, and SSE2. Without this, your Windows 10 fun comes to an end.

Now if you’re the sort of person who is a walking encyclopedia of tech trivia, then you might notice how these specs are the same as those for Windows 7. But there is one gotcha that you need to be aware of, and this only becomes apparent if you pull up the specs for Windows 8/8.1 and look closer at the processor specs:

  • Processor: 1 gigahertz (GHz) or faster with support for PAE, NX, and SSE2

Microsoft offers a handy primer on what these mean.

  • PAE gives 32-bit processors the ability to use more than 4 GB of physical memory on capable versions of Windows, and is a prerequisite for NX.
  • NX helps your processor guard the PC from attacks by malicious software.
  • SSE2 is a standard instruction set on processors that is increasingly used by third-party apps and drivers.

So, how can you tell if your processor supports all of this? There are a few ways:

  • Download and run the Windows 8/8.1 Upgrade Assistant. If your hardware is not up to spec, it’ll tell you, saving you gigabytes of downloads.
  • Try installing Windows 8/8.1. If it won’t work, the installer will tell you before you wade out beyond your depth.
  • Start the Windows 10 upgrade. The Assistant will check your system and tell you if the system will run Windows 10.
  • Download and run a handy utility called CPU-Z (portable version). Look under Instructions and if you see SSE2, EM64T (indicates the processor has support for PAE) and either VT-d or VT-x (which is what’s needed for NX support) then you’re ready to rock.
  • Manually check out your CPU by wading through this list. This will tell you directly if the CPU supports NX, and it will be listed as "NX / XD / Execute disable bit".

NX can be a pain in the behind because while your processor might support it, it could be disabled in the system BIOS, which then means having to dig around looking for the on switch.

To install a 64-bit version of Windows 8.1 (not Windows 8) on a 64-bit PC, your processor also needs to support CMPXCHG16b(which also, annoyingly, needs motherboard support, so it can be hard to test for), PrefetchW, and LAHF/SAHF, which adds more confusion. Fortunately, most people will have this already.

If you’re running Windows 8/8.1 then you’re probably good to go. If you’re not then the installer will tell you. Beyond that, the older your PC is, the more likely you are to be outta luck.

Se be prepared and don’t be disappointed when your upgrade to Windows 10 fails !

Greetz, M.

Visitor Score
[Total: 0 Average: 0]

How do I remove old kernel versions to clean up the boot menu

When running a Ubuntu instance with limited disc space, the /boot can get filled with old (obsolete) kernels. If you run out of disk space on /boot, this is hou to clean up space.

First make sure there is still about 20 percent of disk space left on /boot by removing old kernel files (pick the large ones, but don’t delete the files with the highest kernel version !!)

If needed, fix any pending updates :
sudo apt-get install -f

Now run this command to “cleanup” old kernel versions :
dpkg –list|grep linux-image|awk ‘{print $2}’|sort -V|sed -n ‘/’`uname -r`’/q;p’|xargs sudo apt-get -y purge

Only uname -r is between quotes on ~ key, rest are regular single quotes

greetz, M.

Visitor Score
[Total: 0 Average: 0]

Force Windows 7, 8, or 10 to Boot Into Safe Mode Without Using the F8 Key

So you are reading instructions on some article that tells you to reboot into Safe mode. You ask how you do that, and are told to use the F8 key when the computer boots up. But you just can’t seem to get the F8 key to work… so how do you boot into Safe mode?

There’s an option in the well-known System Configuration utility that will let you force Windows to always boot into Safe mode… until you turn the option off.
Force Windows to Boot into Safe Mode

Open up the start menu search or run box, and type in msconfig and hit the enter key. This should work in any version of Windows, including Windows 8 or 10. You can also use WIN + R to open the Run box and type it in there.

Select the Boot tab, and then check the box for “Safe boot” and make sure the radio button below is set to “Minimal”.

Once you hit the OK button you’ll be asked if you want to Restart now or wait until later. Either way, the next boot will take you into safe mode.

Once you restart, you’ll realize that you are in Safe Mode because it not only places that text in the four corners of the screen, but it even opens up the safe mode page from the help file in Windows 7 or Vista.

Once you are done fixing whatever you were working on, you’ll probably want to turn safe mode off and go back to normal mode. Just open up msconfig the same way as above, and then on the Boot tab you’ll uncheck the “Safe boot” checkbox.

So don’t forget to turn Safe Mode Back Off !!!!

This method especially helps if you need to repeatedly boot into Safe mode.

Greetz, M.

Visitor Score
[Total: 0 Average: 0]

USB Rubber Ducky

The Duck is a USB thumb-drive lookalike with a secret — the hardware is really a micro-controller with a microSD Card interface.  The device can act as any kind of USB slave, with a program or script fed to it via the SD card.  The default personality for the Rubber Duck is a a USB keyboard.  Plug it in, and it will type keystrokes generated via a script file.

The Duck is one of those hacking tools with both good and evil uses.  On the ‘good’ side, it can be used for automatic entry of complex commands in an environment where centralized computer management is difficult.

On the evil side, it can be used to immediately pop up a command shell and type malicious commands, execute scripts (e.g. powershell scripts) and install and execute software (bypassing UELA on Windows). There are lots of scripts available on the net, so using them is quite simple. It’s even possible to add a few lines to your script to “see” if the new “keyboard” is detected by the OS and keyboard input (actually next script lines) are accepted by the OS.

Keystrokes themselves can be pretty dangerous, beyond just using built-in commands.  I’m finding the Duck particularly interesting because it bypasses many kinds of protection: USB Mass Storage can be disabled, Autorun can be disabled, and the Duck will still work.  Who locks their machine down enough to prevent a new keyboard from being plugged in?  I’m also becoming curious about Host OS fingerprinting: could a USB Slave device such as the Rubber Duck determine what kind of host it’s plugged into, based on the USB setup and queries it receives?  If so, the Duck could be programmed to be a universal system hacker, with separate payloads for Windows, Linux, Solaris, etc, running the script based on the system it was plugged into.

Last but not least there are dozens of pages describing how to build your own “Rubber Ducky” USB device if you have a USB stick with the right NAND chipset.

Keep this in mind the next time you find an USB stick outside and think about attaching it to your PC to see what’s on it …

Regards, M.

Visitor Score
[Total: 0 Average: 0]

Smart TV or media streamer?

All smart TVs have streaming apps, like Netflix, Amazon Instant Video, Youtube, and so on. Media streamers are nothing but streaming apps. Sure it’s convenient to use your TV’s built-in services, but are they the best experience?

Probably not, actually. More to the point, is it worth getting a media streamer if you already have a smart TV? Maybe…

Behold, the pros and cons of TV apps and media streamers.

First, some terminology.

What is a smart TV ?

A smart TV, sometimes referred to as connected TV or hybrid TV, is a television set or set-top box with integrated Internet and Web 2.0 features, and is an example of technological convergence between computers and television sets and set-top boxes. Besides the traditional functions of television sets and set-top boxes provided through traditional broadcasting media, these devices can also provide Internet TV, online interactive media, over-the-top content, as well as on-demand streaming media, and home networking access.

Smart TV should not to be confused with Internet TV, IPTV or with Web TV. Internet TV refers to the receiving television content over internet instead of traditional systems (terrestrial, cable and satellite) (although internet itself is received by these methods). Internet Protocol television (IPTV) is one of the emerging Internet television technology standards for use by television broadcasters. Web television is a term used for programs created by a wide variety of companies and individuals for broadcast on Internet TV.

In smart TVs, the operating system is preloaded or is available through set-top box. The software applications or apps can be preloaded into the device, or updated or installed on demand via an app store or app marketplace, in a similar manner to how the apps are integrated in modern smartphones.

The technology that enables smart TVs is also incorporated in external devices such as set-top boxes, Blu-ray players, game consoles, digital media players, hotel television systems, and other network connected interactive devices that utilize television type display outputs. These devices allow viewers to search, find and play videos, movies, photos and other content from the Web, on a cable TV channel, on a satellite TV channel, or on a local storage drive.

(Source :

What is a media streamer ?

Digital media players (DMP) are home entertainment consumer electronics devices that can connect to a home network to stream digital media (such as music, pictures, or video). They can stream files from a personal computer and network-attached storage or other networked media server to play back the media on a television or video projector for home cinema. Most digital media players utilize a 10-foot user interface, and many are navigated via a remote control.

Some digital media players also have Smart TV features, like allowing you to stream media from the internet or popular streaming services and online media sites like YouTube, Vimeo, Netflix, Hulu, Spotify, and Some other digital media players also allow you to playback locally stored content from a direct attached USB hard disk or even direct connect a Hard disk drive externally, or even internally in the digital media player via a Serial ATA (SATA) port, therefore these types of digital media player are sometimes referred to as HD Media Player or HDD Media Player if they can support to have a Hard Disk Drive installed inside.

Digital media players are also commonly referred to as a digital media extender, digital media streamer, digital media hub, digital media adapter, or digital media receiver (which should not be confused with AV Receiver that are also called Digital Media Renderer). Today the main difference between most modern “digital media players” and many modern set-top boxes (also known a set-top units) is that the set-top boxes generally contain at least one TV-tuner and are as such capable of receiving broadcasting signal (cable television, satellite television, and over-the-air television, or IPTV).

(Source :

Here’s a breakdown of the strengths and weaknesses of each.

Available content

Winner: Media streamer
Loser: Smart TV

If all you want is Netflix, everything streams Netflix. I think I’ve seen a toaster that did it. But beyond that, it’s a lot less certain. A vital component to any streaming device (TV or dedicated), is the ability to buy and rent current TV shows and movies. The two services with the most content in that regard are Amazon and Apple. No TV has iTunes (and please don’t mention the Apple Television vaporware), and not all of them have Amazon Instant Video. Google Play is a reasonable runner-up, but it still doesn’t have the breadth of content of Apple and Amazon. Vudu is cool, but primarily movies, and US-only. Sony’s Video Unlimited service is decent too, but not widely available either. The better media streamers, like Roku and Apple TV, have Amazon Instant Video (or iTunes), along with a lot of other content like HBO Go in the US or Sky’s Now TV in the UK. HBO Go is available on numerous streaming boxes, but the only smart TVs that have it are from Samsung. The Apple TV also has the added ability to easily stream music from your computer, which I use all the time. Other TVs and streamers can do this, but it’s not as smooth an experience. To me, just that fact is enough to justify the cost of a media streamer. If the point is to watch content, media streamers offer more content providers than any single television.

Ease of use

Tie, sort of

It’s hard to compare all TVs against all media streamers. The better streamers, like the Roku 3 and Apple TV, but also a whole lot of android based media streamers, are fast and easy to use. Everything is laid out well, and you can get to what you want quickly and simply. Even the Fire TV, despite its other issues, is easy to navigate and fast to use. Some TVs have decent menus for their streaming content… but most don’t. Worse, they’re often slow and clunky to use. So on that level, the better media streamers win. There is the added simplicity, however, of only having one remote with a smart TV. Most people don’t like an Ottoman of Remotes, and using just the TV’s apps could save you from having to buy a universal remote. Comparing the best media streamers against the worst smart TVs, it’s an easy win for the streamers. The lesser streamers against the better TVs, it’s more of a wash. Since the better streamers are barely any more expensive than the worst, generally I’d say this category is a win for streamers. But overall, I guess I have to concede a tie.


Winner: Media streamer
Loser: Smart TV

This one goes to streamers in a landslide. Over the years Roku and Apple TV have undergone numerous software updates to improve available apps and tweak the interface. Chromecast is another streaming platform that has evolved significantly since launch, improving mirroring, adding app compatibility and promising even more improvements as developers dig in. Amazon Fire TV promises more updates of its own, including adding more catalogs to its voice search, but remains stubbornly US-only for now. Then there’s the TVs. If you bought a smart TV a couple years ago chances are its interface, apps and capabilities, not to mention its response time, seem dated by comparison to a $99 box. Most smart TV platforms are updated only during the year they were launched, if then, and afterward age as quickly as any technology. One exception is Samsung’s Evolution Kit, but it costs twice as much as a Roku 3.

Picture quality


Generally, picture quality shouldn’t be an issue. If your TV’s internal scaler isn’t great, however, it’s possible the scaler inside a media streamer is better. This could mean Netflix et al will be sharper than when streamed internally from your TV. This is because, for the foreseeable future, most streaming content will be 720p. There are some 1080p and even 4K exceptions, but they’re still fairly rare. What has to happen is the TV or streaming box must upconvert the 720p to your TV’s 1080p (or 4K). How well this is done determines how detailed the image can look. If you do have a 4K TV, you will have to use your TV’s built-in Netflix app (above) to see 4K content from them. Remember, just because your TV’s Info button says “1080p” doesn’t mean that’s what the signal is from Netflix, that’s just what your TV is receiving from the media box. Check out What is upconverting? and Ultra HD 4K TV Cheat Sheet for more info.


Tie, sort of (again)

Generally speaking, a smart TV costs about $100, or around £80, more than a “dumb” TV. The better media streamers cost about the same. So technically it’s a wash. It’s not that simple, however. If you want to get a good, top-of-the-line TV, it’s going to have smart features built in, whether you want them or not. So if you want to add a media streamer, you’re going to be paying for the same apps (mostly, as mentioned above) twice.

Bottom line

That last part is the kicker. Most people are going to be faced with adding a media streamer to a TV that already has most of the streaming services. Looking at it that way, this becomes more complex than a simple tally of ties, wins, and losses.

The question really is whether a media streamer is worth $100, when you already have a smart TV? Personally, I’d say yes, and I hate recommending people spend more money than they need to. It comes down to Amazon and iTunes. Being able to watch just about any show or movie whenever you want is huge, and most smart TVs just don’t offer that ability. Many also have clunky, annoying interfaces, and they’re not updated frequently. Sure there are some exceptions, but having a good media streamer means you can ignore a smart TV’s apps, both when you’re shopping, and when you’ve got it home. That’s worth $100 to me, easily.

Greetz, M.

Visitor Score
[Total: 0 Average: 0]