Delete local Time Machine snapshots / backups from macOS

If you need to free up some space and you are definitely sure that there could be nothing important / indispensable within your local Time Machine snapshots / backups, then issue the following command to regain the disk space consumed by them: for d in $(tmutil listlocalsnapshotdates | grep "-"); [...]

Install UniFi Controller on your Raspberry Pi

CloudKeys are nice – but if we already have a Raspberry lying around, why not use that to host the UniFi Controller? Here are the steps to do so. We’ll update the Raspbian installation, add the necessary packages (openjdk8) circumvent the slow startup time which occurs because of the lack [...]

Move Log files to RAM on your Raspberry

Save your SD card (or USB) and reduce I/O wear by using log2ram in your Raspberry install. Here are the steps to add the repository to your apt sources and install the necessary packages: echo "deb buster main" | sudo tee /etc/apt/sources.list.d/azlux.list wget -qO - | sudo apt-key [...]

QuickLook Plugin / .qlgenerator can’t be opened because Apple cannot check it for malicious software - fix locally

To remove the quarantine flag from an unnotarized QuickLook plugin – like at time of writing, QLStephen (“QLStephen.qlgenerator” can’t be opened because Apple cannot check it for malicious software.) – one can issue the following command to alleviate the issue, effectively marking the QLGenerator as safe: xattr -cr ~/Library/QuickLook/QLStephen.qlgenerator If [...]

WordPress error on image upload "Post-processing of the image failed likely because the server is busy or does not have enough resources"

This usually means that you don’t have the fcgid PHP module installed or enabled. To do this on Ubuntu Linux under Apache2, you need to do the following steps: 1. install fcgid sudo apt-get install libapache2-mod-fcgid 2. enable fcgid if the install doesn’t enable it a2enmod fcgid 3. install imagick [...]

Delete Bootcamp and other multiple partitions from external disk / hard drive / ssd under macOS

The built-in Disk Utility app is suprisingly negligent with external drives that have at least one non-HFS+/APFS partitions on it. Multiple partition external drive partitioning requires some extra steps to be done. We are going to destroy the complete partition map so that the drive can be reformatted into one [...]

Unifi Controller: Could not find Java SE runtime environment under macOS

Starting the Unifi Controller under recent macOS versions with OpenJDK installed can cause problems, such as one of the following warnings: Could not find a JRE. Will look for a JDK.ERROR: could not find Java SE runtime  I’m going to assume you have Adopt OpenJDK installed, preferably via Homebrew – [...]

Mac Batch Resize Images in macOS Terminal

We can use the built-in sips command to resize all files in a folder while keeping the aspect ratio intact. To resize all JPG files in the current folder, while maintaining aspect ratio and not letting either the height or width go above 1600 pixels, issue the following: sips -Z [...]

Disable FortiClient VPN autostart on login under macOS

Disabling the FortiClient VPN from starting automatically during user login is not currently possible from System Preferences > Users & Groups > Login Items like in most cases. Instead, FortiClient uses LaunchAgents to start itself – what we have to do is edit the following plist files with our text [...]

Clear Google Drive File Stream Cache under macOS on User Login - Delete/Empty the content_cache folder automatically

I’m in a hurry! TL;DR? Download and unzip this Automator script to your Home dir (or iCloud Drive)open System Preferences > Users & Groupsselect your user on the leftswitch to Login Items on the rightclick the “+” at the bottom of the listselect the Clear Google File Stream Cache script [...]

Xcode Duplicate Current Line Keyboard Shortcut

This is something that should have been implemented ages ago – but for some reason, it’s still not present by default. 1. Navigate to the following folder using Finder (CMD + Shift + G): /Applications/ 2. Open the following file in a text editor: IDETextKeyBindingSet.plist 3. Add these lines above [...]

Mount Remote FTP Server Folder as Local Directory on Linux / Ubuntu / Debian / Raspberry / Raspbian

Have a remote FTP server directory mounted locally is pretty convenient for cross-server copying. It could also come in handy if you would like to copy content from your NAS to say, and RGH/JTAG Xbox360 using the built-in FTP server of Phoenix or FSD FreeStyle Dashboard. 1. Install curlftpfs apt-get [...]

xcrun: error: SDK "iphoneos" cannot be located

Make sure that you have Command Line Tools installed with Xcode by running: xcode-select --install After that, issue the following to have it available systemwide: sudo xcode-select --switch /Applications/

