Steps by step guide to clone HowToNode node.js Git Repo and run locally

 

Be sure to install Git for Windows from the link below with the following install setting:

–           http://code.google.com/p/msysgit/downloads/list

–           Use Windows Command Line Interface

–           Check Git is in your path

–           Try to execute the git  command

 

Now create a folder where you would want to create node blog i.e. (C:AzureNodeprojectsavkashblog)

 

Run the git command to clone howtonode repo https://github.com/creationix/howtonode.org

 

C:Azurenodeprojectsavkashblog>git clone https://github.com/creationix/howtonode.org

Cloning into ‘howtonode.org’…

remote: Counting objects: 2606, done.

remote: Compressing objects: 100% (1061/1061), done.

remote: Total 2606 (delta 1592), reused 2512 (delta 1507)

Receiving objects: 100% (2606/2606), 2.65 MiB | 559 KiB/s, done.

Resolving deltas: 100% (1592/1592), done.

 

C:Azurenodeprojectsavkashblog>dir howtonode.org

Volume in drive C has no label.

Volume Serial Number is 8464-7B7C

 

Directory of C:Azurenodeprojectsavkashbloghowtonode.org

 

01/21/2012  08:19 PM    <DIR>          .

01/21/2012  08:19 PM    <DIR>          ..

01/21/2012  08:19 PM                21 .gitignore

01/21/2012  08:19 PM               421 .gitmodules

01/21/2012  08:19 PM    <DIR>          articles

01/21/2012  08:19 PM    <DIR>          authors

01/21/2012  08:19 PM               760 description.markdown

01/21/2012  08:19 PM               527 package.json

01/21/2012  08:19 PM             1,704 README.markdown

01/21/2012  08:19 PM    <DIR>          server

01/21/2012  08:19 PM    <DIR>          skin

5 File(s)          3,433 bytes

6 Dir(s)  33,201,917,952 bytes free

 

It is always good idea to take a look at package.json to see the dependency and if there are any dependency then you can run “npm install –d” to install all the dependencies for your project.

Reading the Package.json as below:

 

{

“author”: “Tim Caswell <tim@creationix.com> (http://creationix.com/)”,

“name”: “howtonode.org”,

“description”: “The popular blog howto.no.de”,

“version”: “0.0.0”,

“homepage”: “http://howto.no.de/&#8221;,

“repository”: {

“type”: “git”,

“url”: “git://github.com/creationix/howtonode.org.git”

},

“engines”: {

“node”: “>=0.4.0”

},

“dependencies”: {

“stack”: “>=0.0.3”,

    “creationix”: “>=0.1.2”,

    “wheat”: “>=0.2.0”,

    “cluster”: “>=0.6.4”

},

“devDependencies”: {}

}

 

Based on above you can see there are 4 dependencies 1) stack 2) creationix 3) wheat 4) cluster

 

Now you can run “npm install –d” command to install all the dependencies.

 

C:Azurenodeprojectsavkashbloghowtonode.org>npm install -d

npm info it worked if it ends with ok

npm info using npm@1.1.0-beta-10

npm info using node@v0.6.7

npm info preinstall howtonode.org@0.0.0

npm http GET https://registry.npmjs.org/wheat

npm http GET https://registry.npmjs.org/creationix

npm http GET https://registry.npmjs.org/stack

npm http GET https://registry.npmjs.org/cluster

npm http 304 https://registry.npmjs.org/stack

npm http 304 https://registry.npmjs.org/creationix

npm http 304 https://registry.npmjs.org/wheat

npm http 304 https://registry.npmjs.org/cluster

npm info into C:Azurenodeprojectsavkashbloghowtonode.org stack@0.1.0

npm info into C:Azurenodeprojectsavkashbloghowtonode.org wheat@0.2.5

npm info into C:Azurenodeprojectsavkashbloghowtonode.org creationix@0.3.1

npm info into C:Azurenodeprojectsavkashbloghowtonode.org cluster@0.7.7

