How-To : Autostart Parsoid on openSUSE 13.1


Once Parsoid is installed on openSUSE it might be handy to have is started automatically once system is restarted.

First we have to create startup script.



# description: Node.js /srv/parsoid/api/server.js

. /etc/rc.status






if [ ! -f "$LOCK_FILE" ] ; then
echo -n $"Starting $SERVER: "
runuser -l "$USER" -c "$DAEMON $SERVER -n $WORKERS_NUMBER >> $LOG_FILE &" && echo || echo
[ $RETVAL -eq 0 ] && touch $LOCK_FILE
echo "$SERVER is locked."
echo -n $"Stopping $SERVER: "
pid=`ps -aefw | grep "$DAEMON $SERVER" | grep -v " grep " | awk '{print $2}'`
kill -9 $pid > /dev/null 2>&1 && echo || echo
[ $RETVAL -eq 0 ] && rm -f $LOCK_FILE

case "$1" in
echo "Usage: $0 {start|stop|restart}"

exit $RETVAL
Remember to adjust all paths and number of worker processes accordingly to your installation.

Once startup script is in place we have to enable Parsoid to be automatically started:

chkconfig parsoid on

From now on Parsoid will be automatically started after each restart.


Config snippets : Cisco : Password 7 Decryptor in Adobe Flex


As the effect of my attempts to produce some small applications in Adobe Flex, I commited decryptor for type 7 passwords stored on Cisco devices.

Using this small app you can decode:

  • wireless keys fro Cisco access points,
  • RADIUS/TACACS shared secrets
  • NTP authentication keys
  • Enable passwords (NOT enable secrets, which are stored using MD5).



TIps & Tricks : Searching for packages in Debian


If you want to install some packages on Debian and don’t know names of packages you can search in packages cache.

For example if you want to see all packages related to MySQL:

root@hostname:~# apt-cache search mysql
akonadi-backend-mysql - MySQL storage backend for Akonadi
ampache-themes - Themes for Ampache
aolserver4-nsmysql - AOLserver 4 module: module for accessing MySQL databases
libapq3.2.0 - Pluggable Ada 95 Binding to various database systems (library)
libapq3.2.0-dbg - Pluggable Ada 95 Binding to various database systems (debug)
libapq3.2.0-dev - Pluggable Ada 95 Binding to various database systems (development)
libaprutil1-dbd-mysql - Apache Portable Runtime Utility Library - MySQL Driver
asterisk-mysql - MySQL database protocol support for the Asterisk PBX
audiolink - makes managing and searching for music easier
auth2db - Powerful and eye-candy IDS logger, log viewer and alert generator
auth2db-common - Common configuration files for Auth2db backend and web frontend
auth2db-filters - Auth2db defaults filters pack
auth2db-frontend - Web frontend view for auth2DB log engine
automysqlbackup - daily, weekly and monthly backup for your MySQL database
autopostgresqlbackup - Automated tool to make periodic backups of PostgreSQL databases
backup-manager - command-line backup tool
backupninja - lightweight, extensible meta-backup system
bacula-common-mysql - network backup service - MySQL common files
bacula-common-mysql-dbg - network backup service - MySQL common files (debugging)
bacula-director-mysql - network backup service - MySQL storage for Director

How-to : Running Cisco Nexus 1000 as virtual machine on vSphere Hypervisor ESXi 5


In one of the previous articles I did quick overview How-to Install vSphere Hypervisor ESXi 5 on VMware Workstation 9. One of the reasons I did that in my Lab environment was to run Cisco Nexus 1000v with NX-OS on it and evaluate this operating system and how it can integrate with other products. So, here is quick overview how to make Cisco Nexus 1000v happen on vSphere ESXi.



Config snippets : Cisco : First time 881w ISR with AP configurarion


When I got cisco 881w first time it was interesting experience. This device presented new concept which was different to model I knew so far, which is 871w. In 881w router module and wireless module are separated. With that being said, router configuration and access point configuration is separated as well. Also, each module (router and access point) has own IOS:

  • c880data-universalk9-mz.152-1.T1 – router IOS
  • ap801-k9w7-mx.124-21a.JA1 – access point IOS