Constant External USB Disk Activity Under macOS / OS X - list files being accessed

Plugging in an external hard drive usually results in Spotlight indexing the contents – or just upgrading the index that already exists. This can be avoided by excluding the hard drive from being indexed under System Preferences – Spotlight – Privacy if desired. But, most often than not, we actually [...]

Google Drive File Stream High CPU usage on Mac OS X / macOS

When installing Google Drive File Stream for macOS for the first time, you should see Loading your files within the app – along with the sudden realization that your fans spin up and something is running one core of your CPU at 100% load. Aside from Google constantly fixing bugs [...]

Install FFMPEG on macOS using Homebrew for x256/H.265/HEVC encoding

Consulting the official FFMPEG Compilation / Installation guide only tells us how to do a basic install of FFMPEG. For day to day encoding we would need some additional options enabled at compile time. Searching around lead me to a GitHub gist discussion where multiple users shared their then-current ways [...]

ERROR ITMS-90087: "Unsupported Architecture. Your executable contains unsupported architecture '[x86_64, i386]'."

This means it’s time to get rid of i386 code, presumably within one of your dylib files. Open a terminal and issue the following: lipo -remove i386 yourlib.dylib -o yourlib_fixed.dylib Now you can preferably delete the old dylib and rename to new one to match your old dylib’s name. Either [...]

Dolphin GameCube / Wii Emulator - compile the latest version under macOS / OSX 10.14 Mojave