npm info installOne stack@0.1.0

npm info installOne wheat@0.2.5

npm info installOne creationix@0.3.1

npm info installOne cluster@0.7.7

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesstack

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheat

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationix

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster

npm info preinstall stack@0.1.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesstack

npm info linkStuff stack@0.1.0

npm info install stack@0.1.0

npm info postinstall stack@0.1.0

npm info preinstall creationix@0.3.1

npm http GET https://registry.npmjs.org/simple-mime

npm info preinstall wheat@0.2.5

npm http GET https://registry.npmjs.org/haml

npm http GET https://registry.npmjs.org/step

npm http GET https://registry.npmjs.org/datetime/0.0.3

npm http GET https://registry.npmjs.org/proto

npm http GET https://registry.npmjs.org/git-fs

npm info preinstall cluster@0.7.7

npm http GET https://registry.npmjs.org/log

npm http GET https://registry.npmjs.org/mkdirp

npm http 304 https://registry.npmjs.org/simple-mime

npm http 304 https://registry.npmjs.org/haml

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationix simple-mime@0.0.4

npm info installOne simple-mime@0.0.4

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationixnode_modulessimple-mime

npm info preinstall simple-mime@0.0.4

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationixnode_modulessimple-mime

npm info linkStuff simple-mime@0.0.4

npm info install simple-mime@0.0.4

npm info postinstall simple-mime@0.0.4

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationix

npm info linkStuff creationix@0.3.1

npm info install creationix@0.3.1

npm info postinstall creationix@0.3.1

npm http 304 https://registry.npmjs.org/proto

npm http 304 https://registry.npmjs.org/datetime/0.0.3

npm http 304 https://registry.npmjs.org/step

npm http 304 https://registry.npmjs.org/log

npm http 304 https://registry.npmjs.org/git-fs

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheathaml@0.4.2

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatsimple-mime@0.0.4

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatproto@0.1.0

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatdatetime@0.0.3

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatstep@0.0.5

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatgit-fs@0.0.7

npm info installOne haml@0.4.2

npm info installOne simple-mime@0.0.4

npm info installOne proto@0.1.0

npm info installOne datetime@0.0.3

npm info installOne step@0.0.5

npm info installOne git-fs@0.0.7

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_moduleshaml

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulessimple-mime

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesproto

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetime

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesstep

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesgit-fs

npm http 304 https://registry.npmjs.org/mkdirp

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster log@1.2.0

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster mkdirp@0.3.0

npm info installOne log@1.2.0

npm info installOne mkdirp@0.3.0

npm info preinstall simple-mime@0.0.4

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesclusternode_moduleslog

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesclusternode_modulesmkdirp

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulessimple-mime

npm info linkStuff simple-mime@0.0.4

npm info install simple-mime@0.0.4

npm info postinstall simple-mime@0.0.4

npm info preinstall proto@0.1.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesproto

npm info linkStuff proto@0.1.0

npm info install proto@0.1.0

npm info postinstall proto@0.1.0

npm info preinstall git-fs@0.0.7

npm info preinstall datetime@0.0.3

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesgit-fs

npm info linkStuff git-fs@0.0.7

npm info install git-fs@0.0.7

npm info postinstall git-fs@0.0.7

npm http GET https://registry.npmjs.org/vows

npm info preinstall step@0.0.5

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesstep

npm info linkStuff step@0.0.5

npm info install step@0.0.5

npm info postinstall step@0.0.5

npm info preinstall log@1.2.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesclusternode_moduleslog

npm info linkStuff log@1.2.0

npm info install log@1.2.0

npm info postinstall log@1.2.0

npm info preinstall mkdirp@0.3.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesclusternode_modulesmkdirp

npm info linkStuff mkdirp@0.3.0

npm info install mkdirp@0.3.0

npm info postinstall mkdirp@0.3.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster

npm info linkStuff cluster@0.7.7

npm info install cluster@0.7.7

