Thursday, September 29, 2016

Installing .Net 3.5 on Windows 10 offline using DVD/ISO media

Installing .Net 3.5 using the Control Panel in Windows 10 (anniversary update) can sometimes be very slow. Alternative option is to install from DVD/ISO, like:

c:\>DISM /Online /Enable-Feature /FeatureName:NetFx3 /All /LimitAccess /Source:E:\sources\sxs

Where:
E: is the drive letter of DVD/ISO

Reference:
https://technet.microsoft.com/en-us/library/dn482069.aspx

Wednesday, September 28, 2016

BlackBerry Playbook Simulator 2.1 not working after installing on Ubuntu 16.04 64-bit

I was able to install BlackBerry Playbook Simulator 2.1 on Ubuntu 16.04 64-bit by installing supported libraries, see here.

Running the IDE (/opt/bbndk-2.1.0/bbndk.sh) fails with a message as shown below.

/opt/bbndk-2.1.0/host/linux/x86/usr/bin/../..//usr/qde/eclipse/qde: error while loading shared libraries: libgtk-x11-2.0.so.0: cannot open shared object file: No such file or directory

The above message says we don't have libgtk-x11-2.0 libraries. Since the IDE was compiled as i386 we need to install the library like:

sudo apt install libgtk2.0-0:i386

Running the IDE again yields the following error message:
(qde:2418): Gtk-WARNING **: Unable to locate theme engine in module_path: "hcengine",
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0xf771179d, pid=2418, tid=4131637376
#
# JRE version: 6.0_24-b07
# Java VM: Java HotSpot(TM) Client VM (19.1-b02 mixed mode, sharing linux-x86 )
# Problematic frame:
# C  [ld-linux.so.2+0xb79d]
#
# An error report file with more information is saved as:
# /home/y/hs_err_pid2418.log
#
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#
Aborted (core dumped)

What is happening here is that Momentics IDE ships with Java 1.6 runtime but it is not compatible with some of the libraries that comes with Ubuntu 16.04. To fix this install Java 1.9 runtime for i386 architecture, like:

sudo apt install default-jre:i386

The above installation will make Java runtime available in the default path which will override sourcing by the scripts. Running the IDE this time should work but with some minor warnings, like:

(qde:2418): Gtk-WARNING **: Unable to locate theme engine in module_path: "hcengine"

To clean the console message out, do:

sudo apt install gtk2-engines:i386

You should now have a working Momentics IDE!!!

Tuesday, September 27, 2016

Installing BlackBerry Playbook Simulator 2.1 fails on Ubuntu 16.04 64-bit

Tried to install BlackBerry Play Simulator 2.1 on Ubuntu 16.04 64-bit but it fails with error message below.

sudo ./installer-bbndk-2.1.0-linux-1032-201209271809-201209280007.bin

Preparing to install...Extracting the JRE from the installer archive...Unpacking the JRE...Extracting the installation resources from the installer archive...Configuring the installer for this system's environment...
Launching installer...
./installer-bbndk-2.1.0-linux-1032-201209271809-201209280007.bin: 3320: exec: /tmp/install.dir.3056/Linux/resource/jre/bin/java: not found


The installation is failing because it has dependencies to 32-bit libraries. To fix it, do:
$ sudo dpkg --add-architecture i386
$ sudo apt install libc6:i386
$ sudo ./installer-bbndk-2.1.0-linux-1032-201209271809-201209280007.bin

Installation should now complete but the IDE will not be working. Next post details how to fix it.

Follow-up post is here.

Saturday, September 24, 2016

Installing VMware Workstation Professional VMware Tools in Ubuntu 16.04

It is good practice to get the latest updates before installing VMware Tools. Open terminal and run the following:
$ sudo apt update
$ sudo apt upgrade
$ sudo reboot
If the update needs to upgrade the kernel, it is a good idea to reboot the machine before installing the tools so that we are compiling against the correct kernel.

From VMware Workstation menu, do VM | Install VMware Tools....
$ mount cdrom
$ mkdir ~/tmp
$ tar -xvzf /media/u1/VMware\ Tools/VMwareTools-9.9.5-3735633.tar.gz -C ~/tmp
$ cd ~/tmp/vmware-tools-distrib/
$ sudo ./vmware-install.pl -d
$ eject
$ sudo reboot
Where:
u1 = is the username, replace it with your username
VMwareTools-9.9.5-3735633.tar.gz = version of VMware Tools in the ISO, change it with what's in /media/<user>/VMware Tools/.

Friday, September 23, 2016

How to determine BlackBerry PlayBook Simulator IP address