There are many ways to do this, but for me none of them worked as most of the time I simply ended up with an app bundle that crashes on start. I’ve successfully built the latest Dolphin with these steps. First, make sure that you have Xcode installed (free download [...]

Karabiner-Elements: Right-Alt + j to í

A complex modification rule for Karabiner-Elements to change AltGr + j to í. Install Karabiner-Elements from here Click here to import the rule Alternatively, open Safari (or if that doesn’t work for some reason, then Finder and press Go -> Connect to Server) and paste this text into the location [...]

Disable iTunes Keyboard Shortcuts/Media Buttons on macOS

UPDATE FOR SIERRA 10.12.4 AND UP This only works on macOS versions prior to macOS Sierra 10.12.4 (16E195) as starting from this version it is necessary to disable the System Integrity Protection – this is not covered in this guide! Alternatively, you could rename the within the Applications folder which will [...]

Find and reattach a lost terminal screen session under Linux / Mac OS X

Running lengthy operations (such as remote sync, video compression) is preferred to be done in a screen session: among other things, it enables you to do something else while your commands run in the background. For the most part you can be fairly sure that you can attach to your [...]

Disable MobileBackups local Time Machine backups on Mac OS X

Being on the road (or just away from your Time Capsule) for longer periods of time may cause a surprising dent on your free disk space counter. As time marches on, those who have Time Machine enabled  will soon realize that something is eating away precious disk space. On Macs with [...]

Extract single file/directory from tar gz archive

Doing automated backups is a must for every sysadmin worth its’ salt. If you happen to administer a smaller pool of servers/hosts it is more than likely that you have your backups tarballed and stored somewhere relatively safe. Restoring from such a backup is an easy process, but what if [...]

VMware ESXi Copy VM from one Host to another without vCenter

There comes a time in every sysadmin’s life when a second Virtual Machine Center is added to the inventory of awesomeness and soon You’ll find yourself reevaluating your current setup from a load balancing poing of view. Either way, moving around virtual machines within the same environment is for the [...]

Google SMTP Error PTR 550-5.7.1 IPv6 - Fix for Postfix under Ubuntu Server

Having undelivered mails due to numerous errors is not nice – having all of our sent emails rejected by a particular host is nothing short of a nightmare. Google has a strict policy on deciding whether it would allow a mail to be delivered to one of its’ accounts or [...]

Shared Folder disappeared in Veertu - Windows 7 Fix

After a recent upgrade to the Veertu virtualization software, many users – including myself – have been surprised to find out that the Shared Folder with the Mac OS X host has all but disappeared into oblivion, re-installing the Guest Additions did not at all resolve the issue. Browsing thru [...]

How to hide terminal command output messages under ubuntu / debian linux

There are times when we do not want our scripts or programs to outputy any kind of message to the standard output – like for instance if we have multiple scripts in our crontabs. If you didn’t have your crontab configured in such a way that it automatically shoots you [...]

Ubuntu LTS 14.04 Server Router From Scratch

Building your very own Ubuntu Server from Scratch is as great way to get a grasp at how things work under the hood, not to mention you’ll end up with a router that does what it is told to do and nothing more. I’m going to assume you have a [...]

Measure network speed, throughput performance and bandwidth between devices

It is always good to know just how much TCP / UDP packets can we squeeze out from our network interfaces. Be it that we are building our very own router or just plain testing out our network environment. Usually there comes a time when the question pops up in [...]

MikroTik RouterOS Hairpin NAT - Public WAN Port Forward From LAN

Switching from a cheaper brand router to something classier can cause a lot of surprises: from broader set of functions to unforeseen security options. One of which is the fact that trying to connect to one of the ports of the public WAN IP address of the router will most [...]

Upgrade rsync on Mac OS X

By default, Apple decided to ship version 2.6.9 of rsync with Mac OS X 10.11 El Capitan. For the most part it gets the job done, however, not so long ago I came across the problem of having to sync directories between remote hosts that have whitespaces in their names. [...]

Slow SSH Login in Debian / Ubuntu Linux

Generally speaking, even the password prompt should not take a lot of time (more than a few seconds) to pop up during the initial connection state. However, leaving parts of the SSH daemon unconfigured can lead to communication mismatch and timeout troubles under the hood – luckily, two lines of configuration [...]

RTNETLINK answers: File exists

Editing config file for the network interfaces in a breeze – unless you make all the necessary edits, save then quit editing, restart your networking and get utterly mortified by the horror of the fact that the interface you’ve just edited would not allow itself to be brought up to [...]

Ubuntu Server LTS restart networking

Those of you who have been using service networking restart to re-cycle your network interfaces will surely be surprised, when the command prompt spits back an error instead of doing what it is told to. As it turns out I have faced a similar situation, to which the only remedy was to [...]

Ubuntu Linux AIDE Setup - Advanced Intrusion Detection Environment

Having anti-virus software and a rigorous firewall as your first line of defense is considered a bare necessity nowadays. But what happens when somehow the malicious code or intent somehow gets past your protection? That is where an Intrusion Detection System (IDS) comes into play. AIDE is one such tool [...]

Remove Xcode Junk from Mac OS X

Oftentimes we find ourselves in dire need of some extra disk space. Given the chance that you do a lot of iOS / Mac OS / WatchOS development some temporary junk can pile up over time – and given the size of your projects, it can eat away a considerable [...]

Disable and Remove Windows 10 Notification Icon

Open Control Panel, go to Windows Update and click on Change Settings on the left pane. Now change the option in the drop-down list from “Install updates automatically (recommended)” to a more favorable “Check for updates but let me choose whether to download and install them” After that is done, click the Installed Updates link [...]

Ubuntu VPS UTF-8 locale error

Setting up a VPS in the cloud is the current de facto method of launching services for startups and bigger companies alike. Supposedly, when someone would like to extend the default system locale it’s only a matter of putting the correct values within the correspondent user’s .bashrc file and you [...]

Enable built-in FTP server in Mac OS X Yosemite / El Capitan / Sierra

Open up a Terminal and paste in the following commands to enable or disable the built-in FTP server. To turn on the FTP server, paste this into the command prompt: sudo -s launchctl load -w /System/Library/LaunchDaemons/ftp.plist To turn off the FTP server, issue the following command: sudo -s launchctl unload [...]

Convert Videos to iPod / iPad / iPhone with FFmpeg under Ubuntu or Mac OS X

We’ll pretend you have ffmpeg up and running, with the necessary build options – for more info on that, refer to the FFmpeg Compilation Guide. To convert to an iPod nano with a max screen size of 320×180, issue the following, replacing INPUT.AVI and OUTPUT.MP4 to your desired filename (but [...]

Converting/Encoding x265 under Mac OS X with FFmpeg

Suppose that we have our brew up and running and we’d like to do some video conversion, namely something to x265. To do this, first it is advisable to install ffmpeg using brew by issuing the following command: brew install ffmpeg --with-faac --with-fdk-aac --with-x265 Should this not work for whatever [...]

Grep whole directory recursively by file extension only

Using grep to scan thru a whole directory recursively is done with: grep -R 'string' dir/ In addition, you can also tell grep to only scan files that have a certain extension (or pattern, for that matter): grep -R 'string' --include *.cpp dir/  

Crontab / User cron file location in Ubuntu

Usually you shouldn’t edit these by hand, but given the off-chance you’d want to, cd yourself all the way to: /var/spool/cron/crontabs If per chance you’d play it by the book, editing would be done by issuing this (per user crontab): crontab -e

See Mac OS X FileVault 2 Encryption Progress in Terminal / CLI

Pop open your, type in the following and hit Return: diskutil cs list |grep -e 'Conversion Progress' Be cautious as between the pipe sign and ‘grep’ there is no space!  

Find and Block Abusive IP Addresses on Ubuntu Server

The Issue Your server has an extremely high workload in comparison to the usual CPU load, it generally feels less- or even unresponsive and if you have any intrusion detection configured, then it is sending alerts of failed login attempts. The Cause Having your server constantly bombarded by SQL Injection [...]

OpenWRT Wi-Fi Repeater / Wireless Bridge

Let us have a nice Wi-Fi range extander be born from the ashes of a long discarded router now, shall we? I’m going to assume that you’ve successfully: installed OpenWRT on your router of choice had accessed the admin page have your radio0 interface up and running have radio0 is [...]

Sublime Text C++/CPP Build System under MacOSX Yosemite

Using the ever-so-wonderful Sublime Text as your primary editor is a joy in itself, however, building your .cpp files under OS X with it was something I wasn’t able to do out-of-the-box. Here are the steps that would enable you start compiling in no time – and as always, you [...]

Transmission on Ubuntu Server 14.04 with Flexget - Python error fix included!

First, let’s install Transmission and set up some directories – issue these commands (remember to substitute user with your desired username that runs transmission) sudo apt-get install python-software-properties sudo add-apt-repository ppa:transmissionbt/ppa sudo apt-get update sudo apt-get install transmission-cli transmission-common transmission-daemon mkdir ~/Downloads mkdir ~/Downloads/Completed mkdir ~/Downloads/Incomplete mkdir ~/Downloads/Torrents sudo usermod [...]

Ubuntu Command Line - How To Connect To Wi-Fi WPA/WPA2

  First and foremost, you will need to have wpa-supplicant installed, otherwise it won’t work. Ubuntu does installs this be default, but to be on the safe side you can install the required package with this command:   sudo apt-get install wpasupplicant   So far so good, next up we’ll [...]

BizHub 250/350 Duplex / Double Sided printing on Mac OS X

At the Printing options select Finishing > and tick in Duplex.

Problem with

Ever encountered the following unpleasant error message under Debian or Ubuntu?   error while loading shared libraries: cannot open shared object file: No such file or directory   Fret not, as the answer is dead simple! Log in to your server and issue the following command (as root / [...]

Remove file protection from copied files under Mac OS X

Copying files from read-only media or an external drive (or even a network share) can cause them to become “protected” upon being written to disk under OS X. Problem is, when the urge to modify/rename the rises, You’ll end up getting an error message stating that it sure is protected [...]

VNC from the Login Screen: accessing the actual Ubuntu X Display shown on the monitor

Issue the following command with elevated rights or as root: apt-get install x11vnc   Create the file /etc/init/x11vnc.conf with your favourite text editor and write this into it: start on login-session-start script x11vnc -xkb -noxrecord -noxfixes -noxdamage -display :0 -auth /var/run/lightdm/root/:0 -forever -bg -o /var/log/x11vnc.log end script   Sources are here [...]

ProFTPd error in Ubuntu 12.04 - solution!

By default, the installed package refused to start, because of missing files. So I had to do the following to resolve the missing links:   First, create a symbolic link to the already existing file:  ln -s ‘/usr/sbin/proftpd’ ‘/usr/sbin/in.ftpd’   Second, let’s tell inetd where to look for the service program, [...]

Scrolling within Mac OS X Terminal app

Ever wanted to scroll pushing Shift + Page Up/Down within Here is how to do it, check MouseTerm!    

Updating Darwin Ports / MacPorts on OSX Mountain Lion

  1. Let’s update the currently available application package list /opt/local/bin/port -d selfupdate   2. Darwin ports should be updated as well: /opt/local/bin/port upgrade outdated    

Coda 2 is not saving passwords for FTP servers

The gurus over Panic have made Coda 2 one of the very best development tools for Mac OS X, stuffed with all the features one could only hope for. However, under OS X 10.8 (and prior) some concerns were raised in relation with the way Coda 2 handles password saving. [...]

How to close open SAMBA / Windows Shared Folder connections effectively

Since the concept of mounting a file system had risen, nearly every type of media and storage device can be accessed from practically everywhere in the world. Unix / Linux based systems are exceptionally good at handling multiple connections to the same host with different user / pass login credentials. [...]

Excel 2007 / 2012 - Open two spreadsheets in two separate windows

Ever wanted to open a spreadsheet like you did before Excel 2007? Now it is possible and it comes in handy if you need to compare documents side-by-side. Start Regedit (WinKey + R, type in “regedit” without the quotation marks and hit Enter)Navigate to: HKEY_CLASSES_ROOT/Excel.Sheet.8/shell/Open/command Double Click on (Default) and [...]

Android - the Missing Manual

1.Resource specification should not include the file extension! Example: “drawable/icon.png” should be referenced as “@drawable/icon”  

Android SDK Error under Ubuntu 12.04 "Precise Pangolin" 64-bit - AVD Emulator Failed to load

Doing some Android bloodshedding with the good ol’ Tux gives an undescribable feel in elaborating your carefully crafted lines of code…so does an error message which pops it’s head up if you’ve recently upgraded to the latest LTS release of Ubuntu. Precisely, test-driving your code on an Android Vitual Device [...]

Remove unused kernel header files in Ubuntu

Straightforward, constant updating is the key to have a fresh and bleeding edge Ubuntu system. However, for those of you who are strapped for disk space – for instance if you are hosting multiple operating systems on one drive – “useless” files can eat up quite a big chunck of [...]

Modifying Debian/Ubuntu Startup Programs from CLI / Terminal

Ever wanted to modify your list of custom-added applications from perhaps a remotely logged in shell? Well, there is really not much to it, as aside from the base “skeleton” startup programs, Debian / Ubuntu stores the custom upstart jobs on a per user basis. These elements reside in the [...]

VNC with SSH-tunneling over PuTTY

Having SSH is totally great to administer your servers and such, but if you ever face a situation that absolutely requires a few clicks to be made on the GUI, then at best you are screwed. For the technically savvy this might not mean an obstacle at all – but [...]

Ubuntu Server 12.04 LTS USB install error, problem reading disc

Making a bootable USB drive off of Ubuntu Server 12.04 LTS is fairly easy and there are even a lot of graphical tools available to do it. However, there is one silly mistake that slips in during the process of decompression, namely one of the files receives a wrong extension [...]

Bash Completion on Ubuntu 12.04 LTS - hit TAB to complete your command

As many of you already know, the Linux/Unix command line interface has a neat little feature, that greatly enhances the speed of executing commands (and finding files) by reducing the time it takes for one to type in the command. What it actually looks like is fairly simple, for example [...]

Shutdown error in Ubuntu 12.04 LTS Server edition

Many of us have experienced that after updating to Ubuntu Server 12.04 LTS, the halt command seems to do partial job: it really does halt the system, but it does not effectively power it down. Numerous fixes have been issued forums-wide, an official one is still in the works, as [...]

Upgrading Ubuntu 12.04 LTS upgrade from console/terminal

Upgrading our Ubuntu Linux installtion (be it 10.04, 10.10, 11.04 or 11.10) can be fairly easy with the aid of the graphical update manager tool. However, in some cases the CLI (command line interface) is the only viable option for us to make a full distributional upgrade. To do this, [...]

Regaining user access after restoring a PostgreSQL backup made with dumpall

Usual, frequent backups – containing just about everything – are highly favoured by a wide-range of sysadmins. In some scenarios, it is more than enough to just issue a full backup (including the kitchen sink) then to make selective and separate dumps from parts of the database, based on the [...]

WPA/WPA2 WiFi password cracking - Reaver on Ubuntu 12.04 LTS

A short, straightforward guide to install and set up Reaver on Ubuntu 12.04 LTS – found and archived from this website, should it be moved or otherwise become unreachable. On with the necessary steps with minimal comments: 1. Download Reaver, compile and install it: # wget # tar -xzvf reaver-1.4.tar.gz [...]

MikroTik RouterOS Password Recovery

Forgetting a long – usually pwgen generated – password can truly be a pain. There are numerous methods of circumventing the password authentication protection, what we will be dealing with today is extracting the hashed password from a MikroTik backup file. First, download the required .deb packages for your Debian/Ubuntu [...]