npm info postinstall cluster@0.7.7

npm info preinstall haml@0.4.2

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_moduleshaml

npm info linkStuff haml@0.4.2

npm info install haml@0.4.2

npm info postinstall haml@0.4.2

npm http 304 https://registry.npmjs.org/vows

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetime vows@0.6.1

npm info installOne vows@0.6.1

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetimenode_modulesvows

npm info preinstall vows@0.6.1

npm http GET https://registry.npmjs.org/eyes

npm http 304 https://registry.npmjs.org/eyes

npm WARN eyes@0.1.7 dependencies field should be hash of <name>:<version-range>

pairs

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheat

node_modulesdatetimenode_modulesvows eyes@0.1.7

npm info installOne eyes@0.1.7

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetimenode_modulesvowsnode_moduleseyes

npm info preinstall eyes@0.1.7

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetimenode_modulesvowsnode_moduleseyes

npm info linkStuff eyes@0.1.7

npm info install eyes@0.1.7

npm info postinstall eyes@0.1.7

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetimenode_modulesvows

npm info linkStuff vows@0.6.1

npm info install vows@0.6.1

npm info postinstall vows@0.6.1

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheatnode_modulesdatetime

npm info linkStuff datetime@0.0.3

npm info install datetime@0.0.3

npm info postinstall datetime@0.0.3

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheat

npm info linkStuff wheat@0.2.5

npm info install wheat@0.2.5

npm info postinstall wheat@0.2.5

npm info build C:Azurenodeprojectsavkashbloghowtonode.org

npm info linkStuff howtonode.org@0.0.0

npm info install howtonode.org@0.0.0

npm info postinstall howtonode.org@0.0.0

stack@0.1.0 ./node_modules/stack

creationix@0.3.1 ./node_modules/creationix

└── simple-mime@0.0.4

cluster@0.7.7 ./node_modules/cluster

├── log@1.2.0

└── mkdirp@0.3.0

wheat@0.2.5 ./node_modules/wheat

├── simple-mime@0.0.4

├── proto@0.1.0

├── git-fs@0.0.7

├── step@0.0.5

├── haml@0.4.2

└── datetime@0.0.3

npm info ok

 

 

After all the dependencies are installed you can also try to install dependencies for the dependent components.

 

Checking dependencies for wheat:

 

C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheat>npm install -d

 

npm info it worked if it ends with ok

npm info using npm@1.1.0-beta-10

npm info using node@v0.6.7

npm info preinstall wheat@0.2.5

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_moduleswheat

 

npm info linkStuff wheat@0.2.5

npm info install wheat@0.2.5

npm info postinstall wheat@0.2.5

 

npm info ok

 

Checking dependencies for cluster:

 

C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster>npm install -d

npm info it worked if it ends with ok

npm info using npm@1.1.0-beta-10

npm info using node@v0.6.7

npm info preinstall cluster@0.7.7

npm http GET https://registry.npmjs.org/should

npm http 200 https://registry.npmjs.org/should

npm http GET https://registry.npmjs.org/should/-/should-0.2.1.tgz

npm http 200 https://registry.npmjs.org/should/-/should-0.2.1.tgz

npm info shasum 5456ca01063d3abeb26b9fe4c918c517deee058d

npm info shasum C:UsersavkashcAppDataLocalTempnpm-13272063206331327206320

633-0.4006785706151277tmp.tgz

npm info shasum 05e57b5442819a362721b32b713ee680fce94f01

npm info shasum C:UsersavkashcAppDataRoamingnpm-cacheshould.2.1package.tgz

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster should@0.2.1

npm info installOne should@0.2.1

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesclusternode_modulesshould

npm info preinstall should@0.2.1

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesclusternode_modulesshould

npm info linkStuff should@0.2.1

npm info install should@0.2.1

npm info postinstall should@0.2.1

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescluster

npm info linkStuff cluster@0.7.7

npm info install cluster@0.7.7

npm info postinstall cluster@0.7.7

