<?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>Apache, Linux ,Seo tricks and many more &#187; ssh</title>
	<atom:link href="http://www.gossiplime.com/tag/ssh/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.gossiplime.com</link>
	<description>This blog is just for all persons to know more about php, apache , linux , seo etc</description>
	<lastBuildDate>Wed, 08 Jul 2009 16:40:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Restart Mysql from ssh</title>
		<link>http://www.gossiplime.com/2009/02/restart-mysql-from-ssh/</link>
		<comments>http://www.gossiplime.com/2009/02/restart-mysql-from-ssh/#comments</comments>
		<pubDate>Tue, 10 Feb 2009 11:13:12 +0000</pubDate>
		<dc:creator>sps</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Mysql]]></category>
		<category><![CDATA[commands]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=265</guid>
		<description><![CDATA[To restart mysql service from command line (ssh) * Login to SSH as root using a program like putty. * Type the following command, /scripts/restartsrv_mysql Hope you all enjoy this command.]]></description>
			<content:encoded><![CDATA[<p>To restart mysql service from command line (ssh)</p>
<p>* Login to SSH as root using a program like putty.<br />
* Type the following command,</p>
<blockquote><p>/scripts/restartsrv_mysql</p></blockquote>
<p>Hope you all enjoy this command.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/02/restart-mysql-from-ssh/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Modify ssh Welcome message</title>
		<link>http://www.gossiplime.com/2009/02/modify-ssh-welcome-message/</link>
		<comments>http://www.gossiplime.com/2009/02/modify-ssh-welcome-message/#comments</comments>
		<pubDate>Mon, 09 Feb 2009 10:29:33 +0000</pubDate>
		<dc:creator>vinod</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[log]]></category>
		<category><![CDATA[putty]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=262</guid>
		<description><![CDATA[Hi friends if you want to create a ssh login message for your server if any buddy login with ssh they will get a welcome message. Lets Start Login with root password pico /etc/motd You will get a welcome screen you can modify it anything you want to show to your users. who logged via [...]]]></description>
			<content:encoded><![CDATA[<p>Hi friends if you want to create a ssh login message for your server if any buddy login with ssh they will get a welcome message.<br />
Lets Start Login with root password</p>
<blockquote><p>pico /etc/motd</p></blockquote>
<p>You will get a welcome screen you can modify it anything you want to show to your users. who logged via ssh.  Write something like this<br />
This computerized system is designed for registered users. All activity is recorded and investigated by the individual system regularly. Those without power or more than their rights when using this system to cancel all its services are subject to. Any illegal services or the user of the server or attempt to withdraw their services in the conduct of local law enforcement to notify the user of law will be finalized and will be punished. Anyone using this system consents to these terms.</p>
<blockquote><p>Now type Ctrl+X then hit Y and enter</p></blockquote>
<p>now your welcome message is now saved</p>
<p>Logout of SSH then log back in, you&#8217;ll see your new greeting.. <img src='http://www.gossiplime.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/02/modify-ssh-welcome-message/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Move account via whm/ssh</title>
		<link>http://www.gossiplime.com/2009/02/move-account-via-whmssh/</link>
		<comments>http://www.gossiplime.com/2009/02/move-account-via-whmssh/#comments</comments>
		<pubDate>Mon, 09 Feb 2009 09:16:06 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[account]]></category>
		<category><![CDATA[putty]]></category>
		<category><![CDATA[root]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[whm]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=260</guid>
		<description><![CDATA[To move an account to another server you need whm or ssh but if account is big in size then it is not possible by whm you need ssh by root access. Follow the commands below: TO PACK ANY ACCOUNT: /scripts/pkgacct nameoftheuser TO MOVE ONE TAR FILE TO ANOTHER SERVER. IT REQUIRES SERVER ROOT PASSWORD: [...]]]></description>
			<content:encoded><![CDATA[<p>To move an account to another server you need whm or ssh but if account is big in size<br />
then it is not possible by whm you need ssh by root access.<br />
Follow the commands below:</p>
<p>TO PACK ANY ACCOUNT:</p>
<blockquote><p>/scripts/pkgacct nameoftheuser</p></blockquote>
<p>TO MOVE ONE TAR FILE TO ANOTHER SERVER. IT REQUIRES SERVER ROOT PASSWORD:</p>
<blockquote><p>scp /home/name_of_tar_file root@IP_DESTINY_SERVER:/home/ name_of_tar_file</p></blockquote>
<p>Restoring Packed Account:</p>
<blockquote><p>/scripts/restorepkg nameoftheuser</p></blockquote>
<p>Hope you all like this <img src='http://www.gossiplime.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/02/move-account-via-whmssh/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Get Email when someone Login by root</title>
		<link>http://www.gossiplime.com/2009/02/get-email-when-someone-login-by-root/</link>
		<comments>http://www.gossiplime.com/2009/02/get-email-when-someone-login-by-root/#comments</comments>
		<pubDate>Mon, 09 Feb 2009 09:06:41 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=256</guid>
		<description><![CDATA[Hi friends everybuddy wanted security about their webserver and updated everytime you can get an email when anybuddy login via root though ssh. To accomplish this you will need to edit the file .bash_profile. At command prompt type the below command: pico .bash_profile At the end of the file add following code: echo &#8216;ALERT &#8211; [...]]]></description>
			<content:encoded><![CDATA[<p>Hi friends everybuddy wanted security about their webserver and updated everytime<br />
you can get an email when anybuddy login via root though ssh.</p>
<p>To accomplish this you will need to edit the file .bash_profile.<br />
At command prompt type the below command:</p>
<blockquote><p>pico .bash_profile</p></blockquote>
<p>At the end of the file add following code:</p>
<blockquote><p>echo &#8216;ALERT &#8211; Root Access from:&#8217; `date` `who` | mail -s &#8220;Alert: Root Access from `who | awk &#8216;{print $6}&#8217;`&#8221; admin@gmail.com</p></blockquote>
<p>Replace this with your email &#8220;admin@gmail.com&#8221;</p>
<p>If  anybuddy login via ssh root  then you will recieve an email.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/02/get-email-when-someone-login-by-root/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Install mod_security through WHM</title>
		<link>http://www.gossiplime.com/2009/02/install-mod_security-through-whm/</link>
		<comments>http://www.gossiplime.com/2009/02/install-mod_security-through-whm/#comments</comments>
		<pubDate>Sun, 01 Feb 2009 16:12:48 +0000</pubDate>
		<dc:creator>vinod</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[cpanel]]></category>
		<category><![CDATA[mod_security]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[whm]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=208</guid>
		<description><![CDATA[Background: Mod_Security is an open source intrusion detection and prevention engine for web applications. Operating as an Apache Web server module, the purpose of Mod_Security is to increase web application security, protecting web applications from known and unknown attacks. Official web site: http://www.modsecurity.org More information: 1. Log to your Web Host Manager via your favorite [...]]]></description>
			<content:encoded><![CDATA[<p><strong><span style="line-height: 1.3em; font-size: medium;">Background:</span></strong><br />
<strong>Mod_Security</strong> is an open source intrusion detection and prevention engine for web applications. Operating as an Apache Web server module, the purpose of <strong>Mod_Security</strong> is to increase web application security, protecting web applications from known and unknown attacks.</p>
<p>Official web site: <a href="http://www.modsecurity.org/" target="_blank">http://www.modsecurity.org</a></p>
<p><strong><span style="line-height: 1.3em; font-size: medium;">More information:</span></strong><br />
<strong>1.</strong> Log to your Web Host Manager via your favorite web browser.</p>
<p><strong>2.</strong> On the left frame, scroll all the way down till you have reached the cPanel section, then click on <strong>Addon Modules</strong>.</p>
<p><strong>3.</strong> A new window will appear on the right frame. Scroll down until you see <strong> modsecurity</strong>, check the <strong>Install and Keep Updated</strong> field, and click on <strong>Save</strong>.</p>
<p>cPanel will now begin to download <strong>Mod_Security</strong> and add a basic security scheme. <strong style="color: black; background-color: #a0ffff;"></strong>Mod_Security will be added to Apache configuration file which is located at <strong>/usr/local/apache/conf/</strong>, and will include its main security configuration file which can be found at <strong>/usr/local/apache/conf/modsec.conf</strong></p>
<p>That&#8217;s it.<strong> </strong><strong style="color: black; background-color: #a0ffff;"></strong>mod_security is now installed on your server. Now, all that is left for you to do is to edit and add security filters.</p>
<p>You can edit Mod_Security as configuration file either through Web Host Manager, or from shell (SSH).</p>
<p><strong><span style="text-decoration: underline;">Web Host Manager</span></strong><br />
Once the installation has been completed, a new section will be added to <strong>WHM</strong> by the name of <strong>Add-ons</strong>. Scroll down on the left frame until you see it, and click on the <strong>Mod Security</strong> link.</p>
<p><strong>Note:</strong> If you are still logged to your <strong>WHM</strong> and don&#8217;t see the <strong>Add-ons</strong> section, try refreshing your browser.</p>
<p><strong><span style="text-decoration: underline;">Shell</span></strong><br />
cPanel includes three configuration files: <strong>modsec.conf</strong>, <strong>modsec.user.conf</strong>, and <strong> modsec.user.conf.default</strong>.</p>
<p>The ones that are in effect are <strong>modsec.conf</strong>, and <strong>modsec.user.conf</strong>. The file <strong>modsec.user.conf</strong> is blank by default, however, <strong>modsec.user.conf.default</strong> contains common security filters which can be applied to <strong>modsec.user.conf</strong>.</p>
<p>I recommend viewing <strong>modsec.user.conf.default</strong> before copying, and applying any security filters. Misconfiguration can do more harm than good.</p>
<p>Hope you all like this post <img src='http://www.gossiplime.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/02/install-mod_security-through-whm/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Zip file via ssh</title>
		<link>http://www.gossiplime.com/2009/02/zip-file-via-ssh/</link>
		<comments>http://www.gossiplime.com/2009/02/zip-file-via-ssh/#comments</comments>
		<pubDate>Sat, 31 Jan 2009 21:42:42 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[commands]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[zip]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=198</guid>
		<description><![CDATA[How many of you know how to zip a file by ssh # zip -r example.zip www This zips all files and directories -r:Includes all files and directories -&#62; Files example.zip:The zip file you want to create www : The folder you are targetting or use * if your currently in the folder. Comments are [...]]]></description>
			<content:encoded><![CDATA[<p>How many of you know how to zip a file by ssh</p>
<blockquote>
<pre class="text geshifilter-text" style="font-family: monospace;"><span style="color: #008080;"><strong><span style="color: #993300;"># zip -r example.zip www</span>
</strong></span>
This zips all files and directories</pre>
<ul>
<li>-r:Includes all files and directories -&gt; Files</li>
<li>example.zip:The zip file you want to create</li>
<li>www : The folder you are targetting or use * if your currently in the folder.</li>
</ul>
<p>Comments are invited! <img src='http://www.gossiplime.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<pre class="text geshifilter-text" style="font-family: monospace;"></pre>
</blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/02/zip-file-via-ssh/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>SSH slow login Problem</title>
		<link>http://www.gossiplime.com/2009/01/ssh-slow-login-problem/</link>
		<comments>http://www.gossiplime.com/2009/01/ssh-slow-login-problem/#comments</comments>
		<pubDate>Sat, 31 Jan 2009 00:01:32 +0000</pubDate>
		<dc:creator>vinod</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[dns]]></category>
		<category><![CDATA[login]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=192</guid>
		<description><![CDATA[SSH slow  login? Disable reverse DNS lookup when you log into the SSH server, it will do a reverse DNS lookup of the client for security reasons. Thats why it takes a time to login. vi /etc/ssh/sshd_config (and add the below line:) UseDNS no So enjoy SSH]]></description>
			<content:encoded><![CDATA[<h2>SSH slow  login? Disable reverse DNS lookup</h2>
<p>when you log into the SSH server, it will do a reverse DNS lookup of the client for security reasons. Thats why it takes a time to login.</p>
<blockquote><p><strong>vi /etc/ssh/sshd_config </strong> (and add the below line:)</p></blockquote>
<h3>UseDNS no</h3>
<pre></pre>
<p>So enjoy SSH <img src='http://www.gossiplime.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2009/01/ssh-slow-login-problem/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Using SSH by Putty</title>
		<link>http://www.gossiplime.com/2008/12/using-ssh-by-putty/</link>
		<comments>http://www.gossiplime.com/2008/12/using-ssh-by-putty/#comments</comments>
		<pubDate>Fri, 12 Dec 2008 04:17:05 +0000</pubDate>
		<dc:creator>sps</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[putty]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=122</guid>
		<description><![CDATA[Putty is a free software application for Windows 95,98, XP, &#38; Vista which can be used to make a SSH Connection. You can find the application at Click here http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe Download it on your pc. Double-click on the putty.exe program to open. Next fill in the appropriate SSH settings for your service: Next fill in [...]]]></description>
			<content:encoded><![CDATA[<p><span class="HelpLink">Putty</span> is a free  software application for Windows 95,98, XP, &amp; Vista which can be used to  make a <span class="HelpLink">SSH</span> Connection. You can find the application at <a title="Download Putty" href="http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe">Click here</a></p>
<p>http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe</p>
<ol>
<li>Download it on your pc.</li>
<li>Double-click on the <span class="screenshot_callout">putty.exe</span> program to open.</li>
<li>Next fill in the appropriate SSH settings for your service:</li>
</ol>
<div id="attachment_124" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-124" title="puttyssh" src="http://www.gossiplime.com/wp-content/uploads/2009/01/puttyssh-300x290.png" alt="Putty" width="300" height="290" /><p class="wp-caption-text">Putty</p></div>
<p>Next fill in the appropriate SSH settings for your service:</p>
<p><span class="screenshot_callout">Host Name: </span></p>
<ol>
<li>
<ul>
<li>
<div id="attachment_125" class="wp-caption alignnone" style="width: 217px"><img class="size-full wp-image-125" title="puttyhostname" src="http://www.gossiplime.com/wp-content/uploads/2009/01/puttyhostname.png" alt="Host name" width="207" height="43" /><p class="wp-caption-text">Host name</p></div>
<ul>
<li>(gs) Grid-Service &#8211; <span class="ac_replace ac_service_access_domain">s#####.gridserver.com</span> or  <span class="ac_replace ac_service_primary_domain">mt-example.com</span></li>
<li>(dv) Dedicated-Virtual -<span class="ac_replace ac_service_primary_domain">mt-example.com</span> or <span class="ac_replace ac_service_ip">xxx.xxx.xxx.xxx</span></li>
<li>(ss) Shared-Server &#8211; <span class="ac_replace ac_service_primary_domain">mt-example.com</span> or <span class="ac_replace ac_service_ip">xxx.xxx.xxx.xxx</span></li>
</ul>
</li>
<li><span class="screenshot_callout">Port:</span> 22
<div id="attachment_126" class="wp-caption alignnone" style="width: 87px"><img class="size-full wp-image-126" title="port" src="http://www.gossiplime.com/wp-content/uploads/2009/01/port.png" alt="port 22" width="77" height="44" /><p class="wp-caption-text">port 22</p></div></li>
<li><span class="screenshot_callout">Connection Type:</span> SSH
<p><div id="attachment_127" class="wp-caption alignnone" style="width: 286px"><img class="size-full wp-image-127" title="connection-type" src="http://www.gossiplime.com/wp-content/uploads/2009/01/connection-type.png" alt="Connection Type" width="276" height="33" /><p class="wp-caption-text">Connection Type</p></div></li>
<li>Next click Open to start the SSH Connection:</li>
</ul>
<p><div id="attachment_128" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-128" title="puttyopen" src="http://www.gossiplime.com/wp-content/uploads/2009/01/puttyopen-300x291.png" alt="putty open" width="300" height="291" /><p class="wp-caption-text">putty open</p></div>
<p>Once the SSH Connection is open you should see a terminal prompt saying <span class="screenshot_callout">login as:</span> Please provide your full username:</li>
</ol>
<div id="attachment_129" class="wp-caption alignnone" style="width: 310px"><img class="size-medium wp-image-129" title="loginas" src="http://www.gossiplime.com/wp-content/uploads/2009/01/loginas-300x186.png" alt="Login" width="300" height="186" /><p class="wp-caption-text">Login Screen</p></div>
<ol>
<li>
<ul>
<li><span class="screenshot_callout">(gs) Grid-Service</span> &#8211; The default should  be <span class="screenshot_callout">s</span><span class="screenshot_callout">erveradmin</span>@<span class="ac_replace ac_service_primary_domain">mt-example.com</span>, however you  may also login as <a href="mailto:username@mt-example.com"><span class="ac_replace ac_mailbox_email_address">username@mt-example.com</span></a>.
<div class="note">
<h3>NOTE:</h3>
<p>Please make sure SSH is enabled for the user. SSH can be enabled from within  the (ac) AccountCenter.</p></div>
</li>
<li><span class="screenshot_callout">(dv) Dedicated-Virtual</span> &#8211; You may login  as the root user, or as a domain&#8217;s <span class="HelpLink">FTP</span> user which has SSH access enabled</li>
<li>Next provide your password. Please note that you will not see any typing  such as *** when providing your password. Once you hit enter you should now be  connected to your service.</li>
</ul>
<p><a title="ssh commands" href="http://www.gossiplime.com/2008/09/common-ssh-commands/"><strong>Common SSH Command</strong></a></li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2008/12/using-ssh-by-putty/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to use SSH Via HTTP Proxy using Corkscrew in Ubuntu</title>
		<link>http://www.gossiplime.com/2008/10/how-to-use-ssh-via-http-proxy-using-corkscrew-in-ubuntu/</link>
		<comments>http://www.gossiplime.com/2008/10/how-to-use-ssh-via-http-proxy-using-corkscrew-in-ubuntu/#comments</comments>
		<pubDate>Thu, 30 Oct 2008 01:45:09 +0000</pubDate>
		<dc:creator>sps</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[http]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=66</guid>
		<description><![CDATA[If you want to ssh your vps server or your home computer from your work place (assuming you are using http proxy).You need to use Corkscrew. corkscrew is a simple tool to tunnel TCP connections through an HTTP proxy supporting the CONNECT method. It reads stdin and writes to stdout during the connection, just like [...]]]></description>
			<content:encoded><![CDATA[<p>If you want to ssh your vps server or your home computer from your work place (assuming you are using http proxy).You need to use Corkscrew.</p>
<p>corkscrew is a simple tool to tunnel TCP connections through an HTTP proxy supporting the CONNECT method. It reads stdin and writes to stdout during the connection, just like netcat.</p>
<p>It can be used for instance to connect to an SSH server running on a remote 443 port through a strict HTTPS proxy.</p>
<p>Install corkscrew in ubuntu using the following command</p>
<blockquote><p>sudo aptitude install corkscrew</p></blockquote>
<p>This will complete the installation.</p>
<p><strong>Configue corkscrew</strong></p>
<p>If your HTTP proxy uses authentication, then you’ll need to tell it about the username and password to use This is where the concept of ‘auth-file’ comes into play. All you have to do is put your username &amp; password, separated by a colon, into a textfile. Once you’ve done this, you just have to tell corkscrew where to find the auth-file. Create a file called .corkscrew-auth in your home directory</p>
<blockquote><p>$touch .corkscrew-auth</p></blockquote>
<blockquote><p>$gedit .corkscrew-auth</p></blockquote>
<p>and place your username and password in the following format</p>
<blockquote><p>username:password</p></blockquote>
<p>Save and exit the file.</p>
<p><strong>Configure ssh For Tunneling</strong></p>
<p>Now we’ll tell ssh what to do when connecting to all or specific hosts. Open up ~/.ssh/config (that’s /home/yourusername/.ssh/config) in your favourite text editor (gedit,nano,vim etc)</p>
<blockquote><p>$gedit /home/yourusername/.ssh/config</p></blockquote>
<p>and add the following lines</p>
<blockquote><p>Host *</p>
<p>ProxyCommand corkscrew proxyhostname proxyport %h %p /home/username/.corkscrew-auth</p></blockquote>
<p>Save and exit the file</p>
<p>Note: replace proxyhostname and proxyport with the equivalents for your network.</p>
<p>Note: you won’t need to add the last section, ‘/home/username/.corkscrew-auth’, if your HTTP proxy doesn’t use authentication.</p>
<p>What we’ve just told ssh to do is for all hostnames (’Host *’), use the following proxy command to route the connection.If you want more secure connections you can also list of hosts.</p>
<p><strong>Corkscrew Syntax</strong></p>
<blockquote><p>corkscrew proxy proxyport targethost targetport [ authfile ]</p></blockquote>
<p>proxy &#8211; This is the name of the host running the HTTP proxy.</p>
<p>proxyport &#8211; This is the port on which to connect on the proxy.</p>
<p>target &#8211; This is the host to reach through the proxy.</p>
<p>targetport &#8211; This is the port to connect to on the target host.</p>
<p><strong>Test your SSH connection</strong></p>
<blockquote><p>ssh serverip</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2008/10/how-to-use-ssh-via-http-proxy-using-corkscrew-in-ubuntu/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Common SSH Commands</title>
		<link>http://www.gossiplime.com/2008/09/common-ssh-commands/</link>
		<comments>http://www.gossiplime.com/2008/09/common-ssh-commands/#comments</comments>
		<pubDate>Wed, 17 Sep 2008 06:26:23 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.gossiplime.com/?p=115</guid>
		<description><![CDATA[This is a list of Common commands that can be run from root / SSH access. I. Basic Commands A. Retrieve Plesk Admin Password cat /etc/psa/.psa.shadow B. Change Directory (cd) cd /path/to/directory/ C. Listing Files/SubFolders (ls) ls -alh (files and subfolders listed with perms in human-readable sizes) D. Checking Processes ps -a top -c (process [...]]]></description>
			<content:encoded><![CDATA[<p>This is a list of Common commands that can be run from <span class="HelpLink">root</span> / <span class="HelpLink">SSH</span> access.</p>
<h3>I. Basic Commands</h3>
<p><strong>A. Retrieve <span class="HelpLink">Plesk</span> Admin Password</strong></p>
<pre><code>cat /etc/psa/.psa.shadow</code></pre>
<p><strong>B. Change Directory  (cd)</strong></p>
<pre><code>cd /path/to/directory/</code></pre>
<p><strong>C. Listing  Files/SubFolders (ls)</strong></p>
<pre><code>ls -alh</code></pre>
<p><em>(files and subfolders listed with perms in human-readable sizes)</em></p>
<p><strong>D. Checking Processes</strong></p>
<pre><code>ps -a top -c</code></pre>
<p style="font-style: italic;">(process viewer &#8211; Ctrl+C to exit)</p>
<pre><code>ps -auxf</code></pre>
<p><em>(process list)</em><br />
<strong><br />
E. Start/Stop Services</strong></p>
<pre><code>/etc/init.d/&lt;service&gt; start|stop|restart|status</code></pre>
<p><em>(&#8220;/etc/init.d/httpd stop&#8221; stops <span class="HelpLink">apache</span>)</em></p>
<p><strong>F. Check Bean  Counters (hard and soft limits, failcounts, etc.)</strong></p>
<pre><code>cat /proc/user_beancounters</code></pre>
<h3>II. File System Commands (df &amp; du are (dv)-only commands)</h3>
<p><strong>A. Check Total Disk Usage</strong></p>
<pre><code>df</code></pre>
<p><em>(gives physical disk usage report with % used)</em></p>
<p><strong>B.  List Files/Folders +Sizes (du)</strong></p>
<pre><code>du</code></pre>
<p><em>(lists all filesizes. This will take some time.)</em></p>
<pre><code>du -sh</code></pre>
<p><em>(lists all the subfolders/sizes in a dir)</em></p>
<p><strong>C.  Remove/Delete Files (rm /path/to/filename.htm) -DANGER- always verify</strong></p>
<pre><code>rm -vf</code></pre>
<p><em>(force-deletes file. Dont run unless you know EXACTLY what you&#8217;re  doing)</em></p>
<pre><code>rm -vrf</code></pre>
<p><em>(force deletes folder and all subfolders and files)</em></p>
<p>To  Remove a Directory you can use the following command:</p>
<pre><code> <span style="font-family: 'Lucida Grande',Arial,Helvetica,sans-serif;">rmdir  </span></code></pre>
<p><strong>D.  Copy Files (cp)</strong></p>
<pre><code>cp filename.abc /new/path/filename.abc.123
</code></pre>
<p><strong>E. Move Files (mv)</strong></p>
<pre><code>mv filename.abc /new/path/filename.abc.123
</code></pre>
<p><strong>F. Create Empty File (touch)</strong></p>
<pre><code>touch filename.123</code></pre>
<h3>III. File Permissions and Ownership</h3>
<p><strong>A. Change Permissions of files (chmod)</strong></p>
<pre><code>chmod 000 filename.abc</code></pre>
<p><em>(defaults are usually 755 for folders, 644 for files)</em></p>
<div class="tip">
<h3>TIP:</h3>
<p>1st digit=Owner; 2nd=Group; 3rd=Other<br />
(-rwxrwxwrx = 777, -rwxr-xr-x =  755, -rw-r&#8211;r&#8211; = 644, etc.)<br />
7 = Read + Write + Execute<br />
6 = Read + Write<br />
5 = Read + Execute<br />
4 = Read<br />
3 = Write + Execute<br />
2 = Write<br />
1  = Execute<br />
0 = All access denied</p></div>
<p><strong>B. Change Ownership of files (chmown)</strong></p>
<pre><code>chown user:group filename.abc</code></pre>
<p><em>(you can see user and group w/ ls -alh)</em></p>
<div class="tip">
<h3>TIP:</h3>
<p>Anytime a user creates a file, the Ownership of the file matches that user.  In Plesk, every domain that has hosting has a different user. So if you are  copying files from one domain to another, you must remember to change ownership.</p></div>
<h3>IV. Checking Log Files (dv)</h3>
<p>Log files can tell you a lot about whats going on on a (dv). You can use the  command:<br />
&#8216;tail -n 100&#8242; before the logfile name to list the last 100 entries  of the logfile.</p>
<p>Here are some of the most common:</p>
<p><strong>A. Main  Error Log</strong></p>
<pre><code>/var/log/messages</code></pre>
<p><strong>B. Apache Error Log</strong></p>
<pre><code>/var/log/httpd/error_log</code></pre>
<p><em>(main)</em></p>
<pre><code>/home/httpd/vhosts/<span class="ac_replace ac_service_primary_domain">mt-example.com</span>/statistics/logs/error_log</code></pre>
<p><em>(per-domain) (May also be: /var/www/vhosts on newer dvs)</em></p>
<p><strong>C. MySQL Logs</strong></p>
<pre><code>/var/log/MySQLd.log
</code></pre>
<p><strong>D. Mail Logs</strong></p>
<pre><code>/usr/local/psa/var/log/maillog</code></pre>
<p><strong></strong></p>
<div class="note">
<h3>NOTE:</h3>
<p><strong>Common issues to look out for in log files</strong></p>
<ul>
<li>The main error log will not always give you all the information you want for  a svc.</li>
<li>You may see alot of failed SSH and <a class="HelpLink" onclick="showHelpTip(event, '&lt;b&gt;FTP&lt;/b&gt;File Transfer Protocol (FTP) is a network protocol used to transfer data from one computer to another through a network, such as over the Internet.'); return false;" href="javascript:void(0)">FTP</a> connections, that is generally normal.</li>
<li>Keep an eye out for MaxClients errors in the Apache logs if a customer is  complaining of Apache dying alot. You can check the KB for raising MaxClients  settings.</li>
<li>If a customer does not set up Log Rotation for a domain under Plesk, then  Log Files will build up and may take up alot of unneeded space. You can usually  delete old log files in Plesk, and change the Log Rotation to Daily instead of  by size.</li>
<li>MailLogs can show you if a customer is spamming, or if mail is coming in or  out.</li>
<li>MySQL Logs should be able to show you general MySQL errors such as bad  connections, or corrupted tables. Check the Int. KB for the &#8216;myisamchk -r&#8217;  repair table command.</li>
</ul>
</div>
<h3>V. Advanced Commands</h3>
<p><strong>A. Find. You can do alot with find. for now lets find all files over  10MB.</strong></p>
<pre><code>cd /
find / -type f -size +10000k -exec ls -lh {} \; | awk '{ print $5 ": " $9 }' |sort -n
</code></pre>
<p><strong>B. Grep. Another handy tool to get specific information</strong></p>
<pre><code>cat file | grep blah</code></pre>
<p><em>(only lists the information where the word blah is found)</em> <strong></strong></p>
<p><strong>C. Less/More</strong></p>
<pre><code>less filename.abc </code></pre>
<p><em>(displays the content of a file. arrows to scroll, &#8216;q&#8217; to quit.) </em></p>
<p><em></em></p>
<p><em>more == same thing basically.</em> <em>You can use the &#8216;| more&#8217; command  to scroll through something page or line at a time.</em></p>
<pre><code>tail -n 1000 /var/log/httpd/error_log | more</code></pre>
<h3><a class="HelpLink" onclick="showHelpTip(event, '&lt;b&gt;VI&lt;/b&gt;Vim is a highly configurable text editor built to enable efficient text editing. It is an improved version of the vi editor distributed with most UNIX systems.'); return false;" href="javascript:void(0)">VI</a>. Vi is a basic text editor.</h3>
<p>Careful what keys you hit while in vi.</p>
<pre><code>vi /path/to/filename.abc</code></pre>
<div class="tip">
<h3>TIP:</h3>
<p>You can learn more about using the VI/VIM text editor by reading the  following guide:</p>
<ul>
<li><a title="vi" href="http://www.gossiplime.com/2008/09/understanding-basic-vi-visual-editor/">Understanding basic vi (visual editor)</a></li>
</ul>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.gossiplime.com/2008/09/common-ssh-commands/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>