As usual, first I connected device to console cable and attempted to configure it. Not being familiar with new concept it was a bit of a failure 🙂 So, eventually had to refer to documentation to find out what’s going on. Problem which came up was, how to access wireless module to configure it or even check if it’s there 🙂

So, finally after I did apply reading ability and spent few minutes with Cisco documentation I was able to access wireless module and configure it to provide wireless services in the air. Here is how that happend:



Config snippets : Cisco : DHCP on Catalyst switches


Usually I tend to create DHCP server on Windows Server. However, sometimes there is no server on site. Only what I have are network devices, workstations and voip phones. In those cases I used to create DHCP server on switches. As environment I operate in contains mainly Cisco devices, each location has at least one or more Cisco Catalyst switches (2960 or 3560) it is possible to provide DHCP service using IOS features. Example contains DHCP configuration for network with different VLANs for data, voice and printers.

Below is short description and set of commands demonstrating how to setup:

  • DHCP scopes
  • Exclusions
  • Define DHCP helper on the interface
  • Check status of DHCP assignments



Tips & Tricks : How to add .NET Framework 3.51 to Windows 8 or Windows Server 2012


Unfortunately there is a problem when you try to add .Net Framework 3.51 to Windows Server 2012 using Server Manager. In order to fix that issue and get .Net Framework 3.51 installed (which is required by majority of applications and servers) issue following command from Command Prompt:

dism /online /enable-feature /all /featurename:NetFX3 /source:x:\sources\sxs

Please notice that x: in source parameter has to be replaced with appropriate drive letter for DVD with Windows Server 2012 installation files.


Code snippets : SQL : Backup and FTP transfer SQL Server database


Some time ago I had to transfer SQL Server databases from remote retail locations to central system. At that time whol einfrastructure was operating on Microsoft SQL server 2000 and link in remote locations was 128kb/s ISDN. At that time I thought that the best idea will be backup database to local hard disk on SQL server, RAR it and FTP compressed backup of SQL database to headquater. It did work quite well. So, below is a script I scheduled to be run as part of scheduled job defined on SQL Server Agent.

Before script will be used few things have to be customized:

  • location for database backups – @archive_path – default: F:\Backup
  • location of WinRAR application – @archive_cmd – default: C:\Program Files\WinRAR
  • IP address of FTP server – default:
  • Username and password for FTP user – default: dbupload/password
  • Folder on FTP server for backup upload – default: Site_Backup

As there might ba many remote sites uploading backups, each site can have different folder for data transfer.

Here is script to backup SQL Server database and trasfer backup to FTP server:



Tips & Tricks : HP TouchSmart tm2 : Screen Rotation


When upgrading drivers on HP TouchSmart tm2 tablet important is to keep in mind that HP Quick Launch Buttons package might disable screen auto-rotation. In order to restore that functionality remove HP Quick Launch Buttons and install older version of that package from here. Full information about package is available on HP Quick Launch Buttons web page availabel here.

Another option might be registry settings adjustment. Parameters which control screen orientation and bahevior are located under:

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Hewlett-Packard\HP Quick Launch Buttons\Schemes\Default\8526

There are two important parameters:
Notebook_Docked_DisplayOrientation = 0
Tablet_UnDocked_DisplayOrientation = 3

Available values for those parameters:
0 – primary landscape
1 – seconday portrait
2 – seconday landscape
3 – primary portrait


How-to : Recover totally bricked Nokia Lumia 820


When trying to recover my Lumia 820 from unsuccessful OS upgrade, phone went completely dead.

I was not able to turn it on or see any sign of activity in the device (boot manager damage happened probably).

At that stage I decided to look for tool which can recover my boot manager and then OS on Lumia.

Tool I found is available on Microsoft web site:

…and here is how it recovered my phone…


Page 1 of 1712345...10...Last »