<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Srini's Point of View</title>
	
	<link>http://www.nyayapati.com/srao</link>
	<description>My thoughts on technology, travel, food and movies…</description>
	<lastBuildDate>Wed, 19 Oct 2011 04:04:38 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/SrinisPointOfView" /><feedburner:info uri="srinispointofview" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Tandoori Style Butter Chicken at Trader Joe’s</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/Eur55fc1_kw/</link>
		<comments>http://www.nyayapati.com/srao/2011/10/tandoori-style-butter-chicken-at-trader-joes/#comments</comments>
		<pubDate>Wed, 19 Oct 2011 04:04:38 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/2011/10/tandoori-style-butter-chicken-at-trader-joes/</guid>
		<description><![CDATA[<p></p>


<p>No related posts.</p>
<p>Related posts brought to you by Yet Another Related Posts Plugin.</p>


No related posts.

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.nyayapati.com/srao/wp-content/uploads/2011/10/20111019-000337.jpg" rel="lightbox[625]"><img src="http://www.nyayapati.com/srao/wp-content/uploads/2011/10/20111019-000337.jpg" alt="20111019-000337.jpg" class="alignnone size-full" /></a></p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F10%2Ftandoori-style-butter-chicken-at-trader-joes%2F&amp;title=Tandoori%20Style%20Butter%20Chicken%20at%20Trader%20Joe%26%238217%3Bs" id="wpa2a_2"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/Eur55fc1_kw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/10/tandoori-style-butter-chicken-at-trader-joes/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/10/tandoori-style-butter-chicken-at-trader-joes/</feedburner:origLink></item>
		<item>
		<title>Time Machine backup to an SMB share</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/mObUXPBf9lA/</link>
		<comments>http://www.nyayapati.com/srao/2011/06/time-machine-backup-to-an-smb-share/#comments</comments>
		<pubDate>Thu, 16 Jun 2011 18:55:07 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[MacOSX]]></category>
		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=592</guid>
		<description><![CDATA[<p>If you wanted Time Machine to work with a SMB share you will notice that it doesn&#8217;t work. To get it to work run the following command on the terminal </p>

defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1

<p>Now mount your SMB share. The best way to do this is to click on Go->connect to server in the finder [...]


Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/ssh-aliases/' rel='bookmark' title='SSH aliases'>SSH aliases</a> <small>I constantly connect to linux or unix machines using ssh...</small></li>
<li><a href='http://www.nyayapati.com/srao/2011/03/mamp-mysqlcheck-got-error-1045/' rel='bookmark' title='MAMP &#8211; mysqlcheck: Got error: 1045'>MAMP &#8211; mysqlcheck: Got error: 1045</a> <small>I started seeing the following error every time I started...</small></li>
</ol>

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>If you wanted Time Machine to work with a SMB share you will notice that it doesn&#8217;t work. To get it to work run the following command on the terminal </p>
<pre class="brush: bash; title: ; notranslate">
defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
</pre>
<p>Now mount your SMB share. The best way to do this is to click on Go->connect to server in the finder menubar. For the server name you enter smb://username:password@servername/ShareName. I have a NAS share which has a Guest account with no password so my address looks like smb://Guest:@MyServer/HomeShare/TimeMachineBackup. Notice I have no password as no password is required for the Guest account.<br />
Once mounted, Control click on the Time machine in the Dock and select &#8220;Time Machine Preferences&#8221;. Once you select &#8220;Choose Backup Disk&#8221; you should see your SMB Share. Select your SMB share and start your Time Share.<br />
Once Time Machine backup starts, you will see an error saying that it cannot create image error. This error message was expected as Time machine could not create a file called a sparsebundle which is required for it to work on the SMB share. For this to work correctly we will be creating the sparsebundle manually. Turn off Time machine and go on to the next step.</p>
<p>In your terminal find your mac address. You can do this with the following command</p>
<pre class="brush: bash; title: ; notranslate">
ifconfig en0 | grep ether
</pre>
<p>Make a note of the mac address without the colon symbol. For this example lets assume my MAC address is 000000000000. Decide on how big you want your Time Machine backup to be. Then run the hdiutil command to create your sparsebundle file. Here is the command I created for a 200 Gigs share -</p>
<pre class="brush: bash; title: ; notranslate">
hdiutil create -size 200g -fs HFS+J -volname “OSX Backup” mymac_000000000000.sparsebundle
</pre>
<p>Where 000000000000 is my mac address and mymac is my mac name. </p>
<p>Now copy the sparsebundle file to the Nas share you want for your backups. In my case I copied it to the TimeMachineBackup folder on my NAS Share. </p>
<p>Go back to Time machine preferences and turn on Time machine. You should now see that the backup starts up with no problems. Depending on what you are backing up, the first time it runs it might take some time.</p>
<p>An important point to note is that for this to work your NAS Share needs to be mounted. You can set Time machine to be manual so that way you can make sure your SMB share is mounted before you click on the backup button.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F06%2Ftime-machine-backup-to-an-smb-share%2F&amp;title=Time%20Machine%20backup%20to%20an%20SMB%20share" id="wpa2a_4"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/ssh-aliases/' rel='bookmark' title='SSH aliases'>SSH aliases</a> <small>I constantly connect to linux or unix machines using ssh...</small></li>
<li><a href='http://www.nyayapati.com/srao/2011/03/mamp-mysqlcheck-got-error-1045/' rel='bookmark' title='MAMP &#8211; mysqlcheck: Got error: 1045'>MAMP &#8211; mysqlcheck: Got error: 1045</a> <small>I started seeing the following error every time I started...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/mObUXPBf9lA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/06/time-machine-backup-to-an-smb-share/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/06/time-machine-backup-to-an-smb-share/</feedburner:origLink></item>
		<item>
		<title>Super Secret features and shortcuts for your MAC</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/JF83o8NM0F8/</link>
		<comments>http://www.nyayapati.com/srao/2011/05/super-secret-features-and-shortcuts-for-your-mac/#comments</comments>
		<pubDate>Wed, 18 May 2011 19:28:18 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=584</guid>
		<description><![CDATA[<p>http://mac.appstorm.net/how-to/os-x/30-super-secret-os-x-features-and-shortcuts/</p>


<p>No related posts.</p>
<p>Related posts brought to you by Yet Another Related Posts Plugin.</p>


No related posts.

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>http://mac.appstorm.net/how-to/os-x/30-super-secret-os-x-features-and-shortcuts/</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F05%2Fsuper-secret-features-and-shortcuts-for-your-mac%2F&amp;title=Super%20Secret%20features%20and%20shortcuts%20for%20your%20MAC" id="wpa2a_6"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/JF83o8NM0F8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/05/super-secret-features-and-shortcuts-for-your-mac/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/05/super-secret-features-and-shortcuts-for-your-mac/</feedburner:origLink></item>
		<item>
		<title>terminal tips and tricks for Mac OS X</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/1vSlCCISXpQ/</link>
		<comments>http://www.nyayapati.com/srao/2011/05/terminal-tips-and-tricks-for-mac-os-x/#comments</comments>
		<pubDate>Thu, 12 May 2011 19:26:35 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[MacOSX]]></category>
		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=580</guid>
		<description><![CDATA[<p>Some interesting tips and tricks for Mac OS X
http://apple.stackexchange.com/questions/5435/terminal-tips-and-tricks-for-mac-os-x</p>


<p>Related posts:Mac Book Pro terminal prompt keeps changing It got really annoying for me to see how my...
</p>
<p>Related posts brought to you by Yet Another Related Posts Plugin.</p>


Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/05/mac-book-pro-terminal-prompt-keeps-changing/' rel='bookmark' title='Mac Book Pro terminal prompt keeps changing'>Mac Book Pro terminal prompt keeps changing</a> <small>It got really annoying for me to see how my...</small></li>
</ol>

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>Some interesting tips and tricks for Mac OS X<br />
<a href="http://apple.stackexchange.com/questions/5435/terminal-tips-and-tricks-for-mac-os-x">http://apple.stackexchange.com/questions/5435/terminal-tips-and-tricks-for-mac-os-x</a></p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F05%2Fterminal-tips-and-tricks-for-mac-os-x%2F&amp;title=terminal%20tips%20and%20tricks%20for%20Mac%20OS%20X" id="wpa2a_8"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/05/mac-book-pro-terminal-prompt-keeps-changing/' rel='bookmark' title='Mac Book Pro terminal prompt keeps changing'>Mac Book Pro terminal prompt keeps changing</a> <small>It got really annoying for me to see how my...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/1vSlCCISXpQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/05/terminal-tips-and-tricks-for-mac-os-x/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/05/terminal-tips-and-tricks-for-mac-os-x/</feedburner:origLink></item>
		<item>
		<title>Mac Book Pro terminal prompt keeps changing</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/b5_MNpONHRw/</link>
		<comments>http://www.nyayapati.com/srao/2011/05/mac-book-pro-terminal-prompt-keeps-changing/#comments</comments>
		<pubDate>Tue, 03 May 2011 15:00:58 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[MacOSX]]></category>
		<category><![CDATA[mac]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=577</guid>
		<description><![CDATA[<p>It got really annoying for me to see how my terminal prompt kept changing when I connected my Macbook from work. I know I can easily fix this by setting my prompt in my .profile file, but I wanted to find out why this was happening.</p>
<p>It turns out the culprit is DHCP. By Default the [...]


Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/ssh-aliases/' rel='bookmark' title='SSH aliases'>SSH aliases</a> <small>I constantly connect to linux or unix machines using ssh...</small></li>
</ol>

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>It got really annoying for me to see how my terminal prompt kept changing when I connected my Macbook from work. I know I can easily fix this by setting my prompt in my .profile file, but I wanted to find out why this was happening.</p>
<p>It turns out the culprit is DHCP. By Default the hostname is determined dynamically on your macbook. This setting can be controlled with your /etc/hostconfig file. Here is what it looks like on my laptop -</p>
<pre class="brush: bash; title: ; notranslate">
# This file is going away

AFPSERVER=-NO-
AUTHSERVER=-NO-
TIMESYNC=-NO-
QTSSERVER=-NO-
</pre>
<p>To hard code a hostname, I just added &#8220;HOSTNAME=MyMacBook&#8221; (without the quotes) to the end of the file.<br />
Some might consider the changing hostname a feature they might want. Not me <img src='http://www.nyayapati.com/srao/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F05%2Fmac-book-pro-terminal-prompt-keeps-changing%2F&amp;title=Mac%20Book%20Pro%20terminal%20prompt%20keeps%20changing" id="wpa2a_10"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/ssh-aliases/' rel='bookmark' title='SSH aliases'>SSH aliases</a> <small>I constantly connect to linux or unix machines using ssh...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/b5_MNpONHRw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/05/mac-book-pro-terminal-prompt-keeps-changing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/05/mac-book-pro-terminal-prompt-keeps-changing/</feedburner:origLink></item>
		<item>
		<title>Convert uploaded file with windows line ending to unix line ending using php</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/PAACVf97vG4/</link>
		<comments>http://www.nyayapati.com/srao/2011/04/convert-uploaded-file-with-windows-line-ending-to-unix-line-ending-using-php/#comments</comments>
		<pubDate>Fri, 01 Apr 2011 15:56:40 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=567</guid>
		<description><![CDATA[<p>I was working on a php project which involved in uploading a tab delimited file and then processing it with php on a unix webserver to insert data into a database. The file was produced on a windows machine and so it had windows line endings. I used this trick to strip off the carriage [...]


Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/' rel='bookmark' title='Join multiple mpg files into one file'>Join multiple mpg files into one file</a> <small>I did not realize how easy it is to join...</small></li>
</ol>

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>I was working on a php project which involved in uploading a tab delimited file and then processing it with php on a unix webserver to insert data into a database. The file was produced on a windows machine and so it had windows line endings. I used this trick to strip off the carriage return and line feed characters from each line of the file<br /> <br />
Here is my html form code </p>
<pre class="brush: xml; title: ; notranslate">
	&lt;form action=&quot;process.php&quot; method=&quot;post&quot; enctype=&quot;multipart/form-data&quot; name=&quot;import_form&quot;&gt;
		&lt;input type=&quot;hidden&quot; name=&quot;action&quot; value=&quot;import&quot;&gt;
		&lt;input type=&quot;file&quot; name=&quot;import_file&quot;&gt;
		&lt;br&gt;
		&lt;input type=&quot;button&quot; value=&quot;Import&quot;&gt;
	&lt;/form&gt;
</pre>
<p>Here is my code for process.php</p>
<pre class="brush: php; title: ; notranslate">
if(isset($_POST['action']) &amp;&amp; ($_POST['action'] == 'import')) {
	if (is_uploaded_file($_FILES['import_file']['tmp_name'])) {

		//	Move the file into an accessible location.
		$buffer = trim(implode(&quot;&quot;,file($_FILES['import_file']['tmp_name'])));

		// Convert all line-endings to UNIX format
        $buffer = str_replace(&quot;\r\n&quot;, &quot;\n&quot;, $buffer);
        $buffer = str_replace(&quot;\r&quot;, &quot;\n&quot;, $buffer);

        //code for processing $buffer

	else {
		echo &quot;&lt;p class=\&quot;Error\&quot;&gt;File Upload Failed.&lt;/p&gt;&quot;;
	}
}
</pre>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F04%2Fconvert-uploaded-file-with-windows-line-ending-to-unix-line-ending-using-php%2F&amp;title=Convert%20uploaded%20file%20with%20windows%20line%20ending%20to%20unix%20line%20ending%20using%20php" id="wpa2a_12"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/' rel='bookmark' title='Join multiple mpg files into one file'>Join multiple mpg files into one file</a> <small>I did not realize how easy it is to join...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/PAACVf97vG4" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/04/convert-uploaded-file-with-windows-line-ending-to-unix-line-ending-using-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/04/convert-uploaded-file-with-windows-line-ending-to-unix-line-ending-using-php/</feedburner:origLink></item>
		<item>
		<title>Argument list too long</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/L1cdoqXvmPQ/</link>
		<comments>http://www.nyayapati.com/srao/2011/03/argument-list-too-long/#comments</comments>
		<pubDate>Wed, 30 Mar 2011 00:02:07 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[unix/linux]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=564</guid>
		<description><![CDATA[<p>Ever tried to copy or move a bunch of files on unix/linux from one location to another and see this error message spit out back at you?? </p>

$ cp /var/www/* /var/tmp
-bash: /bin/cp: Argument list too long

<p>UNIX find to the rescue&#8230;</p>

$ find /var/www -type f -name '*' -exec cp {} /var/tmp/. \;

<p>problem solved!</p>


<p>Related posts:Join multiple mpg [...]


Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/' rel='bookmark' title='Join multiple mpg files into one file'>Join multiple mpg files into one file</a> <small>I did not realize how easy it is to join...</small></li>
<li><a href='http://www.nyayapati.com/srao/2011/03/ssh-aliases/' rel='bookmark' title='SSH aliases'>SSH aliases</a> <small>I constantly connect to linux or unix machines using ssh...</small></li>
</ol>

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>Ever tried to copy or move a bunch of files on unix/linux from one location to another and see this error message spit out back at you?? </p>
<pre class="brush: bash; title: ; notranslate">
$ cp /var/www/* /var/tmp
-bash: /bin/cp: Argument list too long
</pre>
<p>UNIX find to the rescue&#8230;</p>
<pre class="brush: bash; title: ; notranslate">
$ find /var/www -type f -name '*' -exec cp {} /var/tmp/. \;
</pre>
<p>problem solved!</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F03%2Fargument-list-too-long%2F&amp;title=Argument%20list%20too%20long" id="wpa2a_14"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>Related posts:<ol><li><a href='http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/' rel='bookmark' title='Join multiple mpg files into one file'>Join multiple mpg files into one file</a> <small>I did not realize how easy it is to join...</small></li>
<li><a href='http://www.nyayapati.com/srao/2011/03/ssh-aliases/' rel='bookmark' title='SSH aliases'>SSH aliases</a> <small>I constantly connect to linux or unix machines using ssh...</small></li>
</ol></p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/L1cdoqXvmPQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/03/argument-list-too-long/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/03/argument-list-too-long/</feedburner:origLink></item>
		<item>
		<title>MAMP – mysqlcheck: Got error: 1045</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/3xWsphK4MVo/</link>
		<comments>http://www.nyayapati.com/srao/2011/03/mamp-mysqlcheck-got-error-1045/#comments</comments>
		<pubDate>Mon, 28 Mar 2011 17:18:03 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[MAMP]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=560</guid>
		<description><![CDATA[<p>I started seeing the following error every time I started MAMP. This began after I changed the root password for my MAMP installation on my MBP.</p>
<p></p>

/Applications/MAMP/Library/bin/mysqlcheck: Got error: 1045: Access denied for user 'root'@'localhost' (using password: YES) when trying to connect

<p>It turns out that the default password is hard coded in different scripts under &#8216;/Applications/MAMP/bin&#8217;. [...]


No related posts.

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>I started seeing the following error every time I started MAMP. This began after I changed the root password for my MAMP installation on my MBP.</p>
<p><a href="http://www.nyayapati.com/srao/wp-content/uploads/2011/03/Screen-shot-2011-03-28-at-1.10.32-PM.png" rel="lightbox[560]"><img src="http://www.nyayapati.com/srao/wp-content/uploads/2011/03/Screen-shot-2011-03-28-at-1.10.32-PM-300x151.png" alt="" title="MAMP Error msg" width="300" height="151" class="aligncenter size-medium wp-image-561" /></a></p>
<pre class="brush: plain; title: ; notranslate">
/Applications/MAMP/Library/bin/mysqlcheck: Got error: 1045: Access denied for user 'root'@'localhost' (using password: YES) when trying to connect
</pre>
<p>It turns out that the default password is hard coded in different scripts under &#8216;/Applications/MAMP/bin&#8217;. In my case the script quickCheckMysqlUpgrade.sh. Just edit the script to have the correct password and you wont see the annoying message again. </p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F03%2Fmamp-mysqlcheck-got-error-1045%2F&amp;title=MAMP%20%26%238211%3B%20mysqlcheck%3A%20Got%20error%3A%201045" id="wpa2a_16"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/3xWsphK4MVo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/03/mamp-mysqlcheck-got-error-1045/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/03/mamp-mysqlcheck-got-error-1045/</feedburner:origLink></item>
		<item>
		<title>Join multiple mpg files into one file</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/k_uw-BK8RA0/</link>
		<comments>http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/#comments</comments>
		<pubDate>Thu, 24 Mar 2011 02:19:29 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[videos]]></category>
		<category><![CDATA[mpeg]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=464</guid>
		<description><![CDATA[<p>I did not realize how easy it is to join mpeg files with just the windows copy command or unix cat command. </p>
<p>On windows the trick is to copy the files while preserving the binary format. Here is how you would do it -</p>

copy files1.mpg /b + files2.mpg /b joinedfile.mpg

<p>You could also do the following [...]


No related posts.

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>I did not realize how easy it is to join mpeg files with just the windows copy command or unix cat command. </p>
<p>On windows the trick is to copy the files while preserving the binary format. Here is how you would do it -</p>
<pre class="brush: powershell; title: ; notranslate">
copy files1.mpg /b + files2.mpg /b joinedfile.mpg
</pre>
<p>You could also do the following if the files are named consecutively</p>
<pre class="brush: powershell; title: ; notranslate">
copy file*.mpg /b joinedfile.mpg
</pre>
<p>On UNIX it couldn&#8217;t be any simpler..</p>
<pre class="brush: bash; title: ; notranslate">
cat file1.mpg file2.mpg &gt; joinedfile.mpg
</pre>
<p> or</p>
<pre class="brush: bash; title: ; notranslate">
cat file*.mpg &gt; joinedfile.mpg
</pre>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F03%2Fjoin-multiple-mpg-files-into-one-file%2F&amp;title=Join%20multiple%20mpg%20files%20into%20one%20file" id="wpa2a_18"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/k_uw-BK8RA0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/03/join-multiple-mpg-files-into-one-file/</feedburner:origLink></item>
		<item>
		<title>SSH aliases</title>
		<link>http://feedproxy.google.com/~r/SrinisPointOfView/~3/y2DlXUzmOos/</link>
		<comments>http://www.nyayapati.com/srao/2011/03/ssh-aliases/#comments</comments>
		<pubDate>Wed, 23 Mar 2011 17:07:58 +0000</pubDate>
		<dc:creator>srini</dc:creator>
				<category><![CDATA[unix/linux]]></category>
		<category><![CDATA[cli]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://www.nyayapati.com/srao/?p=544</guid>
		<description><![CDATA[<p>I constantly connect to linux or unix machines using ssh and it can get a little bothersome typing out the IP address repeatedly. Here is the typical syntax to connect to a linux box (random IP address)</p>

ssh username@111.11.11.1

<p>Now imagine typing this again and again. Thats where the ssh config file comes to the rescue. You [...]


No related posts.

Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>I constantly connect to linux or unix machines using ssh and it can get a little bothersome typing out the IP address repeatedly. Here is the typical syntax to connect to a linux box (random IP address)</p>
<pre class="brush: bash; title: ; notranslate">
ssh username@111.11.11.1
</pre>
<p>Now imagine typing this again and again. Thats where the ssh config file comes to the rescue. You can create aliases to make your connections easy. The template for the config file ~/.ssh/config is </p>
<pre class="brush: bash; title: ; notranslate">
Host domain
  HostName domain.com
  User username
</pre>
<p>The HostName can be either an IP address or an actual hostname. So for our example above our config file ~/.ssh/config will be</p>
<pre class="brush: bash; title: ; notranslate">
Host myserver
  HostName 111.11.11.1
  User username
</pre>
<p>So now all you have to do is type the following on your command prompt to directly connect and get prompted for a password. </p>
<pre class="brush: bash; title: ; notranslate">
ssh myserver
</pre>
<p>You can create as many aliases as you want. You can also override the settings of the config file on the command line. For instance if you want to connect using a different user, you can do the following</p>
<pre class="brush: bash; title: ; notranslate">
ssh diff_user@myserver
</pre>
<p>You can also specify your SSH keys for the server in your config file as shown below so you don&#8217;t have to enter your password</p>
<pre class="brush: bash; title: ; notranslate">
Host myserver
  HostName 111.11.11.1
  User username
  IdentityFile ~/.ssh/id_dsa
</pre>
<p>Click <a href="http://oreilly.com/pub/h/66">here</a> or <a href="http://www.csua.berkeley.edu/~ranga/notes/ssh_nopass.html">here</a> to read how to generate and use SSH keys.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fwww.nyayapati.com%2Fsrao%2F2011%2F03%2Fssh-aliases%2F&amp;title=SSH%20aliases" id="wpa2a_20"><img src="http://www.nyayapati.com/srao/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p>

<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://yarpp.org'>Yet Another Related Posts Plugin</a>.</p><img src="http://feeds.feedburner.com/~r/SrinisPointOfView/~4/y2DlXUzmOos" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.nyayapati.com/srao/2011/03/ssh-aliases/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://www.nyayapati.com/srao/2011/03/ssh-aliases/</feedburner:origLink></item>
	</channel>
</rss>

