<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6986015147502886469</id><updated>2012-02-16T14:14:35.325-08:00</updated><category term='linux'/><category term='multihoned'/><category term='Title'/><category term='MySQL'/><category term='vi'/><category term='howto'/><category term='Magento'/><category term='putty'/><category term='checkin'/><category term='bookmarks'/><category term='diff'/><category term='export'/><category term='bash'/><category term='networking'/><category term='tar'/><category term='awk'/><category term='controller'/><category term='iphone'/><category term='multiple isp'/><category term='SEO'/><category term='description'/><category term='shell'/><category term='nexthop'/><category term='ip route'/><category term='BTREE'/><category term='debinan'/><category term='Mage'/><category term='ubuntu'/><category term='CTRL-S'/><category term='zend'/><category term='meta-tags'/><category term='svn'/><category term='e-commerce'/><title type='text'>Ishoni</title><subtitle type='html'>Come together of network, technology and user experience</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://www.ishoni.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>11</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-817367393355163231</id><published>2011-10-05T01:07:00.000-07:00</published><updated>2011-10-05T01:07:45.461-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MySQL'/><category scheme='http://www.blogger.com/atom/ns#' term='BTREE'/><category scheme='http://www.blogger.com/atom/ns#' term='export'/><category scheme='http://www.blogger.com/atom/ns#' term='Magento'/><title type='text'>Mangento exporting SQL issue</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;While exporting mySQL if you every get into the problem]&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;ERROR 1064 (42000) at line 688: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'USING BTREE,&lt;br /&gt;&amp;nbsp; KEY `FK_ATTRIBUTE_VARCHAR_ENTITY` (`entity_id`),&lt;br /&gt;&amp;nbsp; KEY `FK_CATALO' at line 9&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;and the mySQL is&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;UNIQUE KEY `IDX_BASE` (`entity_type_id`,`entity_id`,`attribute_id`,`store_id`)&amp;nbsp;&lt;/span&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;USING BTREE&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;You need to replace all such instance by&amp;nbsp;&lt;/div&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;UNIQUE KEY `IDX_BASE` USING BTREE(`entity_type_id`,`entity_id`,`attribute_id`,`store_id`)&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-817367393355163231?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/817367393355163231/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/10/mangento-exporting-sql-issue.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/817367393355163231'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/817367393355163231'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/10/mangento-exporting-sql-issue.html' title='Mangento exporting SQL issue'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-4744109470946286872</id><published>2011-10-04T23:22:00.000-07:00</published><updated>2011-10-04T23:55:32.473-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='multiple isp'/><category scheme='http://www.blogger.com/atom/ns#' term='multihoned'/><category scheme='http://www.blogger.com/atom/ns#' term='howto'/><category scheme='http://www.blogger.com/atom/ns#' term='nexthop'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='debinan'/><category scheme='http://www.blogger.com/atom/ns#' term='networking'/><category scheme='http://www.blogger.com/atom/ns#' term='ip route'/><title type='text'>How to making Linux multihomed to connect to 2 ISP</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;To make my Ubuntu Server on more robust I have connected it to 2 ISP so that I can have redundant last mile. Also one of my ISP gives me unlimited bandwidth while the other is costlier but more reliable.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;1.&lt;/div&gt;&lt;div&gt;To make your linux server multihomed, I am assuming that you have atleast 2 network interfaces. In my case both are ethernet (eth0 and eth1)&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2.&amp;nbsp;&lt;/div&gt;&lt;div&gt;Make sure both the networks are working individually up by setting it on /etc/network/interface&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;sudo vi&amp;nbsp;/etc/network/interface&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;#Loopback&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;auto lo&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;iface lo inet loopback&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;# The primary network interface&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;auto eth0&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;iface eth0 inet static&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; address 192.168.200.100&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; netmask 255.255.255.0&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; metric 100&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; gateway 192.168.200.6&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;auto eth1&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;iface eth1 inet static&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; address 192.168.201.100&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; netmask 255.255.255.0&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; metric 200&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; gateway 192.168.201.5&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;Now if you go to your terminal, you should be able to&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;gt;ip route show&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;192.168.201.0/24 dev eth1 &amp;nbsp;proto kernel &amp;nbsp;scope link &amp;nbsp;src 192.168.201.100&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;192.168.200.0/24 dev eth0 &amp;nbsp;proto kernel &amp;nbsp;scope link &amp;nbsp;src 192.168.200.100&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;default via 192.168.200.6 dev eth0 &amp;nbsp;metric 100&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;default via 192.168.201.5 dev eth1 &amp;nbsp;metric 200&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;With this if your eth0 goes down, your eth1 will take over and vice-versa.&lt;/div&gt;&lt;div&gt;But this is still a long way from making your network multihoned where your can do load balancing.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;All you need to do is to add &amp;nbsp;multihop route in your &lt;span class="Apple-style-span" style="color: red;"&gt;/etc/rc.local&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;ip route append default scope global nexthop via 192.168.200.6 dev eth0 weight 5 nexthop via 192.168.201.5 dev eth1 weight 1&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;read more on&lt;br /&gt;&lt;a href="http://manpages.ubuntu.com/manpages/dapper/man8/ip.8.html"&gt;http://manpages.ubuntu.com/manpages/dapper/man8/ip.8.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-4744109470946286872?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/4744109470946286872/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/10/making-linux-multihomed-to-connect-to-2.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4744109470946286872'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4744109470946286872'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/10/making-linux-multihomed-to-connect-to-2.html' title='How to making Linux multihomed to connect to 2 ISP'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-4788989915789563462</id><published>2011-10-04T22:25:00.001-07:00</published><updated>2011-10-04T22:26:01.376-07:00</updated><title type='text'>USB for Ubuntu Server</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Ubuntu Server does not come with auto-mount for USB.&lt;br /&gt;You will need to install the light weight usbmount&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;sudo apt-get install usbmount&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-4788989915789563462?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/4788989915789563462/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/10/usb-for-ubuntu-server.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4788989915789563462'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4788989915789563462'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/10/usb-for-ubuntu-server.html' title='USB for Ubuntu Server'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-4496599281390227440</id><published>2011-09-20T22:27:00.000-07:00</published><updated>2011-10-04T22:26:48.228-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tar'/><category scheme='http://www.blogger.com/atom/ns#' term='awk'/><category scheme='http://www.blogger.com/atom/ns#' term='diff'/><category scheme='http://www.blogger.com/atom/ns#' term='svn'/><category scheme='http://www.blogger.com/atom/ns#' term='checkin'/><title type='text'>Checking what files to checkin in SVN</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Coming from rational Clearcase background, I always like to check which files I need to checkin and which files I would like to revert back.&lt;br /&gt;&lt;br /&gt;First I check all files that have been added but not necessarily been added into the svn archive.&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;svn status | grep "^?" | awk '{ print $2}&lt;/span&gt;&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;For the files that need to&amp;nbsp;achieved&amp;nbsp;do this manually. &amp;nbsp;For all other files you should save these in a tar and delete them. Most often these are files&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;svn status | grep "^?" | awk '{ print $2} &amp;gt;not-needed.txt&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;At this point you may want to remove the directories which are cached or not under source control&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;tar cxvfa &amp;nbsp;not-needed.tgz -T not-need.txt&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;cat not-needed.txt | xarags rm -rf $1&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Finally for all files that are now modified, I like to make sure they are really needed. Do a diff and make sure the code is correct.&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;svn status | grep "^[AM]" | awk '{if ($2=="S" || $2=="+") print $3; else print $2;}'&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-4496599281390227440?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/4496599281390227440/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/09/checking-what-files-to-checkin-in-svn.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4496599281390227440'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4496599281390227440'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/09/checking-what-files-to-checkin-in-svn.html' title='Checking what files to checkin in SVN'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-6679140290858034704</id><published>2011-09-11T06:34:00.000-07:00</published><updated>2011-10-05T03:20:24.585-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='bash'/><category scheme='http://www.blogger.com/atom/ns#' term='shell'/><category scheme='http://www.blogger.com/atom/ns#' term='bookmarks'/><title type='text'></title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;In magento I have been jumping over all the directories to be able to see the code. Half my life was being spent on CDing.&lt;br /&gt;&lt;br /&gt;Then I found this easy script&lt;br /&gt;&lt;a href="http://www.huyng.com/archives/quick-bash-tip-directory-bookmarks/492/"&gt;http://www.huyng.com/archives/quick-bash-tip-directory-bookmarks/492/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Basically it allows you to do a save on any alias and then go to the alias.&lt;br /&gt;&lt;br /&gt;The script is basically very simple and can be easily used in any bash shell by adding it to .bashrc or .bash_aliases (for sake of completion)&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: #f2f2fd; color: #1a1a1a; font-family: 'Palatino Linotype', 'Book Antiqua', Palatino, serif; font-size: 14px; line-height: 25px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;# Bash Directory Bookmarks&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m1='alias g1="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m2='alias g2="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m3='alias g3="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m4='alias g4="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m5='alias g5="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m6='alias g6="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m7='alias g7="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m8='alias g8="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias m9='alias g9="cd `pwd`"'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias mdump='alias|grep -e "alias g[0-9]"|grep -v "alias m" &amp;gt; ~/.bookmarks'&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;alias lma='alias | grep -e "alias g[0-9]"|grep -v "alias m"|sed "s/alias //"'&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;However there is now a better script which helps you save the names in more readable format and then go to that. For that you should look up the script yourself.&lt;br /&gt;&lt;a href="http://www.huyng.com/bashmarks-directory-bookmarks-for-the-shell/"&gt;http://www.huyng.com/bashmarks-directory-bookmarks-for-the-shell/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-6679140290858034704?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/6679140290858034704/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/09/in-magento-i-have-been-jumping-over-all.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/6679140290858034704'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/6679140290858034704'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/09/in-magento-i-have-been-jumping-over-all.html' title=''/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-6019535333645350513</id><published>2011-09-11T06:33:00.000-07:00</published><updated>2011-10-05T03:21:16.243-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='meta-tags'/><category scheme='http://www.blogger.com/atom/ns#' term='controller'/><category scheme='http://www.blogger.com/atom/ns#' term='Title'/><category scheme='http://www.blogger.com/atom/ns#' term='description'/><category scheme='http://www.blogger.com/atom/ns#' term='SEO'/><category scheme='http://www.blogger.com/atom/ns#' term='Magento'/><title type='text'>Magento: How to change Title, Sescription and Keywords in static pages</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Magento is fairly SEO friendly but for certain pages, it does not allow you to change the Title, Description or the keywords. Some of these pages are very important for Google crawls such as Search terms, Advanced search, Contact us, Sitemaps etc. There are other pages such as accounts etc, which also set the default keywords, however I do not care if they are crawled by Google as they are customer specific.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;You can set all of these by making simple changes the layout XML files and the block functional file.&lt;/div&gt;&lt;div&gt;1.&lt;/div&gt;&lt;div&gt;&lt;div&gt;We have to create the functions setDescription and setKeywords in &lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;.../app/code/core/Mage/Page/Block/Html/Head.php&lt;/span&gt; &amp;nbsp;(Remember it always best to make a copy of this file in&amp;nbsp;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;.../app/code/local/Mage/Page/Block/Html/Head.php&lt;/span&gt;).&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: blue; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &lt;/span&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;/**&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* Set description element text&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;*&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* @param string $description&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* @return Mage_Page_Block_Html_Head&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;*/&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; public function setDescription($description)&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; {&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; $this-&amp;gt;_data['description'] = $description;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return $this;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; }&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; /**&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* Set Keywords element text&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;*&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* @param string $keywords&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;* @return Mage_Page_Block_Html_Head&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;*/&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; public function setKeywords($keywords)&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; {&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; $this-&amp;gt;_data['keywords'] = $keywords;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return $this;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; }&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: blue; font-family: 'Courier New', Courier, monospace; font-size: x-small;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;2.&amp;nbsp;&lt;/div&gt;&lt;div&gt;Let us take Advanced Search for example and see how we can make these changes.&amp;nbsp;In layout/catalogsearch.xml&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;&lt;span class="Apple-style-span"&gt;&amp;nbsp;After&amp;nbsp;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;&amp;lt;label&amp;gt;Advanced Search Form&amp;lt;/label&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace; font-size: x-small;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="font-family: 'Courier New', Courier, monospace;"&gt;&lt;span class="Apple-style-span" style="font-size: x-small;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/span&gt;&lt;span class="Apple-style-span" style="color: lime;"&gt;&amp;lt;reference name="head"&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;action method="setForcedTitle"&amp;gt;&amp;lt;title&amp;gt;%TITLE%Vyom search&amp;lt;/title&amp;gt;&amp;lt;/action&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;action method="setDescription"&amp;gt;&amp;lt;description&amp;gt;%DESCRIPTION%&amp;lt;/description&amp;gt;&amp;lt;/action&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;action method="setKeywords"&amp;gt;&amp;lt;keywords&amp;gt;%KEYWORDS%&amp;lt;/keywords&amp;gt;&amp;lt;/action&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: lime; font-family: 'Courier New', Courier, monospace;"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/reference&amp;gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Make sure you clear your cache before checking the changes.&amp;nbsp;Similarly, find the right XML file and whichever static page you want to make the changes.&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-6019535333645350513?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/6019535333645350513/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/09/magento-how-to-change-title-sescription.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/6019535333645350513'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/6019535333645350513'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/09/magento-how-to-change-title-sescription.html' title='Magento: How to change Title, Sescription and Keywords in static pages'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-1466480906133110820</id><published>2011-09-08T22:29:00.000-07:00</published><updated>2011-09-08T22:31:03.340-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mage'/><category scheme='http://www.blogger.com/atom/ns#' term='e-commerce'/><category scheme='http://www.blogger.com/atom/ns#' term='zend'/><category scheme='http://www.blogger.com/atom/ns#' term='Magento'/><title type='text'>Magento: Out of stock pushed to the end of the list</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;Magento allows sorting by Position, Price and Name in the toolbar.&lt;br /&gt;&lt;br /&gt;But It does not look at the status of product and if the product is available. Under normal circumstances, I would not like to show any of the products which are not available but due to SEO reasons, it makes sense to continue showing the products. So I would like to continue showing the products based on one of the sorting method but pushing the out-of-stock product at the end.&lt;br /&gt;&lt;br /&gt;To do this a good post is&amp;nbsp;&lt;a href="http://www.magentocommerce.com/boards/viewthread/203590/#t345652"&gt;http://www.magentocommerce.com/boards/viewthread/203590/#t345652&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;A more elegant solution is to make changes in .../Mage/Catalog/Model/Layer.php at line #102&lt;br /&gt;$collection-&amp;gt;joinField('inventory_in_stock', 'cataloginventory_stock_item', 'is_in_stock', 'product_id=entity_id','is_in_stock&amp;gt;=0', 'left')-&amp;gt;setOrder('inventory_in_stock', 'desc');&lt;br /&gt;&lt;br /&gt;This will effect both the listing as well as the results page.&lt;br /&gt;&lt;br /&gt;Another things is to remember to copy this file from core to code/local//Mage/Catalog/Model/Layer.php so that the core files remain as it is.&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-1466480906133110820?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/1466480906133110820/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/09/magento-out-of-stock-pushed-to-end-of.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/1466480906133110820'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/1466480906133110820'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/09/magento-out-of-stock-pushed-to-end-of.html' title='Magento: Out of stock pushed to the end of the list'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-4010354291132905802</id><published>2011-09-07T20:51:00.000-07:00</published><updated>2011-09-07T20:51:13.223-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='vi'/><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='bash'/><category scheme='http://www.blogger.com/atom/ns#' term='CTRL-S'/><category scheme='http://www.blogger.com/atom/ns#' term='putty'/><title type='text'>Putty screen freeze due to CTRL-S</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;Over the last couple of day, I faced a problem of getting screen freezes while I was working on vi. It became very frustrating as I had to restart my putty and also remove the swap file.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I finally realised that the reason was I was pressing CTLR-S for saving a file out of sheer habit. CTLR-S on bash generally means XOFF (output off) and you need to do a CTLR-Q to turn it back on.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Instead of that a simple addition to .bash_profile can save you the trouble.&lt;/div&gt;&lt;div&gt;stty -ixon&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;However even with this I was getting a statment such as i-search when I would type CTLR-S.&lt;/div&gt;&lt;div&gt;For that I removed the binding from my bash shell.&amp;nbsp;&lt;/div&gt;&lt;div&gt;bind -r '\C-s'&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;So all in all the changes need in your .bash_profile is&lt;/div&gt;&lt;div&gt;bind -r '\C-s'&lt;/div&gt;&lt;div&gt;stty -ixon&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-4010354291132905802?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/4010354291132905802/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/09/putty-screen-freeze-due-to-ctrl-s.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4010354291132905802'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/4010354291132905802'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/09/putty-screen-freeze-due-to-ctrl-s.html' title='Putty screen freeze due to CTRL-S'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-2434319008469901549</id><published>2011-07-27T11:50:00.000-07:00</published><updated>2011-07-27T11:50:35.026-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='MySQL'/><category scheme='http://www.blogger.com/atom/ns#' term='Magento'/><title type='text'>MySQL: Copy / clone database in MySQL</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;I needed to create a exact replica of my existing MySQL Magento database so that I could use it for my development.&lt;br /&gt;&lt;br /&gt;A elegant solution was&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span"&gt;mysqldump -u SRC_DB_USER --password=SRC_DB_PASSWORD&amp;nbsp;-h&amp;nbsp;&lt;/span&gt;SRC_DB_HOST&lt;span class="Apple-style-span"&gt;&amp;nbsp;SRC_DB_NAME | mysql&amp;nbsp;&lt;/span&gt;-u DST_DB_USER --password=DST_DB_PASSWORD&amp;nbsp;-h DST_DB_HOST&lt;span class="Apple-style-span"&gt;&amp;nbsp;DST_DB_NAME&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;where&lt;br /&gt;- SRC_DB_* is the source database&lt;br /&gt;- DST_DB+* is the destination Database&lt;br /&gt;&lt;br /&gt;If you wanted to create a datavase also, you could have used&lt;br /&gt;&lt;br /&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: monospace; font-size: 11px; line-height: 16px; white-space: pre;"&gt;mysqladmin create &lt;/span&gt;&lt;span class="Apple-style-span"&gt;&amp;nbsp;&lt;/span&gt;-u DST_DB_USER --password=DST_DB_PASSWORD&amp;nbsp;-h DST_DB_HOST&lt;span class="Apple-style-span"&gt;&amp;nbsp;DST_DB_NAME&amp;nbsp;&lt;/span&gt;&amp;amp;&amp;amp; \&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;mysqldump -u SRC_DB_USER --password=SRC_DB_PASSWORD&amp;nbsp;-h&amp;nbsp;SRC_DB_HOST&lt;span class="Apple-style-span"&gt;&amp;nbsp;SRC_DB_NAME \&lt;/span&gt;&lt;/div&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;"&gt;&lt;span class="Apple-style-span"&gt;| mysql&amp;nbsp;&lt;/span&gt;-u DST_DB_USER --password=DST_DB_PASSWORD&amp;nbsp;-h DST_DB_HOST&lt;span class="Apple-style-span"&gt;&amp;nbsp;DST_DB_NAME&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class="Apple-style-span"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-2434319008469901549?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/2434319008469901549/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/07/mysql-copy-clone-database-in-mysql.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/2434319008469901549'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/2434319008469901549'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/07/mysql-copy-clone-database-in-mysql.html' title='MySQL: Copy / clone database in MySQL'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-2322413045495128268</id><published>2011-07-27T11:41:00.000-07:00</published><updated>2011-07-27T11:41:29.249-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='svn'/><title type='text'>SVN help: Easy way to delete .svn folders</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;If you need to delete .svn in folders, here is a simple Linux command&lt;br /&gt;rm -rf `find . -name .svn`&lt;br /&gt;&lt;br /&gt;This can come very useful if you have made a copy/backup of the folder.&lt;br /&gt;Another use is if the folder is copied from one project to another project. In which case, you will not be able to add the folder into SVN as it will tell you that this directory already exist under svn. It is best if you delete all the .svn and then do a 'svn add'&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-2322413045495128268?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/2322413045495128268/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/07/svn-help-easy-way-to-delete-svn-folders.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/2322413045495128268'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/2322413045495128268'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/07/svn-help-easy-way-to-delete-svn-folders.html' title='SVN help: Easy way to delete .svn folders'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6986015147502886469.post-7974629404070859509</id><published>2011-06-09T00:17:00.000-07:00</published><updated>2011-09-11T06:34:45.844-07:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='iphone'/><title type='text'>RIP iphone: reteiving the Messages, call histroy and contact list</title><content type='html'>&lt;div dir="ltr" style="text-align: left;" trbidi="on"&gt;After giving me good service for 3 and half years the touch screen of my iphone finally gave away. It happened at night when it refused to turn itself off and there was no way for me to reset it.&lt;br /&gt;&lt;br /&gt;By now, I knew my iphone was on its last breaths and it was living on borrowed time. I did not loose too much of sleep on this but my immediate concern was to retrieve my last few days messages, address books and call history.&lt;br /&gt;&lt;br /&gt;I knew I had the lastest backup, as the iPhone was still syncing with the iTunes. So all i needed to do was to read the backup. Also from my previous experience I knew these files would be mostly stored as sqllite files.&lt;br /&gt;&lt;br /&gt;After a bit of search on my machine the files were backed on my Vista up @ /user/AppData/Apple Computer/Roaming/MobileSync/Backup/adb3eaadbe258e41f1a045ae15ccb7d3cf66ee6b directory. Just check the latest directory on your computer.&lt;br /&gt;&lt;br /&gt;Next was to figure out which files were the ones needed. Here after some search I found these files to be here.&lt;code&gt;&lt;br /&gt;ff1324e6b949111b2fb449ecddb50c89c3699a78.mddata  Call history 3d0d7e5fb2ce288813306e4d4636395e047a3d28.mddata  SMS Log&lt;br /&gt;740b7eaf93d6ea5d305e88bb349c8e9643f48c3b.mddata  Notes database&lt;br /&gt;31bb7ba8914766d4ba40d6dfb6113c8b614be442.mddata  Contact List&lt;/code&gt;&lt;br /&gt;&lt;code&gt;992df473bbb9e132f4b3b6e4d33f72171e97bc7a.mddata  Voicemail list&lt;/code&gt;&lt;code&gt; &lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I used the &lt;a href="https://addons.mozilla.org/en-US/firefox/addon/sqlite-manager/"&gt;Sqllite manager&lt;/a&gt;, a firefox extension (which can be found &lt;a href="https://addons.mozilla.org/en-US/firefox/addon/sqlite-manager/"&gt;here&lt;/a&gt;) to be able to read these files.&lt;br /&gt;Most of the files are easy to read and does not really need any SQL query as such.&lt;br /&gt;&lt;br /&gt;However the Contact list is more complicated with multiple tables and for that I used the query to build a flat file.&lt;br /&gt;select p.first, p.last, p.middle, p.Organization, p.Department, p.note, p.JobTitle, p.Prefix, d1.value as mobile, d2.value as Home, d3.value as Work, d4.value as WorkFAX, d5.value as Other, d6.value as Main, d7.value as HomeEmail, d8.value as WorkEmail, a1.value as Street,a2.value as State,a3.value as CountryCode,a4.value as City,a5.value as Country,a6.value as Zip from abperson p&lt;br /&gt;left outer join ABMultiValue d1 on d1.record_id=p.ROWID and d1.label=1&lt;br /&gt;left outer join ABMultiValue d2 on d2.record_id=p.ROWID and d2.label=2 and d2.property=3&lt;br /&gt;left outer join ABMultiValue d3 on d3.record_id=p.ROWID and d3.label=3 and d3.property=3&lt;br /&gt;left outer join ABMultiValue d4 on d4.record_id=p.ROWID and d4.label=4&lt;br /&gt;left outer join ABMultiValue d5 on d5.record_id=p.ROWID and d5.label=5&lt;br /&gt;left outer join ABMultiValue d6 on d6.record_id=p.ROWID and d6.label=6&lt;br /&gt;left outer join ABMultiValue d7 on d7.record_id=p.ROWID and d7.label=2 and d7.property=4&lt;br /&gt;left outer join ABMultiValue d8 on d8.record_id=p.ROWID and d8.label=3 and d8.property=4&lt;br /&gt;left outer join ABMultiValueEntry a1 on a1.parent_id=p.ROWID and a1.key=1&lt;br /&gt;left outer join ABMultiValueEntry a2 on a2.parent_id=p.ROWID and a2.key=2&lt;br /&gt;left outer join ABMultiValueEntry a3 on a3.parent_id=p.ROWID and a3.key=3&lt;br /&gt;left outer join ABMultiValueEntry a4 on a4.parent_id=p.ROWID and a4.key=4&lt;br /&gt;left outer join ABMultiValueEntry a5 on a5.parent_id=p.ROWID and a5.key=5&lt;br /&gt;left outer join ABMultiValueEntry a6 on a6.parent_id=p.ROWID and a6.key=6;&lt;br /&gt;&lt;br /&gt;Now too search for an iPhone alternative :-) &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6986015147502886469-7974629404070859509?l=www.ishoni.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://www.ishoni.com/feeds/7974629404070859509/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.ishoni.com/2011/06/rip-iphone-reteiving-messages-call.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/7974629404070859509'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6986015147502886469/posts/default/7974629404070859509'/><link rel='alternate' type='text/html' href='http://www.ishoni.com/2011/06/rip-iphone-reteiving-messages-call.html' title='RIP iphone: reteiving the Messages, call histroy and contact list'/><author><name>Vyom Khandelia</name><uri>http://www.blogger.com/profile/04718456439871841739</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://2.bp.blogspot.com/_75zp2z3EaCw/SVI4y7nKvXI/AAAAAAAADj4/7Jv3IMyY9M4/S220/_MG_7032.JPG'/></author><thr:total>1</thr:total></entry></feed>
