Linux utilities

Ncdu – disk space analyzer. Shows sizes of folders and allows you to drill down into those folders to see which files take up the most space. 

Progress – shows progress (percentage of file copied) of mv, cp operations that are ongoing. Just launch another terminal and run progress as root. 


Nginx PHP configure

Install php7.0 and php7.0-fpm packages.

Edit the site’s config file. Uncomment the PHP lines already in there, but NOT the php7.0cgi lines.

Restart nginx. You’re done. 

If you need curl, the package is php7.0-curl

TUN/TAP error on Linux VPS (OpenVPN)

process started and then immediately exited: [‘Mon Mar 20 22:29:10 2017 ERROR: Cannot open TUN/TAP dev /dev/net/tun: No such file or directory (errno=2)’]
service failed to start or returned error status
the reason: if VPS is running on an OpenVZ platform, TUN/TAP needs to be enabled in the VPS provider’s web control panel. Then restart the server.

Remove BIOS hard drive password

When the BIOS prompts for the drive password, press escape to skip the dialog (so the drive stays locked).

Boot to Linux. Run sudo hdparm –security-disable [Password] /dev/[drive]

Run hdparm -I /dev/[drive] and the status should say not enabled.

Prosody xmpp chat server setup

install the package with apt

modify the config file to server’s domain name

open port 5222

if you want ssl, the certificates have to be readable by the prosody user. easy fix(but not the best) – copy them into the /etc/prosody folder. Then edit the two lines in the global section of the config file.

create user(s) (public registration is disabled by default) – run

prosodyctl adduser

prosodyctl can control the server.

that’s about it.

Modify HTML text box value and click button using a script

Get the element by looking at the page’s source (or right clicking the element and clicking Inspect) and finding the id=””

This will change the text box’s value:


This will click a button:


Bonus Autohotkey script:

SetTitleMatchMode, 2
WinActivate, Vantiv Integrated Payments
Send ^+j
Sleep 1000
Send document.getElementById(“ctl00_ContentPlaceHolder1_searchAccount”).value=”%clipboard%”
Send {Enter}
Sleep 500
Send document.getElementById(“ctl00_ContentPlaceHolder1_btnRunReport”).click()
Send {Enter}
Send ^+j

Blog at

Up ↑