Tuesday, November 5, 2013

App Pool vs Process ID listing

Scenarios

- Every AppPool creates W3WP.EXE process however when you are debugging through visual studio with IIS server having too many websites and app pools and you are challenged to find the right W3WP.EXE process to attach so that code debugging can be done against respective apppool W3WP.EXE


In IIS 6 (Windows 2003)
%windir%\system32\

c:\Windows\System32> iisapp.vbs

In IIS 7 (Windows 2008) and IIS 7.5 (Windows 2008 R2)

c:\Windows\System32\inetsrv>appcmd list wp

- List the web sites on your IIS server
c:\Windows\System32\inetsrv>appcmd list sites 

- Application pools on your IIS server

c:\Windows\System32\inetsrv>appcmd list appPools

Thursday, August 29, 2013

MapReduce Data Processing Pattern

MapReduce is
  • Data processing approach for processing highly parallelizable datasets.
  • Implemented as a cluster, with many nodes working in parallel on different parts of the data.
Data is divided up into small chunks that are then distributed across all data nodes in cluster for parallel processing.

MapReduce requires writing two functions:
  • a mapper
  • a reducer
MapReduce functions can be impleted in JAVA, C++, C#, Python, Javascript (to script PIG), etc...

These functions accept data as input and then return transformed data as output. Functions are called repeatedly, with subsets of data, with the output of the mapper being aggregated and then sent to the reducer. JobTracker coordinates jobs across the cluster.

Limiting factor for MapReduce is the size of the cluster.

Hadoop 

Implements MapReduce as a batch-processing system.
Optimzed for flexible and efficient processing of huge amounts of data, not for response time.

Hadoop ecosystem includes higher level of abstractions beyond MapReduce.

Hive provides a SQL kind of query language. When we submit a HiveQL query, Hive generates MapReduce functions and runs behind the scenes to carryout the requested query.

Pig is another query abstraction with a data flow language known as Pig Latin. Pig also generates MpaReduce functions and runs behind the scenes to implement the higher-level operations described in Pig Latin.

Mahout is a machine learning abstraction....TB typed

Sqoop is a relational database connector.

Use Hadoop to get right data subset and shape it to the desired form, then use BI tools to finish the analytical processing.

MongoDB Install on Windows 7 64-Bit

MongoDB requires a data folder to store its files. 
The default location for the MongoDB data directory is \data\db


Note
You may specify an alternate path for \data\db with the dbpath setting for mongod.exe, as in the following example:
C:\mongodb\bin\mongod.exe --dbpath d:\test\mongodb\data
If your path includes spaces, enclose the entire path in double quotations, for example:

C:\mongodb\bin\mongod.exe --dbpath "d:\test\mongo db data"

mongod.exe --dbpath "C:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\data"


C:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\bin>mongod.exe --dbpath "C
:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\data"
Sat Jun 01 17:16:41.671 [initandlisten] MongoDB starting : pid=9196 port=27017 d
bpath=C:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\data 64-bit host=BHA
RATH-XPS-PC
Sat Jun 01 17:16:41.674 [initandlisten] db version v2.4.4-rc0
Sat Jun 01 17:16:41.674 [initandlisten] git version: f25c410a9c4a88de36c82797e82
e306be2274d40
Sat Jun 01 17:16:41.674 [initandlisten] build info: windows sys.getwindowsversio
n(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1') BOOST
_LIB_VERSION=1_49
Sat Jun 01 17:16:41.675 [initandlisten] allocator: system
Sat Jun 01 17:16:41.676 [initandlisten] options: { dbpath: "C:\Program Files (x8
6)\mongodb-win32-x86_64-2.4.4-rc0\data" }
Sat Jun 01 17:16:41.694 [initandlisten] journal dir=C:\Program Files (x86)\mongo
db-win32-x86_64-2.4.4-rc0\data\journal
Sat Jun 01 17:16:41.696 [initandlisten] recover : no journal files present, no r
ecovery needed
Sat Jun 01 17:16:41.885 [FileAllocator] allocating new datafile C:\Program Files
 (x86)\mongodb-win32-x86_64-2.4.4-rc0\data\local.ns, filling with zeroes...
Sat Jun 01 17:16:41.887 [FileAllocator] creating directory C:\Program Files (x86
)\mongodb-win32-x86_64-2.4.4-rc0\data\_tmp
Sat Jun 01 17:16:42.101 [FileAllocator] done allocating datafile C:\Program File
s (x86)\mongodb-win32-x86_64-2.4.4-rc0\data\local.ns, size: 16MB,  took 0.2 secs

Sat Jun 01 17:16:42.103 [FileAllocator] allocating new datafile C:\Program Files
 (x86)\mongodb-win32-x86_64-2.4.4-rc0\data\local.0, filling with zeroes...
Sat Jun 01 17:16:42.705 [FileAllocator] done allocating datafile C:\Program File
s (x86)\mongodb-win32-x86_64-2.4.4-rc0\data\local.0, size: 64MB,  took 0.583 sec
s
Sat Jun 01 17:16:42.709 [initandlisten] command local.$cmd command: { create: "s
tartup_log", size: 10485760, capped: true } ntoreturn:1 keyUpdates:0  reslen:37
824ms
Sat Jun 01 17:16:43.057 [websvr] admin web console waiting for connections on po
rt 28017
Sat Jun 01 17:16:43.234 [initandlisten] waiting for connections on port 27017



C:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\bin>mongo.exe
MongoDB shell version: 2.4.4-rc0
connecting to: test
Welcome to the MongoDB shell.
For interactive help, type "help".
For more comprehensive documentation, see
        http://docs.mongodb.org/
Questions? Try the support group
        http://groups.google.com/group/mongodb-user
>

MongoDB as a Windows Service


Set log path
echo logpath="C:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\log\mongo.log" > "C:\Program Files (x86)\mongodb-win32-x86_64-2.4.4-rc0\mongod.cfg"

Running the MongoDB server (i.e. “mongod.exe”)
  • To run the MongoDB service:

net start MongoDB
  • To stop the MongoDB service:
    net stop MongoDB
    
  • To remove the MongoDB service:
    C:\mongodb\bin\mongod.exe --remove
Installing MongoDB on Windows
http://docs.mongodb.org/manual/tutorial/install-mongodb-on-windows/

Sample video of building a sample web application working with MongoDB
http://www.10gen.com/presentations/building-web-applications-mongodb-introduction

Fiddler Hook for Visual Studio HTTP traffic

WinInet traffic monitoring can be done by updating the Machine.config file

Configure Fiddler

Following configuration settings are required

<configuration>
  <system.net>
    <defaultProxy>
      <proxy
              usesystemdefault="False"
              bypassonlocal="True" 
              proxyaddress="http://127.0.0.1:8888"              
              />
    </defaultProxy>
  </system.net>
</configuration>

Wednesday, June 19, 2013

Keyboard Shortcuts for Windows Server 2012

Windows Key + C - Opens Charms bar
Windows Key + Ctrl + Tab - Cycles through apps
Windows Key + Shift + Tab - Cycles through apps in reverse order
Windows Key + D - Switch to desktop (from start screen)
Windows Key + E - Opens file explorer
Windows Key + F - Search (files and folders)
Windows Key + H - Share
Windows Key + I - Settings
Windows Key + K - Devices
Windows Key + M - Minimizes current windows on desktop
Windows Key + O - Sets device orientation
Windows Key + Pause - System properties
Windows Key + PgDown- Moves current app to right monitor
Windows Key + PgUp- Moves current app to left monitor
Windows Key + PrtScr - Save screenshot
Windows Key + Q - Global search
Windows Key + R - Run command
Windows Key + spacebar - Switch keyboard/input language
Windows Key + TAB - Provides list of running programs
Windows Key + U - Ease of access center
Windows Key + V - Cycles notifications
Windows Key + Shift + V - Cycles notifications in reverse order
Windows Key + Y - Shows desktop screen
Windows Key + W - System settings search
Windows Key + X - Quick access menu
Windows Key + Z - Opens app bar

Tuesday, June 4, 2013

GeoFlow for Excel 2013

GeoFlow is basically Excel charting plus Bing Maps

GeoFlow is a three dimensional (3-D) data visualization tool for Microsoft Excel 2013 that provides a powerful method for people to look at information in new ways. It enables the data discoveries that might not be seen in traditional two dimensional (2-D) tables and charts. With GeoFlow you can plot geographic and temporal data visually, analyze that data on a 3-D globe and over time, and create visual tours to share with others.

With GeoFlow you can:
1.    Map Data: plot up to a million rows of data in 3-D, visually on Bing maps.
2.    Discover Insights: gain new understandings by seeing your data in geographic space and seeing time-stamped data change over time.
3.    Share Stories: capture screenshots and build cinematic, guided video tours that can be shared broadly, engaging audiences like never before.


Refer to link below for project codename "GeoFlow" Preview for Excel

SQL Server 2014 announcements

Saturday, June 1, 2013

Architecture of your version of Windows platform. How to find ?

How to find the architecture of your version of Windows platform?

Use the following command in the Command Prompt:

C:> wmic os get osarchitecture

Output:

OSArchitecture
64-bit



Wednesday, May 29, 2013

How to disable password expiration for a local user

This blog post describes (one of the way) steps required to disable password expiration for a local user.
1.) Start an elevated command prompt 
-- Start --> Run --> C:\windows\system32\cmd.exe
-- then right click, 'run as administrator' (accept if any UAC dialog appears for permissions)
2.) Execute the following command into the command window:

