<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>A glass case of thoughts &#187; linux</title>
	<atom:link href="http://jyotsna.philogy.com/tag/linux/feed/" rel="self" type="application/rss+xml" />
	<link>http://jyotsna.philogy.com</link>
	<description>Brain munch illustrated</description>
	<lastBuildDate>Wed, 24 Mar 2010 05:49:00 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>linux: handy commands</title>
		<link>http://jyotsna.philogy.com/2009/03/linux-handy-commands/</link>
		<comments>http://jyotsna.philogy.com/2009/03/linux-handy-commands/#comments</comments>
		<pubDate>Wed, 18 Mar 2009 06:10:08 +0000</pubDate>
		<dc:creator>Jyotsna</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[copy files]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[linux handy commands]]></category>
		<category><![CDATA[open shell]]></category>
		<category><![CDATA[scp]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[utility commands]]></category>

		<guid isPermaLink="false">http://jyotsna.philogy.com/?p=274</guid>
		<description><![CDATA[
copy files from one linux server to another through shell

$ scp user@from_computer:dir/filename user@to_computer:dir/filename


open shell to another linux machine from one through shell

$ ssh user@to_computer


Prints the owner of every file or directory in the current directory. The AWK syntax is simply &#8220;print the 3rd field in every line of data&#8221;

ls -l &#124; awk '{print $3}'


To get [...]]]></description>
			<content:encoded><![CDATA[<ol>
<li>copy files from one linux server to another through shell

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">$ scp user@from_computer:dir/filename user@to_computer:dir/filename</pre></div></div>

</li>
<li>open shell to another linux machine from one through shell

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">$ ssh user@to_computer</pre></div></div>

</li>
<li>Prints the owner of every file or directory in the current directory. The AWK syntax is simply &#8220;print the 3rd field in every line of data&#8221;

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">ls -l | awk '{print $3}'</pre></div></div>

</li>
<li>To get the owner of only one file (filename):

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">ls -l | grep filename | awk '{print $3}'</pre></div></div>

</li>
<li>To compress a folder:

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">zip -r target.zip folder/</pre></div></div>

</li>
<li>User creation

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">useradd username</pre></div></div>

</li>
<li>Change user password

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">passwd username</pre></div></div>

</li>
<li>Add user to a group

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">usermod -g grpname username</pre></div></div>

</li>
<li>Import SQL script to an empty mysql database

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">mysql -u root -p database_name &lt; script_file.sql</pre></div></div>

</li>
<li>Unfreeze vi editor in terminal window when frozen because of ctrl+S action

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">press ctrl+q</pre></div></div>

</li>
<li>Reboot linux server remotely

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">sudo reboot</pre></div></div>

</li>
<li>Shut down linux server remotely

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">sudo shutdown -h now</pre></div></div>

</li>
<li>Kill a process

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">top
type k to kill a process. You will be prompted for the PID of the task, and the signal to send to it. For a normal kill, send signal 15. For a sure, but rather abrupt, kill, send signal 9. The default signal, as with kill(1), is 15, SIGTERM. This command is not available in secure mode.</pre></div></div>

</li>
<li>To close port &#8211; 80 in following example

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">fuser -k 80/tcp</pre></div></div>

</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://jyotsna.philogy.com/2009/03/linux-handy-commands/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>linux how to: replicate svn repository</title>
		<link>http://jyotsna.philogy.com/2009/02/linux-how-to-replicate-svn-repository/</link>
		<comments>http://jyotsna.philogy.com/2009/02/linux-how-to-replicate-svn-repository/#comments</comments>
		<pubDate>Sat, 28 Feb 2009 11:27:22 +0000</pubDate>
		<dc:creator>Jyotsna</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[SVN]]></category>
		<category><![CDATA[copy svn repository]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[subversion|svn replicate]]></category>
		<category><![CDATA[svn repository replicate]]></category>

		<guid isPermaLink="false">http://jyotsna.philogy.com/?p=246</guid>
		<description><![CDATA[Task at hand:
I have a repository on one of the linux server. As a part of upgradation process, we decided to move the SVN server to a newer better linux infrastructure. Task at hand is to replicate the svn repositories on new server.
Solution:

Create dump for existing repository

svnadmin dump /path/to/repo &#62; /path/to/dump/folder/myrepo.dump

This command creates a .dump [...]]]></description>
			<content:encoded><![CDATA[<p><b>Task at hand:</b></p>
<p>I have a repository on one of the linux server. As a part of upgradation process, we decided to move the SVN server to a newer better linux infrastructure. Task at hand is to replicate the svn repositories on new server.</p>
<p><b>Solution:</b></p>
<ol>
<li>Create dump for existing repository

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">svnadmin dump /path/to/repo &gt; /path/to/dump/folder/myrepo.dump</pre></div></div>

<p>This command creates a .dump file and shows the revisions being dumped as it progresses</li>
<li>Transfer the dump file to new server. This can be accomplished through SSH / FTP connection or a simple scp command as:</li>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">scp /path/to/dump/folder/myrepo.dump user@new_server:/path/to/dump/folder/myrepo.dump</pre></div></div>

<li>Log into new server and switch to the directory where you want to place your replicated svn repository. Then, create an empty svn repository

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">svnadmin create myrepo</pre></div></div>

</li>
<li>Load empty reposity with dump file

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">svnadmin load myrepo &lt; /path/to/dump/folder/myrepo.dump</pre></div></div>

</li>
<li>Define group ownership and permission

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">chown -R :all myrepo
chmod -R 770 myrepo</pre></div></div>

</li>
</ol>
<p><strong>Related posts</strong></p>
<ul>
<li><a href="http://jyotsna.philogy.com/2009/05/what-to-do-when-your-svn-client-saves-a-wrong-password/">What to do : When your SVN client saves a wrong password</a></li>
<li><a href="http://jyotsna.philogy.com/2008/12/linux-create-svn-repository/">linux: create svn repository</a></li>
<li><a href="http://jyotsna.philogy.com/2008/12/how-to-make-svn-remember-password/">How to make SVN remember password</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://jyotsna.philogy.com/2009/02/linux-how-to-replicate-svn-repository/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>IIS SSL and linux openSSL</title>
		<link>http://jyotsna.philogy.com/2009/01/iis-ssl-and-openssl/</link>
		<comments>http://jyotsna.philogy.com/2009/01/iis-ssl-and-openssl/#comments</comments>
		<pubDate>Mon, 19 Jan 2009 12:02:36 +0000</pubDate>
		<dc:creator>Jyotsna</dc:creator>
				<category><![CDATA[IIS]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[.NET web service]]></category>
		<category><![CDATA[asmx over https]]></category>
		<category><![CDATA[https]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[openSSL]]></category>
		<category><![CDATA[secure communication]]></category>
		<category><![CDATA[security certificate]]></category>
		<category><![CDATA[Self-Signed IIS SSL Certificates using OpenSSL]]></category>
		<category><![CDATA[SSL]]></category>
		<category><![CDATA[using openssl certificateself in iis]]></category>

		<guid isPermaLink="false">http://jyotsna.philogy.com/?p=183</guid>
		<description><![CDATA[I have a .NET web service that I want to be accessed over https rather than http. Problem is HOW !!
Solution:

Activate SSL on web server (IIS)

Follow steps 1 through 4 of this very useful blog by Eric Longman



Specify the file for which SSL is required

Through inetmgr, browse to the file (in my case the .asmx [...]]]></description>
			<content:encoded><![CDATA[<p>I have a .NET web service that I want to be accessed over https rather than http. Problem is HOW !!</p>
<p>Solution:</p>
<ol>
<li>Activate SSL on web server (IIS)
<ul>
<li>Follow steps 1 through 4 of this very useful blog <a href="http://eal.us/blog/_archives/2003/6/2/25109.html">by Eric Longman</a>
</li>
</ul>
</li>
<li>Specify the file for which SSL is required
<ul>
<li>Through inetmgr, browse to the file (in my case the .asmx file). Right click -> Properties -> File Security -> Secure Communications -> Edit</li>
<li>Check Require SSL Channel (SSL)</li>
<p><br/><br />
<img src="http://jyotsna.philogy.com/wp-content/uploads/2009/01/requiressl-300x282.jpg" alt="RequireSSL" title="requiressl" width="300" height="282" class="size-medium wp-image-192" />
</ul>
</li>
</ol>
<p>And you should be done. </p>
<p><b>Related useful article:</b><br />
<a href="http://weblogs.asp.net/jan/archive/2003/12/04/41154.aspx">CONSUMING WEBSERVICES OVER HTTPS (SSL)</a></p>
]]></content:encoded>
			<wfw:commentRss>http://jyotsna.philogy.com/2009/01/iis-ssl-and-openssl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to make SVN remember password</title>
		<link>http://jyotsna.philogy.com/2008/12/how-to-make-svn-remember-password/</link>
		<comments>http://jyotsna.philogy.com/2008/12/how-to-make-svn-remember-password/#comments</comments>
		<pubDate>Sat, 06 Dec 2008 09:54:24 +0000</pubDate>
		<dc:creator>Jyotsna</dc:creator>
				<category><![CDATA[SVN]]></category>
		<category><![CDATA[how to save password for svn+ssh]]></category>
		<category><![CDATA[id_dsa]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[linux remember password svn]]></category>
		<category><![CDATA[linux svn password]]></category>
		<category><![CDATA[make tortoisesvn remember]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[remember]]></category>
		<category><![CDATA[remember password]]></category>
		<category><![CDATA[remember password svn]]></category>
		<category><![CDATA[svn save password]]></category>
		<category><![CDATA[svn tortoise "save password"]]></category>
		<category><![CDATA[svn+ssh]]></category>
		<category><![CDATA[tortoise svn]]></category>
		<category><![CDATA[tortoise svn remember password]]></category>
		<category><![CDATA[tortoiseSVN]]></category>

		<guid isPermaLink="false">http://jyotsna.philogy.com/?p=12</guid>
		<description><![CDATA[Who is this post for?
 This post is for anyone who wants a step by step guide to accomplish any of the following

Make a SVN client like tortoise svn remember password
Make linux server remember your password when logging through putty

Tools you need:

Putty
Puttygen

What you need to do:

Using putty &#8211; login to linux server. change directory to [...]]]></description>
			<content:encoded><![CDATA[<p><b>Who is this post for?</b></p>
<p> This post is for anyone who wants a step by step guide to accomplish any of the following</p>
<ol>
<li>Make a SVN client like tortoise svn remember password</li>
<li>Make linux server remember your password when logging through putty</li>
</ol>
<p><b>Tools you need:</b></p>
<ul>
<li>Putty</li>
<li>Puttygen</li>
</ul>
<p><b>What you need to do:</b></p>
<ol>
<li>Using putty &#8211; login to linux server. change directory to ~/.ssh/ by typing following command</li>

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">cd ~/.ssh</pre></div></div>

<li>Type command

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">ssh-keygen -b 1024 -t dsa</pre></div></div>

<p>and press enter. Do not enter a passphrase. Hit enter when prompted for one. Same for the filename. default filename = <em>id_dsa</em> and <em>id_dsa.pub</em>. id_dsa is the private key file and id_dsa.pub is the public key file.</li>
<li>type command

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">cat ~/.ssh/id_dsa.pub</pre></div></div>

<p>Copy the output to the clipboard by selecting the output by mouse.</li>
<li>Type command

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">vi ~/.ssh/authorized_keys</pre></div></div>

<p>Hit <em>i</em> to enter Insert mode and then paste your public key (if there is already a key in this file, move to the bottom before pasting). Hit the ESC key to leave Insert mode and type <em>:wq</em> and hit enter to save and exit vi editor.</li>
<li>Using ftp download your key files &#8211; both private and public</li>
<p><br/></p>
<li>In order to use the private key we get from the server, we have to convert it to a putty format. This is because the private key file format is not specified by some standard body. We can accomplish this using puttygen. Open Puttygen</li>
<p><br/></p>
<li>In the tree structure on left, choose conversion -&gt; import key -&gt; choose the private key file downloaded from ftp</li>
<p><br/></p>
<li>Choose to save private key. Choose path and save the file as anything.ppk</li>
<p><br/></p>
<li>Run Putty. Specify parameters
<ul>
<li>Session-&gt;HostName: Hostname or IP Adress of your server</li>
<li>Session-&gt;Protocol: SSH</li>
<li>Session-&gt;Saved Sessions: MyConnection</li>
<li>SSH-&gt;Prefered SSH Protocol version: 2</li>
<li>SSH-&gt;Auth-&gt;Private Key file for auth: $PATH$mykey.PKK (replace $PATH$ with real path to the mykey.PKK file)</li>
</ul>
</li>
<li>Go back to Session tab and hit “save” button. You will see “MyConnection” in the list of available connections.</li>
<p><br/></p>
<li>Next click “open” and you should see a telnet login prompt. Use “myuser” as username (without double quotes of course) and if everything is OK, you don’t have to provide a password to your system. If the system still requires a password, something went wrong.</li>
<p><br/></p>
<li>Now that linux server and putty manage to remember your password, you need an application client to use it. In this case it is SVN client e.g. tortoise svn. Go to TortoiseSVN-&gt;RepoBrowser and specify a URL like this:

<div class="wp_syntax"><div class="code"><pre class="text" style="font-family:monospace;">svn+ssh://myuser@MyConnection/usr/local/repos</pre></div></div>

<p>&#8230;where MyConnection is the putty session name and /usr/local/repos is my svn repository on linux server</li>
</ol>
<p>And you are done &#8230;</p>
<p><strong>Related posts</strong></p>
<ul>
<li><a href="http://jyotsna.philogy.com/2009/05/what-to-do-when-your-svn-client-saves-a-wrong-password/">What to do : When your SVN client saves a wrong password</a></li>
<li><a href="http://jyotsna.philogy.com/2009/02/linux-how-to-replicate-svn-repository/">linux how to: replicate svn repository</a></li>
<li><a href="http://jyotsna.philogy.com/2008/12/linux-create-svn-repository/">linux: create svn repository</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://jyotsna.philogy.com/2008/12/how-to-make-svn-remember-password/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
