ASCII Flowcharts

You can generate this:

Screen Shot 2016-04-22 at 11.59.58 PM

From this:

Screen Shot 2016-04-22 at 11.59.18 PM.png

But create it visually, by using this (

Screen Shot 2016-04-23 at 12.03.03 AM.png

The Java based tool that generates the bitmap image from the ASCII graph is called DITAA (DIagrams Through Ascii Art) (

I personally use the ditaa plugin for Dokuwiki this to embed flowchart diagrams into my Dokuwiki hosted documentation. Dokuwiki is a decently powerful wiki software similar to Mediawiki, etc. One major difference is that it uses flat files instead of an RDBMS. You can use either the flat file standard setup or the Git Backed plugin to have it as part of the SCM. Makes for much easier management and automatic documentation generation!

Screen Shot 2016-04-23 at 12.07.01 AM.png



Jenkins – Matrix access control, Active Directory, and Audit Compliance Logging

For Jenkins 1.x (tested with 1.656)

Jenkins and plugins provide a pretty good way to have granular access control to the system and individual projects.

This setup will allow you to:

  • Log in via an Active Directory user (individual or member of an AD group)
  • Granular access and visibility control to projects, Jenkins system, and more
  • ISO27k/ITHC compliant audit logging to syslog server
    • A copy of every change made and of the system configuration will be logged with the job config history plugin

You can download Jenkins from here:

I recommend adding the Yum/Apt repository entries to the OS, this will help with keeping Jenkins updated.

Install the following plugins:

You can install them via the UI via the Manage Jenkins -> Manage Plugins option, or copy the downloaded hpi files into the Jenkins plugins directory and restart the service.


Active Directory

Manage Jenkins -> Configure Global Security -> Access Control -> Security Realm -> Active Directory -> Domain Name

Configure the base domain name. For example – Hitting Test should result in a Success message. If it doesn’t, you may have to configure more settings under Advanced.

Manage Jenkins -> Configure Global Security -> Access Control -> Authorization -> Project-based Matrix Authorization Strategy

Under user/group to add, enter the name of the AD user or group you want to control access for. The domain prefix is not required.

From here, you can also assign permissions to specific items such as the ability to Run, and View a job. Anyone with the Administer permission will have the ability to see all jobs and do anything in the environment. It’s recommended you have a user in here with this permission that is tested before you remove the anonymous access rights.

That’s it! You should be able to log into Jenkins with the domain username and password (no prefix or SPN form required).

Within a Jenkins job, you can now enable Project-based security and then add the AD group or usernames to limit visibility/control to specific groups or users.

Audit Trail

If you’re in an environment where you need or want to have a reliable audit trail for compliance reasons, then you’re likely using Redhat or Centos (selinux!). The audit trail plugin can provide a similar audit trail output to a file or syslog server.

Manage Jenkins -> Configure System -> Audit Trail

Here is where to add logger. If you want to test it, add a Syslog server logger and write to localhost port 514. The audit trail will likely show up in /var/log/messages. If you’re using rsyslog server, adding in a config to /etc/rsyslog.d/jenkins_audit.conf will provide advanced capabilities to separate out the log from the main log.

I prefer using the syslog server output, and then chaining syslog out to Logstash for ElasticSearch logging.

Job Config History

This plugin adds exact tracking of what the config changes are. It will maintain version control for system config and job configs. The audit trail is good to tell you what was modified and who modified it, this will keep track of what the changes were.

System configuration tracking is not enabled by default, and you can only restore previous Job configuration, not system (however you can see system changes).


Linux, MySQL

How to restore debian-sys-maint MySQL Maria user

I had an issue where I wiped this user out accidentally in a galera cluster on Ubuntu 14.04. This is how to add ‘debian-sys-maint’@’localhost’ user back into your MySQL server and then enjoy all the ‘benefits’ once more..

You can then verify the user with SELECT * from mysql.user\G

Make sure that the password in /etc/mysql/debian.conf matches the password below as THE_PASSWORD.

use mysql;
INSERT INTO `user` (
Hardware, HomeLab, Linux

LXLE on 2007 Sony Vaio VGN-TZ170N

The laptop and the OS

I have an old beat up but super nice back-in-the-day Sony Vaio VGN-TZ170N that has been sitting in a drawer for a few years. This thing was pretty much a flagship machine back when it was launched in 2007, it carried an MSRP of $2,399.99.

I figure that since I never get rid of anything and living in San Francisco means that space (for normal people) is a luxury that we don’t have (let’s say family pressure is the driver), it’s time to sell this (at least try to) to someone who will appreciate it more than me.

Here is the eBay link:

Here’s a quick rundown of the machine:

  • CPU: Intel Core 2 Duo U7500 (1.06GHz) x64
  • Screen: 11.1″ WXGA (1366×768) XBRITE-HiColor (wat)
  • RAM: 2GB DDR2
  • Storage: 100 GB PATA 4200 RPM (1.8″ HDD, I believe!)
  • Optical: Built in DVD-RW drive!
  • GFX: Intel GMA950
  • Chipset: Mobile Intel 945GMS Express.
  • VRAM: Shared
  • Comms: Modem (v92), gigabit LAN, wireless LAN (Intel PRO 4965AGN), bluetooth, i400 firewire, 2 USB, 1 VGA, 1 docking conector, 1 headphone, 1 microphone
  • Expansion: 1x ExpressCard /34 slot
  • Built in webcam, and SD (plus Sony memory stick) card reader, fingerprint sensor.
  • Weight: 2.7 lbs
  • Dimensions: 10.9″ x 7.8″ x 0.8-1.17″ (this thing is SMALL – unbelievable how much is packed into it, even today never mind 2007).
  • Windows Vista Business COA on the underside.

Looks like you can even pick up a replacement (or additional 6 cell battery for $22 now.
While the RAM slot is accessible from the underside, it doesn’t look possible to upgrade it beyond the 2GB limit (maybe there is a 4G DDR2 SODIMM that would work? I don’t have one to try).

The revival?

First, I grabbed a copy of Vista Business and installed it via the internal optical drive (nice!). This took *forever*, and was over 4 CDs. Once I got into Windows after waiting about 2 days to install Windows updates, I then went on a quest to kill all the background processes that jam the CPU at 100%.

End result? Machine back in the drawer for another 2 years.

Lightweight Linux

I knew that there were various distributions of Linux that are aimed at low spec, or low performance systems. Since I’ve always been an Ubuntu guy, I decided to start there. The aim of this post isn’t to review the top options of lightweight Linux – I simply don’t have enough time. I can say that at some point I must have installed Kubuntu 14.04, I powered it up, there it was – works great. Uses a bit too much RAM for my liking (about half gone at boot), I started looking into other options to prep this for eBay.

The machine’s hard drive is pretty slow, and I’m also burning these to CD, so I can’t really be assed spending a long time trying them all out. Here’s a non-scientific conclusion of what I considered over the course of an hour or two:


I did look at Lubuntu as a more lightweight replacement for Kubuntu, and that’s what started this whole thing..

Super lightweight and looks ideal for purpose. However, the choice of applications preinstalled are typically considered lighter versions. For example, no LibreOffice.

Generally, the consensus seems to be that it feels a bit too lightweight or barebones. This doesn’t freak me out, as I’d install what I want to, but for eBay purposes, I moved on.


Elementary OS

Very Mac OSX like. However, I’ve read that it’s heavy on RAM. When you only have 2GB of RAM to play with and an old 4200 RPM drive, I think disk swapping is something that needs to be avoided..



Looks like a nice out of the box desktop, but the website put me off. Just sayin..


LXLE (Linux Extra Life Extension)

This was actually my first choice, after looking at Lubuntu!

It’s basically touting itself as Lubuntu but with everything you need configured and customized out of the box to be a nice workstation/desktop. I downloaded this one, 64bit (I know, only 2G ram..)

It’s basically Lubuntu but with the best/useful up-to-date applications, beautiful aesthetics, and a polished user interface. It’s supposed to be a drop-in replacement for Windows, as a desktop.

It did annoy me that the base image was 1.47G and not within CD-R limits. However, old PC might mean old Internet. I just would have rather had a 2 CD option versus 1 DVD.


Ubuntu MATE

Lots of good reviews and buzz around this. I had already settled on LXLE and cut a disc, I didn’t fancy a reinstall. I actually really like the look and sound of this OS.



Download & Preparation

First, I had to figure out a way to burn the ISO to disc. Let’s use the Sony and the Kubuntu installation.

Since I pre-downloaded it on my Macbook Air, I uploaded it to the NAS and grabbed it from there. I have to say it was much slower downloading it from the NAS than it was uploading it (and my Air doesn’t have ac wireless).

Downloading LXLE ISO via Firefox from my Synology Diskstation web interface

Approximately a third of the way done, the system looks OK. Interestingly, CPU software interrupts seems pretty high.

Looking further into this, it looks like it’s the timer (IRQ 0), there’s not much I can do about that. I guess this is just related to using an old machine, and not really worth tuning.

I do note that the system fan has kicked in, Firefox is taxing the machine. No real slowdowns noticed, though.


Eventually, a cup of tea later, it’s time to write the ISO to disc. I’ve not really had much of a requirement for optical discs or drives for quite a few years now, so I’ve still had the same pack of DVD-Rs for easily over 5 years. Interestingly, they all seem to have some weirdness to them now. I’m not sure if you can see this, but here’s a photo:

Over 5 years old, still on the original spindle. They all look like this.

I’m not holding out much hope for a 9 year old machine being able to burn a 5+ year old disc, but it’s worth a shot.

Kubuntu: Burning LXLE on 9 year old laptop with 5+ year old media

Looks like it worked fine. Verified OK, and disc verification in LXLE menu was OK too. Man, I don’t even want to sell this. 🙂


Took about 5 minutes to load past the loading screen. Be free, Be open! .. Wifi connected fine.


  • 20 minutes to get to “Installation is complete” message.

We’re in business!



Overall it’s pretty snappy. LibreOffice worked ok, I was able to do some basic things in terminal and used Seamonkey to perform a run (so Flash works OK too).

Hardware (out of the box)

  • Audio: OK
  • Wifi: OK
  • Bluetooth: Looks OK in dmesg, didn’t test further
  • Optical drive: OK
  • GSM modem: Looks OK in dmesg, didn’t test further
  • LAN: looks OK in dmesg, didn’t test further
  • iee1394/firewire: Looks OK in lspci, didn’t test further.
  • Fingerprint reader: Looks OK in lsusb, didn’t test further
  • Camera: Looks OK in lsusb, no driver installed.
  • Blue FN key presses; some work OK
    • Volume up/down OK
    • Mute OK, doesn’t un-mute
    • Brightness does nothing
    • Page Up/Page down OK
    • Home/End OK
    • Didn’t test the others.
  • Right hand side of touchpad for scrolling works well.


CPU gets high, pretty much any time you do anything with the browser. It doesn’t seem to slow down the OS really from a user experience perspective, though. Right now, I guess anti-virus updates happened, and it’s using 100% of a single core doing regular updates. Overall, a nice little compact Linux laptop.

img_9966 over wireless.

Battery life test will be difficult, it’s going to take a while to finish charging. I’m not really sure if it even still holds a charge.

Browsing generally feels OK, and modern. Youtube plays a music video smooth with no skips, although CPU is high. Works full screen too.


Now I didn’t expect Netflix to work, and I wasn’t disappointed. Before I started streaming, just after I logged in, RAM usage spiked enough to start swapping ~100MB. Once I tried to start streaming, it threw an error saying HTML5 support was needed. I guess Seamonkey doesn’t have support / correct support. Quick Google seems to show this as a known problem. I launched the Lubuntu Software Center, and grabbed Firefox from there. No dice, same issue.

Battery Test

Charging the battery took a long time; It’s 88% now and wants 27 minutes to fill. It was 0% (and off for years) when I started this. I switched out for a 16V 4a adapter I have from the 16V 2.2a and it only dropped to 25 minute charge time from 27 – I guess it just takes a while to charge. From 89% to empty, it’s giving an estimate of 3h 51m remaining. It looks like this thing still holds a charge!

Usage Log

  • Started on battery at 17:54
  • Had a game of DreamChess .. still 89%
  • Game of CriticalMass still 89%
  • I am now editing the remainder of this blog post from the laptop itself via Seamonkey. Works well, the screen is really nice.
  • Down to 87% remaining and an estimate of 3 hours.
  • Still only using 20% cpu and 450MB RAM.
  • Have 4 desktop spaces open, with just the Seamonkey browser on one half of the screen. The keyboard is still pretty nice to type on, except for me having a missing tab key cap.
  • Pandora is playing in another tab now, through the speakers at 50%. CPU 16.3%, RAM 553MB (27%) – pretty impressive memory footprint, really. 86% battery.
  • Went back up the blog post and edited the section adding in the blue FN key info. Down to 84%. Pandora must be dragging the battery down a bit now.
  • Opened the software center to see what games I can download..
  • Installed:
    • Freeciv
    • Freecol
    • Descent 1 Rebirth
    • Freedoom
    • Freedroid
    • Freedroid RPG
  • Even while installing packages, Pandora didn’t skip, and I was still able to type and edit this post.
  • Pandora wanted me to sign in, so I launched the built-in Guayadeque Music Player to stream some radio instead.
  • 78% after the software all installed.
  • Freedoom: silky smooth
  • Freedroid RPG – what is this game? I love it.
  • FreeCol ground the machine to a halt. I guess Java is a no-no. Rebooting, going to try again. 75% battery when I get back into desktop.
  • FreeCol starts but when I try to click past the introduction video, it sorta just hangs. I gave it a good 60 seconds to sort itself out before I got impatient and rebooted again.
  • It’s now 18:36 and I’m back on the Macbook to edit the blog.
  • FreeCiv.. works great, still 73%
  • Descent 1 doesn’t start
  • Heading back to the software store to find some more intensive games. Installing quite a lot actually, 3G of stuff downloaded, 5G installed. I killed the radio at the start of installation too.
  • After installing and playing a bunch of games.. generally what you could say “heavy use”, at 20:20, there’s 25% battery (estimate 1h 4m remaining).

This slideshow requires JavaScript.

Battery Results

  • 89% to 25% battery – 2h 25m of heavy use.
  • Charge estimate of 25% to full – 3h 18m
  • Not bad at all for a laptop nearly a decade old.

Concluding Stats

  • Boot time: 1m 20s (usable as soon as desktop appears with no slowdown)
  • Shutdown time:
  • Wifi performance: 23Mb down/50Mb up
  • Usable for: basic web browsing, remote administration, Linux development, open source gaming, portability, those times where you need old port connectivity and optical drive in a nice tiny package – almost impossible to find now…

…and we’ll call it a day.



Documentation, Games, Gaming, Retro

Windows 98SE on VirtualBox (with video and audio drivers)

Screen Shot 2015-12-04 at 1.00.52 AM

Why do this?

If you feel nostalgic for a bit of Windows 9x action, or you just want to play some old games that are between DOS and Windows XP, you can either build a retro PC gaming rig, or you can test the water with VirtualBox.

Once it’s all done, you too can see how pointless it all is. 🙂

What you will need:

  • Windows 98SE ISO (unfortunately, I can’t help you here)
  • SCITech Display Doctor (this will be the video driver) –
  • VirtualBox (
  • Optional downloads are available and listed in each section below.

Create the VM and Install Windows 98 SE

  1. Create new VM on Virtualbox Screen Shot 2015-12-03 at 10.50.03 PM
    • Type: Microsoft Windows
    • Version: Windows 98
    • RAM: 64MB
    • Create new fixed size HDD – 2GB (VDI is fine)
  2. Install Windows 98SE
    1. Boot with your 98SE ISO mounted (you’ll have to find this yourself)
    2. Boot with option 2 – Start computer with CD-ROM support Screen Shot 2015-12-03 at 10.53.04 PM
    3. Run fdisk and accept all the defaults to create a 2GB partition on your virtual drive.
    4. Restart the virtual machine
    5. Boot with option 2 – Start computer with CD-ROM support
    6. Format the virtual drive using format on the Windows CD
      • D:\win98\format c:
    7. Run: D:\setup.exe /ie /im /is /nr
      • /ie Disables create a boot disk (causes crashing on VBox and 98SE installer)
      • /im Disables checking conventional RAM
      • /is Disables scandisk
      • /iv Don’t disable billboards
      • /nr Disable registry check
    8. Run through the Windows installer with all the defaults Screen Shot 2015-12-03 at 11.01.46 PM
    9. After reboot – Boot from Hard Disk
    10. Enter your name and the CD key for Win98SE (98 key works too btw); install will continue.
    11. If everything went well, you should see Windows 98 desktop and hear some tragic music. 🙂

Install Video Driver

  1. Shutdown Windows (and the VM)
  2. Edit Settings of the VM -> Storage -> Add another device to the IDE controller (click the CD with the green plus) and mount the scitech-display-doctor-7.iso file you downloaded earlier. Screen Shot 2015-12-03 at 11.13.20 PM
  3. You should see a CD drive with Sdd7 – double click that then run the scitech-display-doctor-win-7.0 installer – Express installation is fine. Screen Shot 2015-12-03 at 11.14.52 PM
    • You will eventually need to register the software. Unfortunately, it’s not sold anymore, but it is trivial to find a serial number for this via your favorite search engine.
  4. OS will restart, when it returns, SciTech Display Doctor will load. Either register it or start the 21 day trial.
  5. On the HOME page, underneath Current Configuration, there is a section called Active Features. Click ‘Disabled’ next to SciTech Display Driver then select SciTech Nucleus Driver and apply. Screen Shot 2015-12-03 at 11.19.00 PM
  6. OS will reboot again (remember how annoying this used to be?)
  7. SciTech reloads and you’ll see that VESA VBE 2.0 Oracle VM VirtualBox VBE Adapter is now selected. Screen Shot 2015-12-03 at 11.25.29 PM
  8. Minimize the window, right click Desktop then Properties then Settings
    • Here you should see Default Monitor on SciTech Display Doctor 7.0
  9. Change Colors to 16bit, apply, it’ll reboot again!
    • I’ve had issues trying to change resolution at the same time.
    • I’ve also had issues when the restart didn’t work – if so, restart the VM yourself – no need to go into safe mode, it should boot the second time OK.
  10. Right click Desktop -> Properties -> Settings; now you can select 1024×768 no problem.
  11. Hello accelerated Windows desktop!

Configure for (broken and basic) Internet access (NAT)

This will allow you to access the Internet, albeit in a basic and broken way.

  1. Start -> Settings -> Control Panel -> Internet Options -> Connections -> Setup
    1. I want to set up my Internet connection manually … or local area network (LAN).
    2. I connect through a local area network (LAN).
    3. Accept everything except for setting up a mail account.
    4. Internet Explorer 5 will load. I recommend that you download Opera 9.64 (Opera 10 and above doesn’t support Windows 9x) –
    5. Firefox 2 also works, but I found it was about as useful as IE5.
    6. Windows Update is long dead.

Install DirectX8.1b (optional step)

  1. If you installed Opera 9.6 earlier, this is compatible enough to grab the file directly from the web via
  2. You will also need WinZip – grab this from
  3. Extract and install (via dxsetup.exe) the DirectX8.1b redistributable.
  4. Windows will reboot and you will now have DirectX 8.1 installed – you can verify this by running C:\windows\system\dxdiag.exeScreen Shot 2015-12-04 at 12.19.34 AM

Install AC97 soundcard (optional step)

The default VM setting is SoundBlaster 16 compatible. You can use the Windows Midi Synth, but I’ve seen some issues with games. In turn, we can use 9x drivers for AC97.

  1. If you installed opera 9.6, head over to -> Downloads -> AC’97 Audio Codecs (Software) -> Windows 95 for Driver only.
  2. Install file then instead of rebooting Windows, choose reboot later then shut down the VM.
  3. Head into Virtualbox VM settings -> Audiot and change the Audio Controller from Soundblaster 16 to ICH AC97
  4. Boot the VM up, it’ll detect the AC’97 audio – install the driver then reboot againScreen Shot 2015-12-04 at 12.28.45 AM
  5. Should have audio and wavetable MIDI when it returns.
  6. You can test this by running C:\windows\system\dxdiag.exe again.

Screen Shot 2015-12-04 at 12.45.49 AM

Testing a Game

C&C Gold 95 doesn’t seem to work – will investigate further without dx8.1 since it comes with dx3.


Civilization 2 Ultimate Collection – works perfect (dx5 game)