wmic path Win32_UserAccount WHERE Name='testlocaluser' set PasswordExpires=false

Microsoft HDInsight Public Preview - Setting up Hadoop cluster on Windows Azure

 Windows Azure HDInsight public preview announced on https://HadoopOnAzure.com

1-Home-2013-03-25_2353

I was an existing HadoopOnAzure.com beta users so signing up with already signed up live account

2-SignIn-2013-03-25_2355

Requesting for creating new cluster

3-Create-Cluster-2013-03-25_2355

Sample request form for cluster creation on HDInsight
4-Request-CreateCluster-2013-03-25_2356

After click on "Request Cluster" button on right bottom corner of web interface

5-Creating-Cluster

Hadoop Cluster creation in progress

6-Deploying-Cluster

Hadoop cluster created and in Running status.

7-Hadoop-Cluster-Created

After clicking on "Go to Cluster" link under Cluster URL section in screenshot above.
- we see the cluster information screen as below.

8-Cluster-Look

Configure Ports (ODBC server)

9-ODBC-Ports-Configure

Configure Ports (ODBC server)

10-ODBC-Ports-Enabled

Sample HDInsight Hadoop cluster NameNode Remote Desktop RDP connection file content

11-Remote-Desktop-config

Connecting Remotely to NameNode desktop through RDP

12-MSTSC-Connecting

Sample My Computer - Explorer view of the NameNode hadoop cluster created.

13-RemoteDesktop-DataNode-View-3

Local user "bphdinsight" created with what we provided under cluster login section during requesting form submission for hadoop cluster creation.

13-RemoteDesktop-View-1

Remote Desktop view
13-Remote-Desktop-View-2

Sample preview of setup version of builds available on Hadoop Cluster 

14-Components-And-Versions

Google BigQuery Vs HDInsight - Comparison


ComparisonGoogle BigQueryWindows Azure HDInsight
Pricing

BigQuery uses a columnar data structure, which means that for a given query, you are only charged for data processed in each column, not the entire table.
Note: The first 100GB of data processed per month is at no charge.
Only 2 pricing components (query processing, storage)
Priced based on the configuration of Hadoop cluster and storage configuration.
Storage Options
Data can be loaded directly to Tables in BigQuery project.
Note: Recommendation
-to load data files first to Google Cloud Storage and then load data to BigQuery tables.
-Max 4 GB per file
-Max 100 GB per load
-Max 1000 files per load
HDInsight provides two options for storing data
•Windows Azure Blob Storage and
•Hadoop Distributed File system (HDFS)
Data Formats
BigQuery supports two schema types:
A flat schema in CSV or newline-delimited JSON format.
A nested/repeated schema in newline-delimited JSON format.
Supports unstructured data formats
Performance
Very fast in response for the query submitted
Slow in response (waited for several minutes to hours to complete to provide required output)
Best Practices
BigQuery Data Strategies and Best Practices
Big Data Solutions on Windows Azure