Click on user icon, a popup dialog will show up and show the IP address.

Thursday, September 22, 2016

Windows 10 Task Manager not updating

This is probably my silly mistake but it took me a while to figure out why it is not updating - it was paused!!! Did I do it? Maybe... but could be Windows just deciding to pause it. Anyway, un-pause it like as shown below.


Reference:

Wednesday, September 21, 2016

tmux cheatsheet

Resizing the window of an existing session
tmux attach -d

Work in progress!!!!

How to remove floppy icon in Ubuntu 16.04 running on VMware Workstation 11

Even when the floppy hardware is removed from the VM configuration of a Ubuntu guest under VMware Workstation 11, the icon for floppy disk drive still shows up in the Launcher. To fix this  you need to disable Legacy Diskette A in the virtual BIOS of the guest. An easy way to boot to the virtual BIOS is to shutdown the VM, then select VM | Power | Power On to Firmware.
Then change Legacy Diskette A: to [Disabled], F10 to save and exit. This should reboot the machine.

References:

Monday, September 19, 2016

What is 169.254.x.x IPv4 address?

169.254.x.x is a link-local IP address that gets assigned automatically when, generally, DHCP is not available. On Windows operating system, this is called APIPA (Automatic Private IP Addressing). RFC 3927 defines the 169.254.0.0/16 address block for use in the link-local assignments. Note that routers are not supposed to route traffic from this address block.

Reference:
https://en.wikipedia.org/wiki/Link-local_address

BlackBerry Tablet Simulator Mouse Gestures

Mouse Gestures for BlackBerry Tablet Simulator

Description
Mouse
Show top bar (notification area)
Move mouse top middle and click
Show Browser options
Move mouse top right and click
Show applications running
Move mouse bottom middle and click
Show application home screen (aka desktop)
Move mouse bottom middle and click twice
Show on screen keyboard
Move mouse to lower left and click


Sunday, September 18, 2016

BlackBerry Tablet Simulator shows black screen

On Windows 10 Enterprise version 1511 build 10586.589 + VMware Workstation 11.1.4, powering up a BlackBerry PlayBook Simulator 2.1 shows blank/black screen. The simulator was created around September 2012, it may have worked back in the day but with latest versions of the host OS and VMware it is not working using default configuration. The link from here mentions about supported graphics card, thus say, should support OpenGL 2.0. I am using a machine that supports Open GL 4.1 and still not working.

To have a partially working simulator, change QNX boot option to 2.
You can play with the simulator but developing an application that needs EGL does not work.

Reference:
https://developer.blackberry.com/develop/simulator/simulator_installing.html


Hints/Keywords:
Blank screen
Black screen
BlackBerry Table Simulator Not working on VMware Workstation

Thursday, September 15, 2016

Installing BlackBerry Tablet Simulator 2.1 fails with "Windows error 2 occured while loading the Java VM"

Installing BlackBerry Tablet Simulator 2.1 on Windows 10 fails with the error message as shown below.

---------------------------
LaunchAnywhere Error
---------------------------
Windows error 2 occured while loading the Java VM
---------------------------
OK
---------------------------
To fix this install x86 version of JRE (tested with jre-8u102-windows-i586.exe). Running the installer again will still fail. Workaround is to pass command line argument to the installer, like:

BlackBerryPlayBookSimulator-Installer-2.1.0-1032-Win-201209272349 LAX_VM "C:\Program Files (x86)\Java\jre1.8.0_102\bin\java.exe" -i GUI

Run the above command on elevated prompt.

Tested on Windows 10 1511 (OS Build 10586.545)

Reference:
https://supportforums.blackberry.com/t5/Adobe-AIR-Development/Window-error-2-occurred-when-loading-java-vm/td-p/1300033


Sunday, September 11, 2016

Add a regular user in Kali Linux

Create a new user, say timus.
# adduser timus
Add user to sudoers group. This enables the user to become root when needed, for example to install new software.
# usermod -a -G sudo timus

References:
http://8thstring.blogspot.com/2013/07/howto-create-new-user-in-lubuntu.html
http://8thstring.blogspot.com/2012/12/adding-existing-user-to-group-in-ubuntu.html


Install Linux headers in Kali

In Kali Linux 2016.2, Linux headers were not installed when build-essential package was installed. Linux-headers is need when installing VirtualBox guest additions. To install the headers, do:

# apt install linux-headers-$(uname -r)

This should apply to the following distribution as well:
- Debian
- Ubuntu and derivatives

Reference(s):
http://askubuntu.com/questions/75709/how-do-i-install-kernel-header-files