should@0.2.1 ./node_modules/should

npm info ok

 

Checking dependencies for creationix

 

C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationix>npm install -d

npm info it worked if it ends with ok

npm info using npm@1.1.0-beta-10

npm info using node@v0.6.7

npm info preinstall creationix@0.3.1

npm http GET https://registry.npmjs.org/stack

npm http 304 https://registry.npmjs.org/stack

npm info into C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationix stack@0.1.0

npm info installOne stack@0.1.0

npm info unbuild C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationixnode_modulesstack

npm info preinstall stack@0.1.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationixnode_modulesstack

npm info linkStuff stack@0.1.0

npm info install stack@0.1.0

npm info postinstall stack@0.1.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulescreationix

npm info linkStuff creationix@0.3.1

npm info install creationix@0.3.1

npm info postinstall creationix@0.3.1

stack@0.1.0 ./node_modules/stack

npm info ok

 

Checking dependencies for stack:

 

C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesstack>npm install -d

 

npm info it worked if it ends with ok

npm info using npm@1.1.0-beta-10

npm info using node@v0.6.7

npm info preinstall stack@0.1.0

npm info build C:Azurenodeprojectsavkashbloghowtonode.orgnode_modulesstack

 

npm info linkStuff stack@0.1.0

npm info install stack@0.1.0

npm info postinstall stack@0.1.0

 

npm info ok

 

If you look serverserver.js, you will see the web server start code is already there as below:

// Just a basic server setup for this site

var Stack = require(‘stack’),

Creationix = require(‘creationix’),

Http = require(‘http’);

 

Http.createServer(Stack(

Creationix.log(),

require(‘wheat’)(process.env.JOYENT ? process.env.HOME + “/howtonode” : __dirname +”/..”)

)).listen(process.env.JOYENT ? 80 : 8080);

 

Because all the articles are stored in article folder so edit

 

skinindex.haml as below:

#main.index

:each article in articles.slice(0,15)

.article

.author

%img{src:gravitar(article.author.email, 30)}

By #{article.author.name}

.date{title: article.date}&= formatDate(article.date, “%Y.%m.%d”)

%h3

%a{href: “/articles/” + article.name}&= article.title

= intro(article.markdown)

%a.more{href: “/articles/” + article.name} Read more…

 

#sidebar

.aside

= markdownEncode(description)

.bubble

%h4

Articles

%ul

:each article in articles.slice(0,20)

%li

%a{href: “/articles/” + article.name}&=article.title

&=” by ” + article.author.name

:if article.node

%span.versiontag&= article.node

.bubble= markdownEncode(description)

 

 

To launch the web server just try:

C:Azurenodeprojectsavkashbloghowtonode.orgserver>node server.js

GET / 200 Content-Type=text/html; charset=utf-8 Content-Length=24235

GET /style.css 200 Content-Type=text/css Content-Length=11613

GET /groovepaper.png 200 Content-Type=image/png Content-Length=40723

GET /print.css 200 Content-Type=text/css Content-Length=254

GET / 200 Content-Type=text/html; charset=utf-8 Content-Length=24235

GET /style.css 200 Content-Type=text/css Content-Length=11613

GET /groovepaper.png 200 Content-Type=image/png Content-Length=40723

GET /print.css 200 Content-Type=text/css Content-Length=254

GET /articles/testing-private-state-and-mocking-deps 404 Content-Type=text/plain

 

GET /favicon.ico 200 Content-Type=image/vnd.microsoft.icon Content-Length=1469

GET /favicon.ico 200 Content-Type=image/vnd.microsoft.icon Content-Length=1469

GET /articles/testing-private-state-and-mocking-deps 404 Content-Type=text/plain

 

GET /articles/promises 404 Content-Type=text/plain

GET /articles/promises 404 Content-Type=text/plain

GET /favicon.ico 200 Content-Type=image/vnd.microsoft.icon Content-Length=1469

 

