Use google maps API from google docs
I am looking for a dojo where I could go practice to. I needed to find out which one would be closest to my work or home place...
I had that list of address representing some place of interests - all of the aikido dojos. And course I knew my home address. While google doc offered me an easy way to map all of those addresses on a map, I wanted to get some extra information such as the duration or distance for directions between my place and the listed address.
With the following formula one can easily find plenty of information:
For a duration
=INDEX(importXML("http://maps.googleapis.com/maps/api/directions/xml?origin="&SUBSTITUTE(TRIM(SUBSTITUTE(SUBSTITUTE( D2 ;CHAR(13);" ");CHAR(10);" ")); " "; "+")&"&destination="&SUBSTITUTE(TRIM(SUBSTITUTE(SUBSTITUTE( $D$9 ;CHAR(13);" ");CHAR(10);" ")); " "; "+")&"&sensor=false" ; "//leg/duration/text[last()]" ) ; 1)
For a distance
=INDEX(importXML("http://maps.googleapis.com/maps/api/directions/xml?origin="&SUBSTITUTE(TRIM(SUBSTITUTE(SUBSTITUTE( D2 ;CHAR(13);" ");CHAR(10);" ")); " "; "+")&"&destination="&SUBSTITUTE(TRIM(SUBSTITUTE(SUBSTITUTE( $D$9 ;CHAR(13);" ");CHAR(10);" ")); " "; "+")&"&sensor=false" ; "//leg/distance/text[last()]" ) ; 1)
You will understand that my home address would be in the cell D9 and that each address are in a D# cell.
Of course using the XPath Syntax, you can refer to any of the xml tag and get the value you need in a cell as you notice that the only difference between those are the parsing I am doing with //leg/distance.
importXML is pretty neat for parsing into xml data but use it with moderation as you can only use it 50 times in a spreadsheet.
Big Brother client installation on UNIX/Linux
Following procedure explains the steps for installing Big Brother client on UNIX/Linux servers and information about all the supported files. I could not really find this anywhere easily broke down, I hope this helps a few...
Installation Steps
Create user bb on the server to be monitored.Assign 1984 uid to the Big Brother user.
useradd -u 1984 -c "Big Brother monitoring" bb
Copy the latest BB client tar file from your repository to bb home directory of the monitored server.
su - bb
scp root@yourrepo:/home/bb/software/BBCLT-aix6.1-bbc4.30-bbpe.tar .
Decompress the tar file in the bb home directory
In the bb home directory
tar -xvf BBCLT-aix6.1-bbc4.30-bbpe.tar
Exit from bb home directory as the BB client should be installed using root account.
From root user go to /home/bb/bbc4.30-bbpe/install and execute bbconfig file.After executing bbconfig file, it will ask to accept the License agreement.
After accepting the License agreement, the installation process will ask to enter a few details.
OS [aix] is the default so you can hit enter directly
It will ask for the userid for Big Brother which will be "bb".
The installation process will add a service in /etc/init.d which will start at boot.
At this point the BB client is not started as bb-hosts file is missing or empty.
Information about bb-hosts file
The bb-hosts file in present in /home/bb/bbc4.30-bbpe/etc.This file holds the information about the host and the BBDisplay,BBPAGER and BBNET.
BBDISPLAY is the server which will display all the monitored servers.
BBPAGER is the server which sends email alerts.
BBNET is the server which performa all Network tests.
Sample bb-hosts file.If the first line or name of the monitored host does not match the entry in the bb-hosts file then the bb client will not start.
0.0.0.0 monitoredsrv #must name uname -n
0.0.0.0 displaysrv # BBNET BBDISPLAY BBPAGER
Once all the changes are done then we are good to start the BB client.
The entry of the monitored server in bb-hosts file should also match with the entry in BB server's bb-hosts file.
I forgot to mention that to start and stop BB you can use the following:
su - bb -c "cd /home/bb/bbc4.30-bbpe;./runbb.sh start"
su - bb -c "cd /home/bb/bbc4.30-bbpe;./runbb.sh stop"
Robocopy and EMC Celerra
I came across a problem when using Robocopy command scripts when copying files from NTFS to EMC Celerra file system. The problem was that every time Robocopy was told to copy files to the EMC Celerra over the WAN, the files were always detected as “newer” on from the originating source. This caused Robocopy to copy every single file from our network to the remote network each and every time.
I came across a command line switch for Robocopy: /FFT : Assume FAT File Times (2-second date/time granularity). The NTFS date and time stamp is a 64-bit variable, which DART doesn’t deal with. So what this does is force Robocopy to use FAT style time stamps which are 2-second granularity. It allows enough flexibility to account for the way the time is recorded when doing a file copy from NTFS to another file system. This is needed when going between and NTFS and Linux/Unix/FAT or emulated file system.
update 20110601: I now use fastcopy instead of robocopy. It is a great fast(er) and friendly tool! And it doesn't have any of the security or date issues I have seem with the msft tool.
Using 32-bit .Net Applications on a 64-bit system
I needed to use the Windows Mobile Security Power Toy the other day. So I download the power toy, fired it up, and watched it promptly crash. After several failed attempts I figured there was something wrong with my computer, so I went to another computer and did the same thing with success. In trying to diagnose the problem I went to another computer and tried to run the power toy and it crashed there also. So what was the problem?
In looking at the similarities and differences among the computers I realized that the two computers on which the application crashed had one thing in common - they were 64-bit machines whereas the machine on which the power toy worked was a 32-bit machine. I ran into a problem like this years ago. I had a .Net application that P/Invoked some 32-bit APIs. The computer would automatically load the .Net code in a 64-bit process, but 64-bit and 32-bit code cannot coexists in the same process which is why the program would crash. When I ran into this problem years ago I just changed the settings on my project so that the code would NGEN to 32-bit code (that means it was converted to x86 code at compile time). But I don't have the source code for the Windows Mobile Security Power Toy. So what could I do?
There's a command line utility that would help me here. It allows one to start a .Net executable and load it into a 32-bit process. the utility is named CORFLAGS.EXE. I went back to the 64-bit machines, opened the command prompt, and typed the following:
COREFLAGS.EXE SecurityManager.exe /32BIT+
Success!
I need to do more networking
■ Promote yourself constantly.
■ More contacts = higher probability of success.
■ Never eat alone.
■ Create non-stop touch points.
■ Get out there as much as possible.
Go read Networking for people who hate networking
KitKatNeko