Finally launch the browser and test the site at http://127.0.0.1:8080 as below:

 

 

 

Building Node.js source in Windows 7 64bit Machine

Prerequisite: 

  • Be sure to have Visual Studio installed in your machine or at least VC build components.
  • Install Python 2.x (for example C:Python2.7.2)
  • Now download or git node source in your machine (for example C:azurenode-v0.6.7)

Start building:

  1. Add C:Python2.7.2 in your system path
  2. Launch Visual Studio command prompt 32bit (x86)
  3. Run >vcbuild.bat release   – to build release version of node.
  4. Run >vcbuild.bat debug     – to build release version of node.

Note:  if you have CYGWIN install then try to remove the CYGWIN folder path during your build process.

If you want to launch VS environment directly from command prompt use:

  1. Open Command prompt
  2. Now run the following command at your command prompt
    1. “”C:Program Files (x86)Microsoft Visual Studio 10.0VCvcvarsall.bat”” x86
    2. Above command will set Visual Studio environment

What is NoSQL?

This name was first coined in 1998 by Carlo Strozzi for its lightweight open source relational database which simply didn’t expose an SQL interface.

The First and OnlyNoSQL.

NoSQL RDBMS

There are, since then, many Non-Relational, Distributed, open source, database effort. In 2009, Eric Evans reintroduced the term as a RDBS anti-pattern in an event to discuss all those databases that not only don’t use SQL language but in fact are not Relational at all.

From then on, the most common interpretation of “NoSQL” is “non-relational”.

Let’s go and more technically define NoSQL.

  • NoSQL systems are designed for clusters, so they tolerate hardware failures by keeping backup copies of the data on separate physical servers.
  • NoSQL systems avoid going to disks when answering complex queries. Frequently, they have pre-sorted the data and loaded it into the RAM of several servers in a cluster.
  • NoSQL systems perform write, delete, and update functions to unstructured data, much as relational systems work on structured tables.
  • Queries are directed by MapReduce style guidance systems to the data and an associated processor.
  • NoSQL systems are being built by Web site developers or cloud service providers, not by database architects and administrators.
  • What NoSQL lacks in precision it makes up for in speed.
  • NoSQL systems could perhaps be better called Distributed Database Management Systems (or DDBMSes).
  • Instead of having tables with columns and rows like you would find in a traditional RDBMS, many NoSQL databases are based on hash table structure.
  • Recently, column-oriented NoSQL databases have started to show up as well.
  • NoSQL systems are being considered schema free, which means we can simply start working and create the data structure on the fly.

What prevails in NoSQL system:

  • Massive scalability
  • Low latency
  • Ability to grow on demand
  • An easier programming model

 

The NoSQL universe

NoSQL Databases

According to the implementation characteristics, NoSQL databases could be categorized:

Column Oriented

  • Hadoop / HBase; Cassandra; Hypertable; Cloudera; Amazon SimpleDB

Document store

  • MongoDB; CouchDB; Terrastore; ThruDB; OrientDB; Jackrabbit; Lotus Notes; RavenDB; Citrusleaf; SimpleDB; Keyspace

Graph

  • AllegroGraph; Core Data; Neo4j; Sones; DEX; InfoGrid; FlockDB; HyperGraphDB; Bigdata; Infinite Graph; OpenLink Virtuoso; VertexDB

Key/value

  • BigTable; CDB; Citrusleaf; membase; Velocity; Memcachedb; Redis; Tokyo Cabinet; Tuple space; Cassandra; Dynamo; Hibari; Project Voldemort; Paxos algorithm; Keyspace; NMDB; Berkeley DB

Multivalue databases

  • OpenQM; Rocket U2; OpenInsight

Object databases

  • Db4o; GemStone/S; InterSystems Caché; JADE; JOOB; Objectivity/DB; ZODB

Tabular

  • BigTable; Mnesia; Hbase; Hypertable

Tuple store

  • Apache River

Undefined

  • GT.M

 

Resource: http://www.public.traineronrails.com/guides/nosql/pages/01-windows_nosql.htm

Configure OpenSSH host in Windows using Cygwin

Install Cygwin in your Windows machine  and be sure to have the following two modules installed:

  1. OpenSSL
  2. OpenSSH

After Cygwin is installed, launch Cygwin default BASH shell in administrator mode. At the command prompt enter command:

$ssh-host-config

Now you will be prompt for a few yes/no type questions as below:

When asked – “should privilege separation be used.” Please enter “YES”. As it is on by default in standard installations of OpenSSH

When asked – “new local account ‘sshd’?” please enter “Yes”

When asked – “Do you want to install sshd as service”- Please enter “Yes”

When asked – “Enter the value of CYGWIN for the daemon” please enter “ntsec”

Finally you will see some output which on the screen and you will be told that cyg_server account will be used with sshd service.

When asked – “Do you want to use a different name”, please enter “no”

Again when asked – “Create new privileged user account ‘cyg_server’?”, please select “no”.

This step will generate an error however that is expected.

When asked – “Do you want to proceed anyway?” please inter “yes”.

This way SSHD server will run as “SYSTEM” privilege user and that is what we expected.

avkashc@OMSHANTIOM ~$ ssh-host-config

*** Info: Creating default /etc/ssh_config file

*** Info: Creating default /etc/sshd_config file

*** Info: Privilege separation is set to yes by default since OpenSSH 3.3.

*** Info: However, this requires a non-privileged account called ‘sshd’.

*** Info: For more info on privilege separation read /usr/share/doc/openssh/README.privsep.

*** Query: Should privilege separation be used? (yes/no) yes

*** Info: Note that creating a new user requires that the current account have

*** Info: Administrator privileges.  Should this script attempt to create a

*** Query: new local account ‘sshd’? (yes/no) yes

*** Info: Updating /etc/sshd_config file

*** Query: Do you want to install sshd as a service?

*** Query: (Say “no” if it is already installed as a service) (yes/no) yes

*** Query: Enter the value of CYGWIN for the daemon: [] ntsec

*** Info: On Windows Server 2003, Windows Vista, and above, the

*** Info: SYSTEM account cannot setuid to other users — a capability

*** Info: sshd requires.  You need to have or to create a privileged

*** Info: account.  This script will help you do so.

*** Info: You appear to be running Windows XP 64bit, Windows 2003 Server,

*** Info: or later.  On these systems, it’s not possible to use the LocalSystem

*** Info: account for services that can change the user id without an

*** Info: explicit password (such as passwordless logins [e.g. public key

*** Info: authentication] via sshd).

*** Info: If you want to enable that functionality, it’s required to create

*** Info: a new account with special privileges (unless a similar account

*** Info: already exists). This account is then used to run these special

*** Info: servers.

*** Info: Note that creating a new user requires that the current account

*** Info: have Administrator privileges itself.

*** Info: No privileged account could be found.

*** Info: This script plans to use ‘cyg_server’.

*** Info: ‘cyg_server’ will only be used by registered services.

*** Query: Do you want to use a different name? (yes/no) no

*** Query: Create new privileged user account ‘cyg_server’? (yes/no) no

*** ERROR: There was a serious problem creating a privileged user.

*** Query: Do you want to proceed anyway? (yes/no) yes

*** Warning: Expected privileged user ‘cyg_server’ does not exist.

*** Warning: Defaulting to ‘SYSTEM’

*** Info: The sshd service has been installed under the LocalSystem

*** Info: account (also known as SYSTEM). To start the service now, call

*** Info: `net start sshd’ or `cygrunsrv -S sshd’.  Otherwise, it

*** Info: will start automatically after the next reboot.

*** Warning: Host configuration exited with 1 errors or warnings!

*** Warning: Make sure that all problems reported are fixed,

*** Warning: then re-run ssh-host-config.

 

Now re-run ssh-host-config and when asked to overwrite configuration file, please enter “yes” and select “no” for privilege separation.

You will a message saying SSHD service is installed in your machine as below:

avkashc@OMSHANTIOM ~$ ssh-host-config

*** Query: Overwrite existing /etc/ssh_config file? (yes/no) yes

*** Info: Creating default /etc/ssh_config file

*** Query: Overwrite existing /etc/sshd_config file? (yes/no) yes

*** Info: Creating default /etc/sshd_config file

*** Info: Privilege separation is set to yes by default since OpenSSH 3.3.

*** Info: However, this requires a non-privileged account called ‘sshd’.

*** Info: For more info on privilege separation read /usr/share/doc/openssh/README.privsep.

*** Query: Should privilege separation be used? (yes/no) no

*** Info: Updating /etc/sshd_config file

*** Info: Sshd service is already installed.

*** Info: Host configuration finished. Have fun!

 

Now go to administrator control panel and launch services. You will see CYGWIN sshd is installed and not running as below:

Now you can go ahead and start the CYGWIN sshd service as usual. While starting CYGWIN sshd service above, be sure you done need to provide any password.

Alternatively you can use the following command to start the SSHD service from Cygwin shell:

$ net start sshd

To finish the remaining steps to generate key please run:

$ssh-keygen

When asked please enter “no” passphrase (two times, just press ENTER):

avkashc@OMSHANTIOM ~$ ssh-keygen

Generating public/private rsa key pair.

Enter file in which to save the key (/home/avkashc/.ssh/id_rsa):

Created directory ‘/home/avkashc/.ssh’.

Enter passphrase (empty for no passphrase):

Enter same passphrase again:

Your identification has been saved in /home/avkashc/.ssh/id_rsa.

Your public key has been saved in /home/avkashc/.ssh/id_rsa.pub.

The key fingerprint is:

******************************** avkashc@OMSHANTIOM

The key’s randomart image is:

+–[ RSA 2048]—-+

********************

********************

********************

Finally run the following command to complete the setup:

avkashc@OMSHANTIOM ~

$ cd ~/.ssh

avkashc@OMSHANTIOM ~/.ssh

$ ls -l

total 5

-rw——- 1 avkashc mkgroup 1675 Jan 12 22:18 id_rsa

-rw-r–r– 1 avkashc mkgroup  400 Jan 12 22:18 id_rsa.pub

avkashc@OMSHANTIOM ~/.ssh

$ cat id_rsa.pub >> authorized_keys

avkashc@OMSHANTIOM ~/.ssh

$ ssh localhost

The authenticity of host ‘localhost (::1)’ can’t be established.

ECDSA key fingerprint is ***********************************.

Are you sure you want to continue connecting (yes/no)? yes

Warning: Permanently added ‘localhost’ (ECDSA) to the list of known hosts.

avkashc@OMSHANTIOM ~/.ssh

$ ssh localhost

Connection closed by ::1

avkashc@OMSHANTIOM ~/.ssh

$

To perform user configuration for OpenSSH please use:

$ ssh-user-config

Resources:

Running ANT in Cygwin returns warning – MS-DOS style path detected

If you run ant in Cygwin and get warning as below:

 

$ ant

cygwin warning:

MS-DOS style path detected: C:hadoopapache-ant-1.8.2

Preferred POSIX equivalent is: /cygdrive/c/hadoop/apache-ant-1.8.2

CYGWIN environment variable option “nodosfilewarning” turns off this warning.

Consult the user’s guide for more details about POSIX paths:

http://cygwin.com/cygwin-ug-net/using.html#using-pathnames

Buildfile: build.xml does not exist!

Build failed

 

 

To solve this problem:

–           Just Remove ANT_HOME environment from the computer environment variable.

 

SVN checkout list of Hadoop Core Components Source

Hadoop Core Components:

HDFS:

MapReduce:

Hadoop-Common:

Pig

HBase

Mahout:

ZooKeeper:

BookKeeper:

Other Hadoop Components:

Hadoop-Yarn