<?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>Php2s.com Linux Guide</title> <atom:link href="http://www.php2s.com/feed" rel="self" type="application/rss+xml" /><link>http://www.php2s.com</link> <description>Linux, Security, Networking, Open Source for Newbies and Geeks</description> <lastBuildDate>Fri, 11 May 2012 10:21:17 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.2</generator> <item><title>How to Run Mutiple Localhosts Using WAMP (Windows Apache MySQL PHP)</title><link>http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html</link> <comments>http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html#comments</comments> <pubDate>Fri, 11 May 2012 10:21:17 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[PHP]]></category> <category><![CDATA[Programming]]></category> <category><![CDATA[apche]]></category> <category><![CDATA[mysql]]></category> <category><![CDATA[php]]></category> <category><![CDATA[wamp]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=948</guid> <description><![CDATA[Wamp is a web development platform on Windows allowing you to create dynamic web applications with Apache2, PHP and MySQL. This tutorial shows how to run multiple localhosts using WAMP (Windows Apache MySQL PHP). WAMPServer has been a very server for lots of PHP developers (who uses Windows environment). Here’s a simple tutorial on how [...]]]></description> <content:encoded><![CDATA[<div><a
href="http://www.php2s.com/wp-content/uploads/2012/05/wamp-server-small.png"><img
class="alignleft  wp-image-950" title="wamp-server-small" src="http://www.php2s.com/wp-content/uploads/2012/05/wamp-server-small.png" alt="wamp server small How to Run Mutiple Localhosts Using WAMP (Windows Apache MySQL PHP)" width="105" height="105" /></a>Wamp is a web development platform on Windows allowing you to create dynamic web applications with Apache2, PHP and MySQL. This tutorial shows how to run multiple localhosts using WAMP (Windows Apache MySQL PHP). WAMPServer has been a very server for lots of PHP developers (who uses Windows environment). Here’s a simple tutorial on how to run multiple localhosts in WAMP.</div><div><span
id="more-948"></span></div><div><p>WAMP setup localhost2<strong>Basic instructions</strong>:</p><ol><li>update apache.conf (attached) – Update your document root paths to the correct folders. ie – C:/dev/project/trunk/</li><li>update hosts file (C:\Windows\System32\drivers\etc) – run as administrator to update.</li><li>restart apache</li></ol></div><p><strong>If working:</strong></p><blockquote><p>dev.eviport.com points to svn checkout folder<br
/> localhost points to your usual local dev</p><p>hosts file:<br
/> 127.0.0.1       localhost<br
/> 127.0.0.1   dev.project.com</p><p>apache conf:<br
/> Comment out other document root lines and paste the following at the bottom of the file:</p><p>NameVirtualHost *:80<br
/> NameVirtualHost 127.0.0.1:80</p><p>&lt;VirtualHost 127.0.0.1&gt;<br
/> ServerName dev.project.com<br
/> DocumentRoot &#8220;D:/dev/project/trunk/&#8221;<br
/> &lt;Directory &#8220;D:/dev/project/trunk/&#8221;&gt;<br
/> allow from all<br
/> order allow,deny<br
/> AllowOverride All<br
/> &lt;/Directory&gt;<br
/> DirectoryIndex index.html index.php<br
/> &lt;/VirtualHost&gt;</p><p>&lt;VirtualHost 127.0.0.1&gt;<br
/> ServerName localhost<br
/> DocumentRoot &#8220;D:/dev/&#8221;<br
/> &lt;/VirtualHost&gt;</p></blockquote><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-set-up-an-apache-virtual-host-vhost-on-ubuntu.html" rel="bookmark" class="crp_title">How to set up an Apache Virtual Host (vhost) on Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/installing-lamp-linux-apache-mysql-php-on-ubuntu-11-10.html" rel="bookmark" class="crp_title">Installing LAMP (Linux, Apache Mysql PHP) on Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-the-phpbb-forum-on-debian-squeezesid-linux.html" rel="bookmark" class="crp_title">How to install the phpbb forum on Debian (Squeeze/Sid) Linux</a></li><li><a
href="http://www.php2s.com/linux/installing-lamp-server-on-debian-squeeze.html" rel="bookmark" class="crp_title">Installing LAMP Server on Debian Squeeze</a></li><li><a
href="http://www.php2s.com/programming/web-programming/fixing-apache-13permission-denied-access-to-403-forbidden.html" rel="bookmark" class="crp_title">Fixing Apache (13)Permission denied: access to / 403 Forbidden</a></li><li><a
href="http://www.php2s.com/linux/installing-monit-and-restart-apache-automatically-on-centos.html" rel="bookmark" class="crp_title">Installing Monit and Restart Apache Automatically on CentOS</a></li><li><a
href="http://www.php2s.com/database/how-to-secure-mysql-database-server.html" rel="bookmark" class="crp_title">How to Secure MySQL Database Server to Prevent Anonymous Access</a></li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-install-nginx-with-https-support-on-centos.html" rel="bookmark" class="crp_title">How to Install Nginx with HTTPS support on CentOS</a></li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" rel="bookmark" class="crp_title">How to Untar Tar.gz on Linux (Linux Untar Command)</a></li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" rel="bookmark" class="crp_title">Installing Webmin on Ubuntu 12.04 Server using APT</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html" title="wamp">wamp</a> (12)</li><li><a
href="http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html" title="wamp server logo">wamp server logo</a> (2)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to install RecordMyDesktop on RHEL and CentOS</title><link>http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html</link> <comments>http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html#comments</comments> <pubDate>Mon, 30 Apr 2012 14:48:42 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Centos]]></category> <category><![CDATA[RecordMyDesktop]]></category> <category><![CDATA[RHEL]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=940</guid> <description><![CDATA[In this example, I will show how to install Recordmydesktop on Red Hat Linux and CentOS. Recordmydesktop is a command line (and GUI) program that can be used to record a video of the CentOS Desktop (among other distros as well). To install it on CentOS, begin by installing the required dependencies: yum install gcc [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/04/recordmydesktop-logo.png"><img
class="alignleft  wp-image-941" title="recordmydesktop-logo" src="http://www.php2s.com/wp-content/uploads/2012/04/recordmydesktop-logo.png" alt="recordmydesktop logo How to install RecordMyDesktop on RHEL and CentOS" width="95" height="95" /></a>In this example, I will show how to install Recordmydesktop on Red Hat Linux and CentOS. Recordmydesktop is a command line (and GUI) program that can be used to record a video of the CentOS Desktop (among other distros as well). To install it on CentOS, begin by installing the required dependencies:</p><p><span
id="more-940"></span></p><blockquote><p>yum install gcc make libXext-devel libSM-devel libICE-devel zlib-devel libXfixes-devel libXdamage-devel libvorbis-devel libtheora-devel</p></blockquote><p>Because CentOS does not official an RPM for recordmydesktop, we will have to install it from source. We will download a tar of the source code, untar the source, and remove the tar file:</p><blockquote><p>wget http://downloads.sourceforge.net/project/recordmydesktop/recordmydesktop/0.3.8.1/recordmydesktop-0.3.8.1.tar.gz<br
/> tar xf recordmydesktop-0.3.8.1.tar.gz<br
/> rm -rf recordmydesktop-0.3.8.1.tar.gz</p></blockquote><p>Now, let’s go into the folder and install Recordmydesktop.</p><blockquote><p>cd recordmydesktop-0.3.8.1<br
/> ./configure<br
/> make<br
/> make install</p></blockquote><p>If you did not set a custom prefix, running <span
style="color: #ff6600;"><strong>/usr/bin/recordmydesktop</strong></span> should begin recording your desktop! Use the following command (just as with most commands) to view the options available:</p><blockquote><p>recordmydesktop &#8211;help</p></blockquote><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/howto-use-bash-auto-complete-with-yum-on-fedora-centos-rhel.html" rel="bookmark" class="crp_title">Howto use Bash auto complete with YUM on Fedora, CentOS, RHEL</a></li><li><a
href="http://www.php2s.com/linux/howto-install-webmin-1-570-1-on-centos-6-2-using-rpm.html" rel="bookmark" class="crp_title">Howto Guide: Install Webmin 1.570-1 on CentOS 6.2 using RPM</a></li><li><a
href="http://www.php2s.com/linux/how-to-installation-and-configuration-bind-dns-server-on-centos-5-3.html" rel="bookmark" class="crp_title">How to Installation and Configuration BIND DNS Server on CentOS 5.3</a></li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" rel="bookmark" class="crp_title">How to Untar Tar.gz on Linux (Linux Untar Command)</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-ntp-daemon-on-centos-rhel-fedora.html" rel="bookmark" class="crp_title">Install and Configure NTP on CentOS/ RHEL/ Fedora</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-configure-vsftpd-on-rhel-centos-ubuntu-fedora-debian.html" rel="bookmark" class="crp_title">How to Install &#038; Configure Vsftpd on RHEL/CentOS/Ubuntu/Fedora</a></li><li><a
href="http://www.php2s.com/linux/installing-centos-6-2-on-vmware-fusion-step-by-step-guide.html" rel="bookmark" class="crp_title">Installing CentOS 6.2 on VMWare Fusion Step by Step Guide</a></li><li><a
href="http://www.php2s.com/linux/installing-monit-and-restart-apache-automatically-on-centos.html" rel="bookmark" class="crp_title">Installing Monit and Restart Apache Automatically on CentOS</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-turn-on-telnet-service-on-rhel-febora-centos-ubuntu-freebsd-debian.html" rel="bookmark" class="crp_title">how to install &#038; turn on telnet service on RHEL, Fedora, CentOS, Ubuntu, FreeBSD, Debian</a></li><li><a
href="http://www.php2s.com/linux/how-to-modify-iptables-during-kickstart-install-of-centos-6.html" rel="bookmark" class="crp_title">How to modify iptables during Kickstart Install of CentOS 6</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="how to install record my desktop in centos">how to install record my desktop in centos</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="recordmydesktop linux centos 6 2">recordmydesktop linux centos 6 2</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="recordmydesktop centos">recordmydesktop centos</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="can not ftp into centos6 2">can not ftp into centos6 2</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="rhel5 libxfixes-devel">rhel5 libxfixes-devel</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="rhel 6 2 ftp server setup">rhel 6 2 ftp server setup</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="recordmydesktop dependency redhat">recordmydesktop dependency redhat</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="recordmydesktop command in rhel">recordmydesktop command in rhel</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="recordmydesktop centos 6">recordmydesktop centos 6</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" title="record my desktop linux">record my desktop linux</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How To Upgrade to Ubuntu 12.04 for Desktops &amp; Servers running 10.04 or 11.10</title><link>http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html</link> <comments>http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html#comments</comments> <pubDate>Fri, 27 Apr 2012 05:34:28 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Ubuntu]]></category> <category><![CDATA[Ubuntu Update]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=917</guid> <description><![CDATA[This tutorial contains full instructions on how to upgrade to Ubuntu 12.04 from 10.04 or 11.10 for servers and desktops I have included both GUI and command line upgrade instructions for Ubuntu 12.04 updates. If you have any 3rd party propriatory graphics card drivers installed it is recommended you remove them prior to the upgrade [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/04/Ubuntu_Linux_Unix_logo.png"><img
class="alignleft size-full wp-image-919" title="Ubuntu_Linux_Unix_logo" src="http://www.php2s.com/wp-content/uploads/2012/04/Ubuntu_Linux_Unix_logo.png" alt="Ubuntu Linux Unix logo How To Upgrade to Ubuntu 12.04 for Desktops & Servers running 10.04 or 11.10"  /></a>This tutorial contains full instructions on how to upgrade to Ubuntu 12.04 from 10.04 or 11.10 for servers and desktops I have included both GUI and command line upgrade instructions for Ubuntu 12.04 updates.</p><p><em>If you have any 3rd party propriatory graphics card drivers installed it is recommended you remove them prior to the upgrade process to avoid any problems during the update, you can reinstalled them after the upgrade has completed.</em></p><p><em>Always take a backup before carrying out an operating system upgrade!</em></p><p><span
id="more-917"></span></p><h2><strong>How To Upgrade to 12.04 Desktop using the GUI</strong></h2><p>This is by far the easiest way to upgrade you simple wait until the official release date of 12.04 (which is currently the 26th of April 1012) and upgrade when prompted. If this does not happen it’s probably as the servers are getting hammered by users updating you can either wait or follow the instructions below on how to carry out the network upgrade.<br
/> <strong><br
/> How to Upgrade from 11.10 to 12.o4 for Desktops using Update Manager</strong></p><p>If Ubuntu fails to prompt you to upgrade to 12.04 Desktop you can run the update manager process manually, note these instructions are for 11.10 to 12.04 only.</p><ul><li>Run the <strong>Update Manager</strong> application from the<strong> Unity Dash</strong></li><li>In Update Manager, click on “<strong>Settings</strong>” and enter your password to start the Software Sources application</li><li>Select the sub menu <strong>Updates</strong> from the Software Sources application</li><li>Check the “<strong>Release upgrade</strong> &#8211; Show new distribution releases” drop down to make sure “Normal releases” is selected, and change it if otherwise</li><li>Close the Software Sources application and return to Update Manager</li><li>In Update Manager, click the <strong>Check</strong> button to check for new updates.</li><li>If there are any updates to install, use the <strong>Install Updates</strong> button to install them, and press Check again after that is complete</li><li>A message will appear informing you of the availability of the new release</li><li>Click <strong>Upgrade</strong></li><li>Follow the on-screen instructions</li></ul><p><strong>Upgrade from 10.04 to 12.o4 for Desktops using Update Manager</strong></p><p>The following instructions are for 10.04 to 12.04 Desktop upgrades, this uses a network installation using update manager, please only use these instructions for 10.04 to 12.04 desktops.</p><ul><li>Open the<strong> Update Manager</strong> application from the <strong>System → Administration</strong> menu</li><li>In Update Manager, click the “<strong>Settings</strong>…”, and enter your password to start the Software Sources application</li><li>Select the sub menu <strong>Updates</strong> from the Software Sources application</li><li>Check the “<strong>Release upgrade</strong> &#8211; Show new distribution releases” drop down to make sure “<strong>Long term support releases only</strong>” is selected, and change it if otherwise</li><li>Close the Software Sources application and return to Update Manager</li><li>In Update Manager, click the Check button to check for new updates</li><li>If there are any updates to install, use the <strong>Install Updates</strong> button to install them, and press Check again after that is complete</li><li>A message will appear informing you of the availability of the new release</li><li>Click <strong>Upgrade</strong></li><li>Follow the on-screen instructions</li></ul><p><strong>Ubuntu Server upgrade to 12.04 using the command line</strong></p><p>This is my preferred method of upgrading to 12.04 as it can be ran over SSH or on any version of Ubuntu Server.</p><p>To start off with make sure update-manager-core is installed and fully up to date:</p><blockquote><p>sudo apt-get install update-manager-core</p></blockquote><p>Edit the file<strong><span
style="color: #ff6600;"> /etc/update-manager/release-upgrades</span></strong> and add set:</p><blockquote><p>Prompt=normal</p></blockquote><p>Start the upgrade process:</p><blockquote><p>sudo do-release-upgrade</p></blockquote><p>Hope you will find it helpful!</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-install-a-software-application-from-a-terminal-on-ubuntu.html" rel="bookmark" class="crp_title">How to Install a Software Application from a Terminal on Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/download-ubuntu-11-10-oneiric-ocelot-cd-iso-dvd-images-for-3264-bit.html" rel="bookmark" class="crp_title">Download Ubuntu 11.10 (Oneiric Ocelot) CD ISO / DVD Images for 32/64 bit</a></li><li><a
href="http://www.php2s.com/linux/how-to-prepare-anaconda-update-image-for-rhel-fedora-centos.html" rel="bookmark" class="crp_title">How to prepare anaconda update image for RHEL/Fedora/CentOS</a></li><li><a
href="http://www.php2s.com/programming/php-programming/how-to-resolve-fatal-error-allowed-memory-size-of-33554432-bytes-exhausted-tried-to-allocate-30720-bytes.html" rel="bookmark" class="crp_title">How to Resolve Fatal Error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 30720 bytes)</a></li><li><a
href="http://www.php2s.com/linux/howto-downloa-install-centos-6-2-step-by-step-guide-screenshots.html" rel="bookmark" class="crp_title">How to install CentOS 6.2 Step by step guide Screenshots</a></li><li><a
href="http://www.php2s.com/linux/download-linux-mint-12-lisa-gnome-3-mgse-cd-dvd-img-iso.html" rel="bookmark" class="crp_title">Download Linux Mint 12 (Lisa) GNOME 3, MGSE CD/DVD</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-gnome-shell-in-ubuntu-11-10-oneric-ocelot.html" rel="bookmark" class="crp_title">How to Install Gnome Shell in Ubuntu 11.10 Oneric Ocelot</a></li><li><a
href="http://www.php2s.com/linux/how-to-enable-root-login-in-ubuntu-11-10.html" rel="bookmark" class="crp_title">How to Enable Root Login in Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-creat-tun-tap-devices-on-ubuntu-linux.html" rel="bookmark" class="crp_title">How to Create tun/tap devices on Ubuntu/ Linux</a></li><li><a
href="http://www.php2s.com/linux/arch-linux-compared-to-other-distributions.html" rel="bookmark" class="crp_title">Arch Linux Compared to Other Distributions</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="upgrade to ubuntu 12 04 command line">upgrade to ubuntu 12 04 command line</a> (12)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="ubuntu upgrade to 12 04 command line">ubuntu upgrade to 12 04 command line</a> (10)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="Ubuntu 12 04 upgrade command line">Ubuntu 12 04 upgrade command line</a> (7)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="upgrade ubuntu server 10 04 to 12 04">upgrade ubuntu server 10 04 to 12 04</a> (6)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="ubuntu 12 04 server gui">ubuntu 12 04 server gui</a> (6)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="how to upgrade from 10 04 to 12 04">how to upgrade from 10 04 to 12 04</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="ubuntu upgrade 12 04 command line">ubuntu upgrade 12 04 command line</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="how to upgrade 10 04 to 12 04">how to upgrade 10 04 to 12 04</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="upgrade to 12 04 from command line">upgrade to 12 04 from command line</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" title="how to upgradeto ubuntu 12:04">how to upgradeto ubuntu 12:04</a> (3)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to configure network interface on Fedora 16 using NetworkManager</title><link>http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html</link> <comments>http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html#comments</comments> <pubDate>Sun, 22 Apr 2012 14:12:12 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Fedora]]></category> <category><![CDATA[Fedora 16]]></category> <category><![CDATA[NetworkManager]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=908</guid> <description><![CDATA[The step by step example below show how to configure network interface on Fedora 16. The Fedora 16 use NetworkManager to manage network interface, by using NetworkManager this simple step by step tutorial show how to configure network interface to use static IP address. Check network properties. To show network properties type in ifconfig command. [...]]]></description> <content:encoded><![CDATA[<p>The step by step example below show how to configure network interface on Fedora 16. The Fedora 16 use NetworkManager to manage network interface, by using NetworkManager this simple step by step tutorial show how to configure network interface to use static IP address.</p><p><span
id="more-908"></span></p><h2>Check network properties.</h2><p>To show network properties type in <strong><span
style="color: #ff6600;">ifconfig</span></strong> command.<br
/> <strong>1.</strong> Open terminal and type in <strong><span
style="color: #ff6600;">ifconfig</span></strong> command and hit enter key.</p><blockquote><p>[fedora@localhost ~]$ ifconfig</p><p>em1 Link encap:Ethernet HWaddr 00:13:21:65:C7:2D<br
/> UP BROADCAST MULTICAST MTU:1500 Metric:1<br
/> RX packets:0 errors:0 dropped:0 overruns:0 frame:0<br
/> TX packets:0 errors:0 dropped:0 overruns:0 carrier:0<br
/> collisions:0 txqueuelen:1000<br
/> RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)<br
/> Interrupt:17</p><p>em2 Link encap:Ethernet HWaddr 00:13:21:65:C7:2C<br
/> inet addr:60.49.199.75 Bcast:60.49.199.79 Mask:255.255.255.248<br
/> inet6 addr: fe80::213:21ff:fe65:c72c/64 Scope:Link<br
/> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1<br
/> RX packets:14743744 errors:0 dropped:3610 overruns:0 frame:0<br
/> TX packets:691939 errors:0 dropped:0 overruns:0 carrier:0<br
/> collisions:0 txqueuelen:1000<br
/> RX bytes:1863873005 (1.7 GiB) TX bytes:84722609 (80.7 MiB)<br
/> Interrupt:18</p><p>lo Link encap:Local Loopback<br
/> inet addr:127.0.0.1 Mask:255.0.0.0<br
/> inet6 addr: ::1/128 Scope:Host<br
/> UP LOOPBACK RUNNING MTU:16436 Metric:1<br
/> RX packets:429 errors:0 dropped:0 overruns:0 frame:0<br
/> TX packets:429 errors:0 dropped:0 overruns:0 carrier:0<br
/> collisions:0 txqueuelen:0<br
/> RX bytes:36564 (35.7 KiB) TX bytes:36564 (35.7 KiB)</p><p>virbr0 Link encap:Ethernet HWaddr 52:54:00:B7:EB:4F<br
/> inet addr:192.168.122.1 Bcast:192.168.122.255 Mask:255.255.255.0<br
/> UP BROADCAST MULTICAST MTU:1500 Metric:1<br
/> RX packets:0 errors:0 dropped:0 overruns:0 frame:0<br
/> TX packets:0 errors:0 dropped:0 overruns:0 carrier:0<br
/> collisions:0 txqueuelen:0<br
/> RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)</p><p>[fedora@localhost ~]$</p></blockquote><h2>Open NetworkManager configuration tools.</h2><p>Then to start the network configuration process, open NetworkManager configuration tools by type in nm-connection-editor on the terminal.</p><p><strong>2.</strong> Then type in <span
style="color: #ff6600;"><strong>nm-connection-editor</strong></span> and hit enter key, this open the interface of NetworkManager configuration tools&#8230;<br
/> <a
href="http://www.php2s.com/wp-content/uploads/2012/04/networkmanager-config1.png"><img
class="aligncenter size-full wp-image-912" title="networkmanager-config1" src="http://www.php2s.com/wp-content/uploads/2012/04/networkmanager-config1.png" alt="networkmanager config1 How to configure network interface on Fedora 16 using NetworkManager" width="567" height="338" /></a></p><p><strong>3.</strong> Choose network device that you need to configure and the click edit button&#8230; on the example, we choose system em1 network device to edit as an example&#8230; then go to <strong>IPv4 Settings</strong> tab and choose <strong>Manual</strong> by clicking the Method drop down menu<br
/> <a
href="http://www.php2s.com/wp-content/uploads/2012/04/activate-nm4.png"><img
class="aligncenter size-full wp-image-909" title="activate-nm4" src="http://www.php2s.com/wp-content/uploads/2012/04/activate-nm4.png" alt="activate nm4 How to configure network interface on Fedora 16 using NetworkManager" width="539" height="251" /></a></p><p><strong>4.</strong> Then&#8230; Click on Add button and start adding IP Address. then proceed to put your network DNS server address&#8230;<br
/> <a
href="http://www.php2s.com/wp-content/uploads/2012/04/static-ip3.png"><img
class="aligncenter size-full wp-image-910" title="static-ip3" src="http://www.php2s.com/wp-content/uploads/2012/04/static-ip3.png" alt="static ip3 How to configure network interface on Fedora 16 using NetworkManager" width="497" height="552" /></a></p><p><strong>5.</strong> Then click on Save button to apply the changes. to activate network interface or to enable disable network interface go to NetworkManager applet (nm-applet) as show on the screenshot below.<br
/> <a
href="http://www.php2s.com/wp-content/uploads/2012/04/ipv4-setting2.png"><img
class="aligncenter size-full wp-image-911" title="ipv4-setting2" src="http://www.php2s.com/wp-content/uploads/2012/04/ipv4-setting2.png" alt="ipv4 setting2 How to configure network interface on Fedora 16 using NetworkManager" width="464" height="552" /></a></p><p>Please note :- that this network configuration example tested on Linux Fedora 16 machine&#8230; the output may vary base on your machine use, operating system and command version.</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-configure-network-card-in-red-hat-enterprise-linux-centos-fedora-core-from-cli.html" rel="bookmark" class="crp_title">How to configure network card in Red Hat Enterprise Linux, CentOS, Fedora Core from CLI</a></li><li><a
href="http://www.php2s.com/linux/how-to-setup-a-fedora-red-hat-linux-or-centos-dhcp-client.html" rel="bookmark" class="crp_title">How to Setup a Fedora / Red Hat Linux or CentOS DHCP Client</a></li><li><a
href="http://www.php2s.com/linux/install-fresh-centos-ilo-install-no-internet-connectivity-yum-wget-etc-fail.html" rel="bookmark" class="crp_title">Install fresh CentOS iLO install, no internet connectivity (yum, wget etc. fail)</a></li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" rel="bookmark" class="crp_title">How to Set Static IP Address in Centos 6.2 Linux Server</a></li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" rel="bookmark" class="crp_title">Step by Step Delete Windows Partition using fdisk command on Linux Fedora System</a></li><li><a
href="http://www.php2s.com/networking/how-to-create-an-ip-ip-tunnel-among-three-networks.html" rel="bookmark" class="crp_title">How to create an ip-ip tunnel among three Networks</a></li><li><a
href="http://www.php2s.com/networking/how-to-create-map-of-local-network-lan-using-lanmap.html" rel="bookmark" class="crp_title">How to create map of local network (LAN) using Lanmap</a></li><li><a
href="http://www.php2s.com/linux/step-by-step-install-and-configure-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">Step by Step Install and Configure Squid Proxy Server on CentOS 6.2 / RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" rel="bookmark" class="crp_title">How To Upgrade to Ubuntu 12.04 for Desktops &#038; Servers running 10.04 or 11.10</a></li><li><a
href="http://www.php2s.com/linux/installing-centos-6-2-on-vmware-fusion-step-by-step-guide.html" rel="bookmark" class="crp_title">Installing CentOS 6.2 on VMWare Fusion Step by Step Guide</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="fedora 16 network manager">fedora 16 network manager</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="network manager fedora 16">network manager fedora 16</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="how to configure network in fedora 16">how to configure network in fedora 16</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="enabling network interface in fedora 16">enabling network interface in fedora 16</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="simple guide for network on fedora 16">simple guide for network on fedora 16</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="how to configure static ip in fedora 16">how to configure static ip in fedora 16</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="how to configure lan settings in fedora 16">how to configure lan settings in fedora 16</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="fedora configure network interface">fedora configure network interface</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="how to enable ethernet in fedora 16">how to enable ethernet in fedora 16</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" title="fedora 16 networkmanager">fedora 16 networkmanager</a> (2)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>JavaScript – Detect Viewport Size,Screen Resolution,Mouse Position</title><link>http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html</link> <comments>http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html#comments</comments> <pubDate>Sun, 22 Apr 2012 08:09:13 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Javascript]]></category> <category><![CDATA[Programming]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=902</guid> <description><![CDATA[Detect Viewport Size, Screen Resolution, Mouse Position When we Surf the Internet Many Visitors See That Some Website has Auto-Detect System For Viewport Size,Screen Resolution and Mouse Position of User System. This System is Created By Using JavaScript.So Here Is The Code For Creating this Auto-Detect System in JavaScript. To Use This Code Just Copy [...]]]></description> <content:encoded><![CDATA[<h3><a
href="http://www.php2s.com/wp-content/uploads/2012/04/Javascript.jpg"><img
class="alignleft size-full wp-image-946" title="Javascript" src="http://www.php2s.com/wp-content/uploads/2012/04/Javascript.jpg" alt="Javascript JavaScript – Detect Viewport Size,Screen Resolution,Mouse Position"  /></a>Detect Viewport Size, Screen Resolution, Mouse Position</h3><p>When we Surf the Internet Many Visitors See That Some Website has Auto-Detect System For Viewport Size,Screen Resolution and Mouse Position of User System.</p><p>This System is Created By Using JavaScript.So Here Is The Code For Creating this Auto-Detect System in JavaScript.</p><p><span
id="more-902"></span></p><p>To Use This Code Just Copy and Paste It.</p><blockquote><pre>&lt;script type="text/javascript"&gt;
function getViewportWidth()
{
if (window.innerWidth)
{
return window.innerWidth;
}
else if (document.body &amp;&amp; document.body.offsetWidth)
{
return document.body.offsetWidth;
}
else
{
return 0;
}
}
function getViewportHeight()
{
if (window.innerHeight)
{
return window.innerHeight;
}
else if (document.body &amp;&amp; document.body.offsetHeight)
{
return document.body.offsetHeight;&lt;br /&gt;
}
else
{
return 0;
}
}
var tellMeTheSizes=function()
{
document.getElementById("viewportwidth").innerHTML = getViewportWidth() + "px";
document.getElementById("viewportheight").innerHTML = getViewportHeight() + "px";
document.getElementById("resolutionheight").innerHTML = screen.height + "px";
document.getElementById("resolutionwidth").innerHTML = screen.width + "px";
}
window.onload=function()
{
tellMeTheSizes();
}
window.onresize=function()
{
tellMeTheSizes();
}
window.onmousemove=function(event)
{
ev = event || window.event;
document.getElementById("mousetop").innerHTML = ev.pageY + "px";
document.getElementById("mouseleft").innerHTML = ev.pageX + "px";
}
&lt;/script&gt;</pre></blockquote><p>&nbsp;</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/programming/javascript/javascript-delayed-redirect-script-and-tutorial.html" rel="bookmark" class="crp_title">Javascript Delayed Redirect Script and Tutorial</a></li><li><a
href="http://www.php2s.com/programming/javascript/javascript-settimeout-function-javascript-timing-events-tutorial.html" rel="bookmark" class="crp_title">JavaScript setTimeout Function &#8211; JavaScript Timing Events Tutorial</a></li><li><a
href="http://www.php2s.com/programming/web-programming/how-to-disable-scripts-and-styles.html" rel="bookmark" class="crp_title">How to disable scripts and styles</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-gnome-shell-in-ubuntu-11-10-oneric-ocelot.html" rel="bookmark" class="crp_title">How to Install Gnome Shell in Ubuntu 11.10 Oneric Ocelot</a></li><li><a
href="http://www.php2s.com/linux/how-to-change-permissions-in-ubuntu-11-10-oneiric-ocelot-with-the-chmod-command.html" rel="bookmark" class="crp_title">How to change permissions in Ubuntu 11.10 Oneiric Ocelot with the chmod command</a></li><li><a
href="http://www.php2s.com/linux/vi-commands-cheat-sheet-vi-short-commands-reference-linux.html" rel="bookmark" class="crp_title">Vi Commands Cheat sheet &#8211; Vi short commands reference linux</a></li><li><a
href="http://www.php2s.com/linux/how-to-enable-root-login-in-ubuntu-11-10.html" rel="bookmark" class="crp_title">How to Enable Root Login in Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html" rel="bookmark" class="crp_title">How to Run Mutiple Localhosts Using WAMP (Windows Apache MySQL PHP)</a></li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" rel="bookmark" class="crp_title">PHP Tutorial: A Quick Way to Break up a URL into usable Pieces</a></li><li><a
href="http://www.php2s.com/programming/php-programming/php-memory-usage-information-class.html" rel="bookmark" class="crp_title">PHP Memory Usage Information Class</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="auto viewport javascript">auto viewport javascript</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="viewport javascript">viewport javascript</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="screen size detection javascript php 2012">screen size detection javascript php 2012</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="php script detect viewport size">php script detect viewport size</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="php screen resolution detection">php screen resolution detection</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="linux detect mouse">linux detect mouse</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="javascript viewport position">javascript viewport position</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="include javascript screen size detection">include javascript screen size detection</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="html javascript window viewport height -jquery">html javascript window viewport height -jquery</a> (1)</li><li><a
href="http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html" title="detect viewport size javascript">detect viewport size javascript</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/programming/javascript/javascript-detect-viewport-sizescreen-resolutionmouse-position.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Step by Step Delete Windows Partition using fdisk command on Linux Fedora System</title><link>http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html</link> <comments>http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html#comments</comments> <pubDate>Sun, 22 Apr 2012 07:48:44 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[delete partition]]></category> <category><![CDATA[delete partition windows]]></category> <category><![CDATA[delete windows]]></category> <category><![CDATA[delete windows partition]]></category> <category><![CDATA[Fedora]]></category> <category><![CDATA[using fdisk to delete windows partition]]></category> <category><![CDATA[windows delete partition]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=891</guid> <description><![CDATA[This tutorial show how to delete windows partition using fdisk command on Linux Fedora System Step by Step. The procedure below use fdisk command to delete the Windows partition table inside the external USB hard disk on Linux Fedora system&#8230; To delete Windows partition, please make sure that you know which partition that you want [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/04/fedora-logo.png"><img
class="alignleft size-full wp-image-924" title="fedora-logo" src="http://www.php2s.com/wp-content/uploads/2012/04/fedora-logo.png" alt="fedora logo Step by Step Delete Windows Partition using fdisk command on Linux Fedora System"  /></a> This tutorial show how to delete windows partition using fdisk command on Linux Fedora System Step by Step. The procedure below use fdisk command to delete the Windows partition table inside the external USB hard disk on Linux Fedora system&#8230; To delete Windows partition, please make sure that you know which partition that you want to delete before you follow the procedure below &#8230; ones you delete the Windows partition&#8230; all data inside that partition also deleted (gone forever). Please note that the same procedure could be apply to delete Linux partition.</p><p><span
id="more-891"></span></p><h2><span
style="color: #3366ff;">Delete Windows Partition:</span></h2><p><strong>1.</strong> List the windows partition that you want to delete using fdisk -l [target device] command. The example below show that the Windows partition that we want to delete is on the <em>/dev/sdb</em> hard disk device and on the partition number 1 ( show as sdb1 )<br
/> <a
href="http://www.php2s.com/wp-content/uploads/2012/04/windows_partition1.png"><img
class="aligncenter size-full wp-image-892" title="windows_partition1" src="http://www.php2s.com/wp-content/uploads/2012/04/windows_partition1.png" alt="windows partition1 Step by Step Delete Windows Partition using fdisk command on Linux Fedora System" width="500" height="212" /></a></p><blockquote><p>[root@fedora ~]# <strong>fdisk -l /dev/sdb</strong></p><p>Disk /dev/sdb: 40.0 GB, 40007761920 bytes<br
/> 64 heads, 32 sectors/track, 38154 cylinders<br
/> Units = cylinders of 2048 * 512 = 1048576 bytes<br
/> Disk identifier: 0x00b4c6f2</p><p>Device Boot Start End Blocks Id System</p><p>/dev/sdb1 1 38154 39069680 c W95 FAT32 (LBA)</p><p>[root@fedora ~]#</p></blockquote><p><strong>2.</strong> Execute the fdisk command as show on the example below.<br
/> <a
href="http://www.php2s.com/wp-content/uploads/2012/04/delete_windows.png"><img
class="aligncenter size-full wp-image-895" title="delete_windows" src="http://www.php2s.com/wp-content/uploads/2012/04/delete_windows.png" alt="delete windows Step by Step Delete Windows Partition using fdisk command on Linux Fedora System" width="500" height="212" /></a></p><blockquote><p>[root@fedora ~]# fdisk /dev/sdb</p></blockquote><p><em>The number of cylinders for this disk is set to 38154.</em><br
/> <em> There is nothing wrong with that, but this is larger than 1024,</em><br
/> <em> and could in certain setups cause problems with:</em></p><p><em>1) software that runs at boot time (e.g., old versions of LILO)</em><br
/> <em> 2) booting and partitioning software from other OSs</em></p><p><em>(e.g., DOS FDISK, OS/2 FDISK)</em></p><p><strong>3.</strong> Then type in &#8216;m&#8217; key and hit Enter key to display the help menu for fdisk command. Command (m for help): <span
style="color: #ff6600;"><strong>m</strong></span></p><p><strong>Command action</strong></p><p><em>a toggle a bootable flag</em><br
/> <em> b edit bsd disklabel</em><br
/> <em> c toggle the dos compatibility flag</em><br
/> <em> d delete a partition</em><br
/> <em> l list known partition types</em><br
/> <em> m print this menu</em><br
/> <em> n add a new partition</em><br
/> <em> o create a new empty DOS partition table</em><br
/> <em> p print the partition table</em><br
/> <em> q quit without saving changes</em><br
/> <em> s create a new empty Sun disklabel</em><br
/> <em> t change a partition&#8217;s system id</em><br
/> <em> u change display/entry units</em><br
/> <em> v verify the partition table</em><br
/> <em> w write table to disk and exit</em><br
/> <em> x extra functionality (experts only)</em></p><p><strong>4.</strong> Type in &#8216;d&#8217; key and hit Enter key to delete a partition, select the partition that you want to delete.<br
/> Command (m for help): <strong><span
style="color: #ff6600;">d</span></strong></p><p>Selected partition 1</p><p><strong>5.</strong> Verify again by type in &#8216;p&#8217; command, to list all partition table inside the hard disk.<br
/> Command (m for help): <span
style="color: #ff6600;"><strong>p</strong></span></p><p><em>Disk /dev/sdb: 40.0 GB, 40007761920 bytes</em><br
/> <em> 64 heads, 32 sectors/track, 38154 cylinders</em><br
/> <em> Units = cylinders of 2048 * 512 = 1048576 bytes</em><br
/> <em> Disk identifier: 0x00b4c6f2</em><br
/> <em> Device Boot Start End Blocks Id System</em></p><p><strong>6.</strong> Save the changes that you made by type in the &#8216;w&#8217; key then hit Enter key<br
/> Command (m for help): <strong><span
style="color: #ff6600;">w</span></strong></p><p>The partition table has been altered!</p><p>Calling ioctl() to re-read partition table.<br
/> Syncing disks.</p><p>[root@fedora ~]#</p><p><a
href="http://www.php2s.com/wp-content/uploads/2012/04/windows_deleted.png"><img
class="aligncenter size-full wp-image-896" title="windows_deleted" src="http://www.php2s.com/wp-content/uploads/2012/04/windows_deleted.png" alt="windows deleted Step by Step Delete Windows Partition using fdisk command on Linux Fedora System" width="500" height="196" /></a></p><h2><span
style="color: #3366ff;">Check deleted partition on hard disk</span></h2><p>To verify: After exit the fdisk command&#8230; check Windows deleted partition again using fdisk command as show on example below.</p><blockquote><p>[root@fedora ~]# <strong>fdisk -l /dev/sdb</strong></p></blockquote><p><em>Disk /dev/sdb: 40.0 GB, 40007761920 bytes</em><br
/> <em> 64 heads, 32 sectors/track, 38154 cylinders</em><br
/> <em> Units = cylinders of 2048 * 512 = 1048576 bytes</em><br
/> <em> Disk identifier: 0x00b4c6f2</em></p><p><em>Device Boot Start End Blocks Id System</em></p><p>[root@fedora ~]#</p><p>Hope the example will be helpful!</p><p>&nbsp;</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/ps-replacing-failed-raid-drive.html" rel="bookmark" class="crp_title">(P/S) Replacing failed Raid Drive</a></li><li><a
href="http://www.php2s.com/linux/howto-downloa-install-centos-6-2-step-by-step-guide-screenshots.html" rel="bookmark" class="crp_title">How to install CentOS 6.2 Step by step guide Screenshots</a></li><li><a
href="http://www.php2s.com/linux/qa-linux-lvm-extend-on-software-raid-partition.html" rel="bookmark" class="crp_title">(Q/A) Linux LVM Extend on Software RAID Partition</a></li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" rel="bookmark" class="crp_title">How to configure network interface on Fedora 16 using NetworkManager</a></li><li><a
href="http://www.php2s.com/linux/how-to-change-default-boot-up-runlevel-for-linux-centos-fedora-by-inittab-config-file.html" rel="bookmark" class="crp_title">How to change default boot up runlevel for Linux CentOS Fedora by inittab config file</a></li><li><a
href="http://www.php2s.com/linux/howto-setup-iscsi-san-server-on-centos-red-hat-linux.html" rel="bookmark" class="crp_title">Howto Setup iSCSI San Server on CentOS / Red Hat Linux</a></li><li><a
href="http://www.php2s.com/linux/howto-guide-setup-local-yum-repository-on-centos-6-2-from-cddvd-image.html" rel="bookmark" class="crp_title">Howto Guide: Setup Local Yum Repository on CentOS 6.2 from CD/DVD image</a></li><li><a
href="http://www.php2s.com/linux/how-to-change-permissions-in-ubuntu-11-10-oneiric-ocelot-with-the-chmod-command.html" rel="bookmark" class="crp_title">How to change permissions in Ubuntu 11.10 Oneiric Ocelot with the chmod command</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-turn-on-telnet-service-on-rhel-febora-centos-ubuntu-freebsd-debian.html" rel="bookmark" class="crp_title">how to install &#038; turn on telnet service on RHEL, Fedora, CentOS, Ubuntu, FreeBSD, Debian</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-configure-vsftpd-on-rhel-centos-ubuntu-fedora-debian.html" rel="bookmark" class="crp_title">How to Install &#038; Configure Vsftpd on RHEL/CentOS/Ubuntu/Fedora</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="fdisk step by step">fdisk step by step</a> (6)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="ubuntu delete fdisk delete partition">ubuntu delete fdisk delete partition</a> (4)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="ubuntu 11 10 fdisk delete partition">ubuntu 11 10 fdisk delete partition</a> (2)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="command to delete partition">command to delete partition</a> (1)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="why delete windows partition linux">why delete windows partition linux</a> (1)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="what is the command to delete the created partition in linux step by step">what is the command to delete the created partition in linux step by step</a> (1)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="usb fdisk partition for windows and linux">usb fdisk partition for windows and linux</a> (1)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="steps to fdisk in linux">steps to fdisk in linux</a> (1)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="step to change the partition table using fdisk">step to change the partition table using fdisk</a> (1)</li><li><a
href="http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html" title="linux ubuntu delete windows partition">linux ubuntu delete windows partition</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/step-by-step-delete-windows-partition-using-fdisk-command-on-linux-fedora-system.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to Set Static IP Address in Centos 6.2 Linux Server</title><link>http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html</link> <comments>http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html#comments</comments> <pubDate>Sun, 22 Apr 2012 06:38:02 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[CentOS 6.2]]></category> <category><![CDATA[IP Address]]></category> <category><![CDATA[Server]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=886</guid> <description><![CDATA[This tutorial shows how to configure static ip address on CentOS 6.2 Linux Server. After you have installed CentOS 6.2 linux server, the system will not get the ip automatically and the network interface will not auto start even after the server rebooted. The default system configuration will be as below: DEVICE=&#8221;eth0&#8243; HWADDR=&#8221;xx:xx:xx:xx:xx:xx&#8221; NM_CONTROLLED=&#8221;yes&#8221; ONBOOT=&#8221;no&#8221; [...]]]></description> <content:encoded><![CDATA[<p>This tutorial shows how to configure static ip address on CentOS 6.2 Linux Server. After you have installed CentOS 6.2 linux server, the system will not get the ip automatically and the network interface will not auto start even after the server rebooted.<span
id="more-886"></span> The default system configuration will be as below:</p><blockquote><p>DEVICE=&#8221;eth0&#8243;<br
/> HWADDR=&#8221;xx:xx:xx:xx:xx:xx&#8221;<br
/> NM_CONTROLLED=&#8221;yes&#8221;<br
/> ONBOOT=&#8221;no&#8221;</p></blockquote><p>Follow this steps to set static ip and set it auto start once rebooted in CentOS 6.2 :</p><p><span
style="color: #ff0000;"><strong>1. Configure eth0:</strong></span></p><blockquote><p>[root@centos6 ~]# vi /etc/sysconfig/network-scripts/ifcfg-eth0</p><p>DEVICE=&#8221;eth0&#8243;<br
/> HWADDR=&#8221;00:0C:29:67:51:B1&#8243;<br
/> NM_CONTROLLED=&#8221;yes&#8221;<br
/> ONBOOT=&#8221;yes&#8221;<br
/> IPADDR=192.168.1.44<br
/> BOOTPRO=static<br
/> NETMASK=255.255.255.0</p></blockquote><p><span
style="color: #ff0000;"><strong>2. Configure Default gateway:</strong></span></p><blockquote><p>[root@centos6 ~]# vi /etc/sysconfig/network</p><p>NETWORKING=yes<br
/> HOSTNAME=centos6.2<br
/> GATEWAY=192.168.1.1</p></blockquote><p><span
style="color: #ff0000;"><strong>3. Restart Network interface:</strong></span></p><blockquote><p>[root@centos6 ~]# /etc/init.d/network restart</p></blockquote><p>or</p><blockquote><p>[root@centos6 ~]# Service network restart</p></blockquote><p><span
style="color: #ff0000;"><strong>4. Configure DNS server:</strong></span></p><blockquote><p>[root@centos6 ~]# vi /etc/resolv.conf</p><p>nameserver 8.8.8.8<br
/> nameserver 192.168.1.1</p></blockquote><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-setup-a-fedora-red-hat-linux-or-centos-dhcp-client.html" rel="bookmark" class="crp_title">How to Setup a Fedora / Red Hat Linux or CentOS DHCP Client</a></li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-card-in-red-hat-enterprise-linux-centos-fedora-core-from-cli.html" rel="bookmark" class="crp_title">How to configure network card in Red Hat Enterprise Linux, CentOS, Fedora Core from CLI</a></li><li><a
href="http://www.php2s.com/linux/install-fresh-centos-ilo-install-no-internet-connectivity-yum-wget-etc-fail.html" rel="bookmark" class="crp_title">Install fresh CentOS iLO install, no internet connectivity (yum, wget etc. fail)</a></li><li><a
href="http://www.php2s.com/linux/howto-install-webmin-1-570-1-on-centos-6-2-using-rpm.html" rel="bookmark" class="crp_title">Howto Guide: Install Webmin 1.570-1 on CentOS 6.2 using RPM</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-apache-httpd-on-centos-6-2.html" rel="bookmark" class="crp_title">Howto Guide: Install &#038; Start Apache or Httpd Service on CentOS 6.2</a></li><li><a
href="http://www.php2s.com/linux/howto-guide-setup-local-yum-repository-on-centos-6-2-from-cddvd-image.html" rel="bookmark" class="crp_title">Howto Guide: Setup Local Yum Repository on CentOS 6.2 from CD/DVD image</a></li><li><a
href="http://www.php2s.com/linux/step-by-step-install-and-configure-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">Step by Step Install and Configure Squid Proxy Server on CentOS 6.2 / RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-interface-on-fedora-16-using-networkmanager.html" rel="bookmark" class="crp_title">How to configure network interface on Fedora 16 using NetworkManager</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-ntp-daemon-on-centos-rhel-fedora.html" rel="bookmark" class="crp_title">Install and Configure NTP on CentOS/ RHEL/ Fedora</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-turn-on-telnet-service-on-rhel-febora-centos-ubuntu-freebsd-debian.html" rel="bookmark" class="crp_title">how to install &#038; turn on telnet service on RHEL, Fedora, CentOS, Ubuntu, FreeBSD, Debian</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="centos 6 2 set static ip">centos 6 2 set static ip</a> (11)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="set static ip centos 6 2">set static ip centos 6 2</a> (9)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="centos 6 2 configure static ip">centos 6 2 configure static ip</a> (8)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="centos 6 2 configure eth0">centos 6 2 configure eth0</a> (8)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="centos 6 2 static ip">centos 6 2 static ip</a> (7)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="centos 6 static ip">centos 6 static ip</a> (7)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="how to configure ip in centos 6 2">how to configure ip in centos 6 2</a> (6)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="how to set static ip on centos">how to set static ip on centos</a> (6)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="static ip address centos 6 2">static ip address centos 6 2</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" title="changing to static ip in centos 6 2">changing to static ip in centos 6 2</a> (5)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Installing Webmin on Ubuntu 12.04 Server using APT</title><link>http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html</link> <comments>http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html#comments</comments> <pubDate>Thu, 19 Apr 2012 08:29:22 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Feature]]></category> <category><![CDATA[Linux]]></category> <category><![CDATA[Server]]></category> <category><![CDATA[Ubuntu]]></category> <category><![CDATA[Unix]]></category> <category><![CDATA[Webmin]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=875</guid> <description><![CDATA[Webmin is a user-friendly web-based interface for Linux server system administration. Using any modern web browser, you can setup user accounts, Apache, DNS, file sharing and much more. Webmin removes the need to manually edit Unix configuration files like /etc/passwd, and lets you manage a system from the console or remotely. Previously installing Webmin on [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/04/logo-webmin.png"><img
class="alignleft  wp-image-876" title="logo-webmin" src="http://www.php2s.com/wp-content/uploads/2012/04/logo-webmin.png" alt="logo webmin Installing Webmin on Ubuntu 12.04 Server using APT" width="210" height="158" /></a>Webmin is a user-friendly web-based interface for Linux server system administration. Using any modern web browser, you can setup user accounts, Apache, DNS, file sharing and much more. Webmin removes the need to manually edit Unix configuration files like /etc/passwd, and lets you manage a system from the console or remotely.</p><p>Previously installing Webmin on your Ubuntu server required a few workarounds thanks to its reliance on deprecated perl libraries, but nowadays you can actually do a full install via the standard APT mechanism.<br
/> <span
id="more-875"></span></p><p>First, edit your sources file to add the Webmin repository:</p><blockquote><p>sudo nano /etc/apt/sources.list</p></blockquote><p>Add the following two lines at the end of the file:</p><blockquote><p>deb http://download.webmin.com/download/repository sarge contrib<br
/> deb http://webmin.mirror.somersettechsolutions.co.uk/repository sarge contrib</p></blockquote><p>Next, add the necessary key to ensure smooth access:</p><blockquote><p>cd ~<br
/> wget http://www.webmin.com/jcameron-key.asc<br
/> sudo apt-key add jcameron-key.asc</p></blockquote><p>Now that we’re all set up, time to do the actual download and install:</p><blockquote><p>sudo apt-get update<br
/> apt-get install webmin<br
/> apt-get -f install</p></blockquote><p>Done. You should now be able to login to Webmin at the URL <em><strong><span
style="color: #ff6600;">http://localhost:10000/</span></strong></em>. Or if accessing it remotely, replace localhost with your system’s IP address. You can login in with any user account that has sudo powers.</p><p><a
href="http://www.php2s.com/wp-content/uploads/2012/04/Install-webmin-using-ubuntu.png"><img
class="size-full wp-image-878 aligncenter" title="Install-webmin-using-ubuntu" src="http://www.php2s.com/wp-content/uploads/2012/04/Install-webmin-using-ubuntu.png" alt="Install webmin using ubuntu Installing Webmin on Ubuntu 12.04 Server using APT" width="550" height="409" /></a></p><p>Related Link<br
/> <a
href="http://www.webmin.com/index.html">http://www.webmin.com/index.html</a></p><p><em><span
style="color: #888888;"><a
href="http://www.codeunit.co.za/"><span
style="color: #888888;">Reference</span></a></span></em></p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/howto-install-webmin-1-570-1-on-centos-6-2-using-rpm.html" rel="bookmark" class="crp_title">Howto Guide: Install Webmin 1.570-1 on CentOS 6.2 using RPM</a></li><li><a
href="http://www.php2s.com/linux/installing-lamp-linux-apache-mysql-php-on-ubuntu-11-10.html" rel="bookmark" class="crp_title">Installing LAMP (Linux, Apache Mysql PHP) on Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-configure-vsftpd-on-rhel-centos-ubuntu-fedora-debian.html" rel="bookmark" class="crp_title">How to Install &#038; Configure Vsftpd on RHEL/CentOS/Ubuntu/Fedora</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-a-software-application-from-a-terminal-on-ubuntu.html" rel="bookmark" class="crp_title">How to Install a Software Application from a Terminal on Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/how-to-enable-root-login-in-ubuntu-11-10.html" rel="bookmark" class="crp_title">How to Enable Root Login in Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-a-perl-module-in-linux-without-root-permission.html" rel="bookmark" class="crp_title">How to Install A Perl Module In Linux Without Root Permission</a></li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" rel="bookmark" class="crp_title">How To Upgrade to Ubuntu 12.04 for Desktops &#038; Servers running 10.04 or 11.10</a></li><li><a
href="http://www.php2s.com/linux/installing-centos-6-2-on-vmware-fusion-step-by-step-guide.html" rel="bookmark" class="crp_title">Installing CentOS 6.2 on VMWare Fusion Step by Step Guide</a></li><li><a
href="http://www.php2s.com/linux/how-to-change-ownership-with-the-chown-command-on-ubuntu-11-10-oneiric-ocelot.html" rel="bookmark" class="crp_title">How to Change Ownership With The chown Command On Ubuntu 11.10 Oneiric Ocelot</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-turn-on-telnet-service-on-rhel-febora-centos-ubuntu-freebsd-debian.html" rel="bookmark" class="crp_title">how to install &#038; turn on telnet service on RHEL, Fedora, CentOS, Ubuntu, FreeBSD, Debian</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="webmin ubuntu 12 04">webmin ubuntu 12 04</a> (26)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="ubuntu 12 04 webmin">ubuntu 12 04 webmin</a> (23)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="ubuntu 12 webmin">ubuntu 12 webmin</a> (20)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="webmin ubuntu 12">webmin ubuntu 12</a> (20)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="install webmin ubuntu 12 04">install webmin ubuntu 12 04</a> (16)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="webmin ubuntu server 12 04">webmin ubuntu server 12 04</a> (12)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="ubuntu 12 04 server webmin">ubuntu 12 04 server webmin</a> (10)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="ubuntu server 12 04 webmin">ubuntu server 12 04 webmin</a> (10)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="install webmin ubuntu server 12 04">install webmin ubuntu server 12 04</a> (9)</li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" title="install webmin ubuntu 12">install webmin ubuntu 12</a> (9)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to Encrypt LAN and wifi traffic on small private network</title><link>http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html</link> <comments>http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html#comments</comments> <pubDate>Tue, 27 Mar 2012 05:36:36 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Networking]]></category> <category><![CDATA[Encrypt]]></category> <category><![CDATA[lan]]></category> <category><![CDATA[VPN]]></category> <category><![CDATA[Wifi]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=862</guid> <description><![CDATA[Question: How to Encrypt LAN and WiFi traffic on small private network. I want to encrypt all traffic on a small private network running wi-fi and LAN traffic on 192.168.0.x network. The network would comprise of client laptops connecting to the wi-fi router (192.168.0.254) via ethernet connection or wireless. The main purpose of the server [...]]]></description> <content:encoded><![CDATA[<p><strong><a
href="http://www.php2s.com/wp-content/uploads/2012/03/questions-qa.png"><img
class="alignleft  wp-image-864" title="questions-qa" src="http://www.php2s.com/wp-content/uploads/2012/03/questions-qa-300x191.png" alt="questions qa 300x191 How to Encrypt LAN and wifi traffic on small private network" width="210" height="134" /></a>Question:</strong><br
/> How to Encrypt LAN and WiFi traffic on small private network. I want to encrypt all traffic on a small private network running wi-fi and LAN traffic on 192.168.0.x network. The network would comprise of client laptops connecting to the wi-fi router (192.168.0.254) via ethernet connection or wireless. The main purpose of the server is for the client laptops to talk to two servers on different IP’s (192.168.0.200 and 192.168.0.201) on ports 80 and 433.<span
id="more-862"></span></p><p>My main concern is having packet sniffers and what not getting access to the data.</p><p>The only ways I see at the moment is to have VPN running on the network or use IPSec policy’s to do this. Is there any other way to do that?</p><p><strong>Answer:</strong><br
/> IPSEC is the network layer encryption designed specifically to cover this case (among others).</p><p>If you do not want to mess with it because of the complexity and cannot use HTTPS throughout for some reason, you might consider relying on your network equipment’s isolation features. WPA2-enterprise encrypts client-to-AP traffic and is not susceptible to man-in-the-middle attacks due to a secret shared among all users as WPA-PSK would be. Managed switches allow either for locking down the MAC forwarding database or using authenticated connections (802.1x) with a MAC address lockdown so MAC spoofing attacks allowing authenticated users to sniff on other user’s data would be mitigated. This would not protect your users from a direct tap on layer 1 though (e.g. a hub or a wiretap device installed somewhere between the switch port and the user’s laptop Ethernet jack).</p><p>Answered by <a
href="http://serverfault.com/users/76595/syneticon-dj">syneticon-dj</a></p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/networking/how-to-create-map-of-local-network-lan-using-lanmap.html" rel="bookmark" class="crp_title">How to create map of local network (LAN) using Lanmap</a></li><li><a
href="http://www.php2s.com/networking/how-to-create-an-ip-ip-tunnel-among-three-networks.html" rel="bookmark" class="crp_title">How to create an ip-ip tunnel among three Networks</a></li><li><a
href="http://www.php2s.com/linux/how-to-configure-network-card-in-red-hat-enterprise-linux-centos-fedora-core-from-cli.html" rel="bookmark" class="crp_title">How to configure network card in Red Hat Enterprise Linux, CentOS, Fedora Core from CLI</a></li><li><a
href="http://www.php2s.com/networking/how-to-configure-passwords-to-secure-your-cisco-router-on-different-mode.html" rel="bookmark" class="crp_title">How to Configure Passwords to Secure your Cisco Router on Different Mode</a></li><li><a
href="http://www.php2s.com/linux/install-configure-squid-proxy-server-on-centos-or-enterprise-linux-5-and-implement-access-control-list-to-block-website.html" rel="bookmark" class="crp_title">Install &#038; Configure Squid Proxy Server on CentOS or Enterprise Linux 5 and Implement ACL</a></li><li><a
href="http://www.php2s.com/linux/step-by-step-install-and-configure-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">Step by Step Install and Configure Squid Proxy Server on CentOS 6.2 / RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/how-to-setup-a-fedora-red-hat-linux-or-centos-dhcp-client.html" rel="bookmark" class="crp_title">How to Setup a Fedora / Red Hat Linux or CentOS DHCP Client</a></li><li><a
href="http://www.php2s.com/linux/linux-encryptdecrypt-files-command-gpg-interactivenon-interactive-modes.html" rel="bookmark" class="crp_title">Linux Encrypt/Decrypt Files Command, GPG Interactive/Non Interactive Modes</a></li><li><a
href="http://www.php2s.com/linux/how-to-restrict-web-access-by-time-using-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">How to Restrict Web Access By Time Using Squid Proxy Server on CentOS 6.2/ RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-dhcp-server-on-centos-or-other-clone-of-linux.html" rel="bookmark" class="crp_title">How to Install and Configure DHCP Server on Centos or Other Clone of Linux</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="encrypt lan network traffic">encrypt lan network traffic</a> (2)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="encrypt lan traffic">encrypt lan traffic</a> (2)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="how to encrypt lan traffic">how to encrypt lan traffic</a> (2)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="centos 6 2 ipsec module">centos 6 2 ipsec module</a> (1)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="private wifi linux">private wifi linux</a> (1)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="linux encrypted network">linux encrypted network</a> (1)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="ipsec squid">ipsec squid</a> (1)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="how to encrypt all wifi traffic">how to encrypt all wifi traffic</a> (1)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="how to create wi-fi traffic?">how to create wi-fi traffic?</a> (1)</li><li><a
href="http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html" title="encrypt wifi signal">encrypt wifi signal</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/networking/how-to-encrypt-lan-and-wifi-traffic-on-small-private-network.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to Untar Tar.gz on Linux (Linux Untar Command)</title><link>http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html</link> <comments>http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html#comments</comments> <pubDate>Thu, 08 Mar 2012 10:41:49 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[How-To]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=852</guid> <description><![CDATA[How to untar tar.gz archives on Linux systems, there is no actual Linux untar command – you use the tar command with different options to extract tar.gz files. tar.gz files are commonly used on Linux operating systems for source packages and for grouping large amounts of small files, tar.gz is by far the most common [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/03/terminal-logo-small.png"><img
class="alignleft size-full wp-image-853" title="terminal-logo-small" src="http://www.php2s.com/wp-content/uploads/2012/03/terminal-logo-small.png" alt="terminal logo small How to Untar Tar.gz on Linux (Linux Untar Command)" width="128" height="128" /></a>How to untar tar.gz archives on Linux systems, there is no actual Linux untar command – you use the tar command with different options to extract tar.gz files.</p><p>tar.gz files are commonly used on Linux operating systems for source packages and for grouping large amounts of small files, tar.gz is by far the most common compressed archive software used on Linux, if you are from a Windows background you will be familiar with .zip this is a similar propitiatory equivalent.<span
id="more-852"></span></p><h2>How to untar tar.gz archive</h2><blockquote><p>tar -xvzf archive.tar.gz</p></blockquote><p>You should be left with your extracted files in a directory or in the directory where you extracted your tar.gz file.</p><p>I will explain the Linux untar options I used above:</p><p>x = Extract<br
/> v = Verbose (it shows you what files are extracted from the archive on the console)<br
/> z = Filter through gzip – allows us to extract gzip compression using the Linux tar command.<br
/> f = File, this tells the command we which to use a file</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/linux-locate-command-find-files-and-directories-quickly-and-efficiently-in-linux.html" rel="bookmark" class="crp_title">Linux locate command: Find Files and Directories Quickly and Efficiently in Linux</a></li><li><a
href="http://www.php2s.com/linux/linux-encryptdecrypt-files-command-gpg-interactivenon-interactive-modes.html" rel="bookmark" class="crp_title">Linux Encrypt/Decrypt Files Command, GPG Interactive/Non Interactive Modes</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-recordmydesktop-on-rhel-and-centos.html" rel="bookmark" class="crp_title">How to install RecordMyDesktop on RHEL and CentOS</a></li><li><a
href="http://www.php2s.com/linux/add-date-and-time-to-linux-terminal-title-gnome-terminal-xterm-urxvt-rxvt.html" rel="bookmark" class="crp_title">Add date and time to Linux terminal title (Gnome Terminal, xterm, urxvt, rxvt)</a></li><li><a
href="http://www.php2s.com/programming/php-programming/how-to-run-mutiple-localhosts-using-wamp-windows-apache-mysql-php.html" rel="bookmark" class="crp_title">How to Run Mutiple Localhosts Using WAMP (Windows Apache MySQL PHP)</a></li><li><a
href="http://www.php2s.com/linux/howto-guide-get-the-size-of-a-directory-via-terminal-on-ubuntu.html" rel="bookmark" class="crp_title">Howto Guide: Get the Size of a Directory via Terminal on Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/moving-and-renaming-directories-and-files-in-centoslinux.html" rel="bookmark" class="crp_title">Moving and Renaming Directories and Files in CentOS/Linux</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-a-software-application-from-a-terminal-on-ubuntu.html" rel="bookmark" class="crp_title">How to Install a Software Application from a Terminal on Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/vi-commands-cheat-sheet-vi-short-commands-reference-linux.html" rel="bookmark" class="crp_title">Vi Commands Cheat sheet &#8211; Vi short commands reference linux</a></li><li><a
href="http://www.php2s.com/linux/how-to-change-ownership-with-the-chown-command-on-ubuntu-11-10-oneiric-ocelot.html" rel="bookmark" class="crp_title">How to Change Ownership With The chown Command On Ubuntu 11.10 Oneiric Ocelot</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="linux untar">linux untar</a> (17)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="Untar Tar gz">Untar Tar gz</a> (8)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="untar command linux">untar command linux</a> (7)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="linux untar command">linux untar command</a> (7)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="how to untar on linux">how to untar on linux</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="how to untar in linux">how to untar in linux</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="linux command terminal unzip tar gz">linux command terminal unzip tar gz</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="untar command">untar command</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="how to untar tar gz">how to untar tar gz</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html" title="untar command in linux">untar command in linux</a> (3)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-untar-tar-gz-on-linux-linux-untar-command.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to Redirect all www traffice to non-www version in Nginx</title><link>http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html</link> <comments>http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html#comments</comments> <pubDate>Thu, 23 Feb 2012 06:20:40 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Nginx]]></category> <category><![CDATA[Open Source]]></category> <category><![CDATA[How-To]]></category> <category><![CDATA[nginx]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=845</guid> <description><![CDATA[Problem: How do I redirect an request at www. to the non-www version? This should include requests to the root domain as well as any (wildcard) subdomain. I also don’t want any unnecessary if statements, as per the nginx pitfalls document. Here’s what I have so far but it only seems to work for the [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/02/nginx.png"><img
class="alignleft  wp-image-846" title="nginx" src="http://www.php2s.com/wp-content/uploads/2012/02/nginx.png" alt="nginx How to Redirect all www traffice to non www version in Nginx" width="207" height="93" /></a><br
/> <strong><span
style="color: #ff0000;">Problem</span>:</strong><br
/> How do I redirect an request at www. to the non-www version?</p><p>This should include requests to the root domain as well as any (wildcard) subdomain.</p><p>I also don’t want any unnecessary if statements, as per the nginx pitfalls document.</p><p><span
id="more-845"></span></p><p>Here’s what I have so far but it only seems to work for the root domain, not subdoamins.</p><blockquote><p>server {<br
/> listen 80 default_server;<br
/> server_name www.*;<br
/> rewrite &#8220;^www\.(.*)&#8221; $scheme://$1 permanent;<br
/> }</p></blockquote><p><strong><span
style="color: #3366ff;">Solution</span>:</strong><br
/> My understanding of your question is the following:<br
/> Redirect all requests reaching any subdomain of an arbitrary root domain to the root domain – in a reasonably general manner. For example:</p><blockquote><p>www.example1.com -&gt; example1.com<br
/> abcd.example2.com -&gt; example2.com<br
/> *.exampleN.com -&gt; exampleN.com</p></blockquote><p>Let’s start with the easy case first – a known root domain, with any subdomain:</p><blockquote><p>server{<br
/> server_name *.example.com;<br
/> rewrite ^ $scheme://example.com permanent;<br
/> }server{<br
/> listen 80 default_server;<br
/> server_name example.com;<br
/> #your main config<br
/> }</p></blockquote><p>This is fairly well optimized – no if statements, no unnecessary captures in the rewrite – and wildcard server_names are hashed for performance. The first server block matches any subdomain and will issue a redirect to the second server block which only matches the root domain. (Note, although it is easy to match both conditions in one server block (server_name .example.com – no * needed) the two server blocks are needed to prevent a redirect loop).</p><p>The more generalized case requires some way of identifying the domain, since it is ‘unknown’. We therefore need to parse the server_name – and can do so with a regex capture.</p><blockquote><p>server{<br
/> server_name ~^(.+\.)(?.+\..+)$;<br
/> rewrite ^ $scheme://$domain permanent;<br
/> }server{<br
/> listen 80 default_server;<br
/> server_name _;<br
/> #your main config<br
/> }</p></blockquote><p>Here we have a (required) subdomain – (.+\.) means any character (.) repeated one or more times (+) followed by an actual ‘.’ (escaped with the backslash) – this capture will be assigned to $1 if we need it.</p><p>The next section is very similar – we are using Perl 5.1/PCRE7 notation for a ‘named capture’ – ?assigns the capture to $domain. Our domain can be anything (.) one or more characters in length (+), followed by an actual ‘.’ and then another set of any characters (the TLD). This regex will not work for TLDs which contain a ‘.’ – e.g. ‘co.uk’ – if you will be using those, it is probably best to specify the valid TLDs in your regex. For example:</p><blockquote><p>server_name ^(.+\.)(?.+\.(co\.uk|net|org|com))$</p></blockquote><p>We use the same rewrite as above, just replacing the static root domain with the captured domain.</p><p>Since a common case with the ‘unknown’ domain scenario will see you passing the same files to all the domains, you probably don’t need to capture the domain name in the default_server block (it is more efficient to avoid the regex when possible).</p><p>It is important to note that regex matches have the lowest priority – exact names, and wildcard entries take precendence over regexes. Additionally, unlike exact names and wildcard entries – regexes are not hashed. Finally, when using regexes with captures, even if only one server block is defined, the expression must be evaluated for every request to obtain the captures.</p><p>As a result of the above, if you do have to do something specific with a particular domain name, simply define a new server block for it and that will take precedence over the default_server block defined above.</p><p>If you know the domain names, even if they are numerous, you will get better performance if you can include the static name instead of using a regex. That said, there are some cases (e.g. allowing users to point their (unknown) domain at your IP as part of a service) where you may not know the domain and where the regex approach is necessary.</p><p>(Of course, this needs a matching wildcard DNS entry for the requests to ever reach the server.)</p><p><a
href="http://serverfault.com/questions/362425/nginx-redirect-all-www-traffice-to-non-www-version">Reference</a></p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-configure-virtualhost-by-different-domains-nginx.html" rel="bookmark" class="crp_title">How to configure VirtualHost by different domains (nginx)</a></li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-install-nginx-with-https-support-on-centos.html" rel="bookmark" class="crp_title">How to Install Nginx with HTTPS support on CentOS</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-dhcp-server-on-centos-or-other-clone-of-linux.html" rel="bookmark" class="crp_title">How to Install and Configure DHCP Server on Centos or Other Clone of Linux</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-the-phpbb-forum-on-debian-squeezesid-linux.html" rel="bookmark" class="crp_title">How to install the phpbb forum on Debian (Squeeze/Sid) Linux</a></li><li><a
href="http://www.php2s.com/linux/install-configure-squid-proxy-server-on-centos-or-enterprise-linux-5-and-implement-access-control-list-to-block-website.html" rel="bookmark" class="crp_title">Install &#038; Configure Squid Proxy Server on CentOS or Enterprise Linux 5 and Implement ACL</a></li><li><a
href="http://www.php2s.com/linux/how-to-installation-and-configuration-bind-dns-server-on-centos-5-3.html" rel="bookmark" class="crp_title">How to Installation and Configuration BIND DNS Server on CentOS 5.3</a></li><li><a
href="http://www.php2s.com/linux/run-php-file-without-create-any-file-via-wget-to-cronjob-of-linux.html" rel="bookmark" class="crp_title">Run PHP File Without Create Any File Via Wget to Cronjob of Linux</a></li><li><a
href="http://www.php2s.com/linux/virtualbox-auto-start-vm-centos-fedora-redhat.html" rel="bookmark" class="crp_title">(Q/A)VirtualBox Auto Start VM Centos Fedora RedHat</a></li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" rel="bookmark" class="crp_title">How to Set Static IP Address in Centos 6.2 Linux Server</a></li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" rel="bookmark" class="crp_title">How to check fiber connectivity in VMware ESXi 5.0</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="nginx rewrite www to non www">nginx rewrite www to non www</a> (2)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="centos 6 2 nginx rewrite">centos 6 2 nginx rewrite</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="nginx rewrite non-www">nginx rewrite non-www</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="nginx rewrite www to non-www">nginx rewrite www to non-www</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="nginx rewrite www to non-www domain">nginx rewrite www to non-www domain</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="nginx www to non www">nginx www to non www</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="non www not working nginx">non www not working nginx</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="redirect all non www to www">redirect all non www to www</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="redirect domain to www nginx">redirect domain to www nginx</a> (1)</li><li><a
href="http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html" title="redirect non www to www nginx without root access">redirect non www to www nginx without root access</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/open-source/nginx/how-to-redirect-all-www-traffice-to-non-www-version-in-nginx.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to improve battery life of Linux System / Laptop / PC</title><link>http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html</link> <comments>http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html#comments</comments> <pubDate>Mon, 06 Feb 2012 14:13:46 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Feature]]></category> <category><![CDATA[Linux]]></category> <category><![CDATA[How-To]]></category> <category><![CDATA[Laptop]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=831</guid> <description><![CDATA[In this tutorial i will show you how to improve battery life of linux system or laptop. For Linux users who enjoy a fragmentation-free and virus-immune laptop, there’s barely anything that makes them whine as much as their Redmond-loving counterparts. Linux, on a fully compatible machine, achieves a perfect blend of performance and stability. That [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/02/linux-system.jpg"><img
class="alignleft  wp-image-832" title="linux-system" src="http://www.php2s.com/wp-content/uploads/2012/02/linux-system-300x219.jpg" alt="linux system 300x219 How to improve battery life of Linux System / Laptop / PC" width="210" height="153" /></a>In this tutorial i will show you how to improve battery life of linux system or laptop. For Linux users who enjoy a fragmentation-free and virus-immune laptop, there’s barely anything that makes them whine as much as their Redmond-loving counterparts. Linux, on a fully compatible machine, achieves a perfect blend of performance and stability. That said, there are some of us who want more than perfection, they want optimum performance and a beast-like computing speed. I know, overclocking is a bit risky, but tweaking isn&#8217;t. We&#8217;ve heard them whining about their empty batteries and their always-plugged workdays, and yeah, as always, we couldn&#8217;t help doling out some useful advice to those folks.</p><p><span
id="more-831"></span></p><h2><span
style="color: #3366ff;"><strong>Dim the Lights</strong></span></h2><p>In most of the devices, including cellphones, the display is the biggest culprit when it comes to reduced battery life. A brightly lit laptop won’t really help you get through a whole workday. The best solution to this problem is to dim the screen as much as possible. If, in certain cases like movie-watching or reading you need a bright display, you can turn the brightness up for that period and them dim the screen back when you’re finished.</p><h2><span
style="color: #3366ff;"><strong>Kill the Slowpokes</strong></span></h2><p>It’s not just the display that hurts the battery, it’s also those CPU-hogging programs that make you reach out for the charger sooner than expected. That said, it’s not always easy for a user to spot that the CPU is under a load. It takes a real slowdown or freezing to realize that the program has become a mess and needs to be killed.</p><p>Don’t worry yet, as you can always keep an eye on your CPU or RAM by using any of the following methods:</p><p><strong>1.</strong> Take a look at the system monitor if you feel the slightest of difference in performance. From there, you can kill any misbehaving task.</p><p><strong>2.</strong> Ubuntu users can install the System Load Indicator from a ppa, which, once installed, will let you take a look at the performance right from the indicator menu. To install, go to the terminal (Ctrl+Alt+T) and paste/type in the following commands.</p><blockquote><p>sudo add-apt-repository ppa:indicator-multiload/stable-daily</p><p>sudo apt-get update &amp;&amp; sudo apt-get install indicator-multiload</p></blockquote><h2><span
style="color: #3366ff;"><strong>Power Management</strong></span></h2><p>The computer’s power management scheme is one of the most important factors that decide the fate of your battery. In the power management settings window, always make sure you choose a balanced plan that helps you get through a whole workday without looking for an adapter. Another great way to take advantage of this setting is by making sure that the laptop goes into suspend mode as soon as the lid is closed. Though, it might not be a suitable setting for folks who are a tad impatient, it still is one of the most effective ways of saving battery life. To access the power management settings in Ubuntu, open the Dash (Super/Windows key) and type in the word “Power” without quotes.</p><h2><span
style="color: #3366ff;"><strong>Hibernate over Suspend</strong></span></h2><p>If, instead of shutting down your laptop, you put it on suspend mode, always make sure you’re connected to a charger. If not, then put the computer in hibernate mode and go for a nice nap. That way, neither would you lose any precious battery life nor would you lose your current work.</p><h2><span
style="color: #3366ff;"><strong>Keep It Cool</strong></span></h2><p>Most of the battery loss also occurs due to overheating laptops. The overheating issue is something that affects a lot of laptops. To remedy that problem, simply use a laptop cooling pad, a simple accessory that saves your computer from overheating. It’s also a good idea to keep an eye on the temperature; to do that, simply install the system monitor indicator that comes with various temperature sensors.</p><blockquote><p>sudo add-apt-repository ppa:alexeftimie/ppa</p><p>sudo apt-get update &amp;&amp; sudo apt-get install indicator-sysmonitor</p></blockquote><p>Or, if all you want is a simple hardware sensor, then try out the following indicator applet:</p><blockquote><p>sudo add-apt-repository ppa:alexmurray/indicator-sensors</p><p>sudo apt-get install indicator-sensors</p></blockquote><h2><span
style="color: #3366ff;"><strong>Update Update Update</strong></span></h2><p>Finally, always remember to update your computer. The Linux kernel is continuously improving, and so are the distributions. In Ubuntu 12.04 for example, users will get to see an improved support for battery life. So, make sure you don’t ignore your computer when it badgers you to give it a big update.</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-enable-root-login-in-ubuntu-11-10.html" rel="bookmark" class="crp_title">How to Enable Root Login in Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-configure-vsftpd-on-rhel-centos-ubuntu-fedora-debian.html" rel="bookmark" class="crp_title">How to Install &#038; Configure Vsftpd on RHEL/CentOS/Ubuntu/Fedora</a></li><li><a
href="http://www.php2s.com/open-source/installing-and-tweaking-homebrew-on-mac-os-x.html" rel="bookmark" class="crp_title">Installing and Tweaking Homebrew on Mac OS X</a></li><li><a
href="http://www.php2s.com/linux/how-to-update-lib-modules-after-copying-disk-to-a-different-system.html" rel="bookmark" class="crp_title">How to update /lib/modules after copying disk to a different system?</a></li><li><a
href="http://www.php2s.com/linux/how-to-upgrade-to-ubuntu-12-04-for-desktops-servers-running-10-04-or-11-10.html" rel="bookmark" class="crp_title">How To Upgrade to Ubuntu 12.04 for Desktops &#038; Servers running 10.04 or 11.10</a></li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" rel="bookmark" class="crp_title">Installing Webmin on Ubuntu 12.04 Server using APT</a></li><li><a
href="http://www.php2s.com/linux/linux-kernel-3-2-released-and-available-for-download.html" rel="bookmark" class="crp_title">Linux Kernel 3.2 released and available for download</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-a-software-application-from-a-terminal-on-ubuntu.html" rel="bookmark" class="crp_title">How to Install a Software Application from a Terminal on Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-turn-on-telnet-service-on-rhel-febora-centos-ubuntu-freebsd-debian.html" rel="bookmark" class="crp_title">how to install &#038; turn on telnet service on RHEL, Fedora, CentOS, Ubuntu, FreeBSD, Debian</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-ntp-daemon-on-centos-rhel-fedora.html" rel="bookmark" class="crp_title">Install and Configure NTP on CentOS/ RHEL/ Fedora</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="centos battery life">centos battery life</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="LINUX SYSTEM">LINUX SYSTEM</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="how to improve battery life on linux">how to improve battery life on linux</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="improve battery life centos">improve battery life centos</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="linux improve battery life">linux improve battery life</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="improving battery life linux">improving battery life linux</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="how to increase battery life in linux">how to increase battery life in linux</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="battery life improve linux">battery life improve linux</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="improve linux battery life">improve linux battery life</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html" title="centos improve battery life">centos improve battery life</a> (2)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-improve-battery-life-of-linux-system-laptop-pc.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to load custom Kernel (tun) module in CentOS/ RHEL Linux</title><link>http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html</link> <comments>http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html#comments</comments> <pubDate>Mon, 06 Feb 2012 07:25:42 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Centos]]></category> <category><![CDATA[Debian]]></category> <category><![CDATA[How-To]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=825</guid> <description><![CDATA[Just recently it was necessery to load up a tun kernel module on few CentOS Linux servers. I’m using Debian on daily basis, and everybody that had even little of experience with Debian should already be aware about the existence of the handy: /etc/modules file. On Debian to enable a certain kernel module to load [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/02/centos-logo11.jpg"><img
class="alignleft  wp-image-826" title="centos-logo1" src="http://www.php2s.com/wp-content/uploads/2012/02/centos-logo11-300x80.jpg" alt="centos logo11 300x80 How to load custom Kernel (tun) module in CentOS/ RHEL Linux" width="240" height="64" /></a>Just recently it was necessery to load up a <strong>tun</strong> kernel module on few <strong>CentOS</strong> Linux servers.</p><p>I’m using Debian on daily basis, and everybody that had even little of experience with Debian should already be aware about the existence of the handy:<br
/> <strong> /etc/modules </strong> file.<br
/> On Debian to enable a certain kernel module to load up on Linux boot, all necessery is to just place the kernel module name in <em>/etc/modules</em>.</p><p><span
id="more-825"></span><br
/> For example loading the <strong>tun</strong> tunneling kernel module I issue the command:</p><blockquote><p><code>debian:~# echo tun &gt;&gt; /etc/modules<br
/> </code></p></blockquote><p>I wondered if CentOS, also supports<span
style="color: #3366ff;"> <strong> /etc/modules</strong></span> as it was necessery now to add this <em>tun</em> module to load up on CentOS’s boot.<br
/> After a bit of research I’ve figured out CentOS does not have support for adding modules names in <strong> /etc/modules </strong>, anyhow after consulting <strong> CentOS </strong> documentation on <em> <a
href="http://www.centos.org/docs/5/html/Deployment_Guide-en-US/s1-kernel-modules-persistant.html">http://www.centos.org</a> </em>, I found <span
style="color: #3366ff;"><strong>CentOS and RHEL use /etc/rc.modules instead of Debian’s /etc/modules </strong></span> to load up any custom kernel modules not loaded by default during system boot.</p><p>Therefore instructing the RHEL Linux to load up my desired <strong>tun</strong> module in kernel on next boot was as easy as executing:</p><blockquote><p><code>[root@centos ~]# echo 'modprobe tun' &gt;&gt; /etc/rc.modules<br
/> [root@centos ~]# chmod +x /etc/rc.modules<br
/> </code></p></blockquote><p>Now on next boot CentOS will load up the <strong>tun</strong> module in kernel. Achiving the same module load up is also possible through <strong> /etc/rc.local </strong>, but it’s not recommended way as <strong>/etc/rc.local</strong> would load up the kernel module after all of the rest init boot scripts complete and therefore will load up the module slightly later, at the final boot stage.</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" rel="bookmark" class="crp_title">How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</a></li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" rel="bookmark" class="crp_title">How to auto restart CentOS Linux server with software watchdog (softdog) to reduce server downtime</a></li><li><a
href="http://www.php2s.com/linux/how-to-update-lib-modules-after-copying-disk-to-a-different-system.html" rel="bookmark" class="crp_title">How to update /lib/modules after copying disk to a different system?</a></li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" rel="bookmark" class="crp_title">How to disable Ipv6 on GNU / CentOS, Fedora, Debian, Redhat</a></li><li><a
href="http://www.php2s.com/linux/how-to-make-a-usb-boot-cd-for-ubuntu-11-10.html" rel="bookmark" class="crp_title">How to make a USB Boot CD for Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-a-perl-module-in-linux-without-root-permission.html" rel="bookmark" class="crp_title">How to Install A Perl Module In Linux Without Root Permission</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-memcached-on-centos-6-2-rhel-5-7-fedora-16.html" rel="bookmark" class="crp_title">How to Install Memcached on CentOS 6.2, RHEL 5.7, Fedora 16</a></li><li><a
href="http://www.php2s.com/networking/how-to-create-an-ip-ip-tunnel-among-three-networks.html" rel="bookmark" class="crp_title">How to create an ip-ip tunnel among three Networks</a></li><li><a
href="http://www.php2s.com/linux/how-to-modify-iptables-during-kickstart-install-of-centos-6.html" rel="bookmark" class="crp_title">How to modify iptables during Kickstart Install of CentOS 6</a></li><li><a
href="http://www.php2s.com/linux/how-to-setup-usergroup-quotas-4tib-on-ubuntu.html" rel="bookmark" class="crp_title">How to Setup user/group quotas >4TiB on Ubuntu</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="rhel 6 2 rc modules">rhel 6 2 rc modules</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="installing tun module ubuntu 11 10">installing tun module ubuntu 11 10</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="load modules at boot centos 6 0">load modules at boot centos 6 0</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="custom kernel centos 6 2">custom kernel centos 6 2</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="install tun module centos 6">install tun module centos 6</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="centos /etc/modules">centos /etc/modules</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="automatic rdp on centos6 2">automatic rdp on centos6 2</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="ubuntu 11 10 tun module">ubuntu 11 10 tun module</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="load kernel modules centos">load kernel modules centos</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" title="rhel 6 2 tun support">rhel 6 2 tun support</a> (2)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to auto restart CentOS Linux server with software watchdog (softdog) to reduce server downtime</title><link>http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html</link> <comments>http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html#comments</comments> <pubDate>Sun, 05 Feb 2012 07:38:32 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Open Source]]></category> <category><![CDATA[Centos]]></category> <category><![CDATA[Linux]]></category> <category><![CDATA[Softdog]]></category> <category><![CDATA[Watchdog]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=816</guid> <description><![CDATA[If you are in charge of dozen of Linux servers these days and therefore required to restart many of the servers with a support ticket (because many of the Data Centers where the servers are co-located does not have a web interface or IPKVM connected to the server for that purpose). Therefore the server restart [...]]]></description> <content:encoded><![CDATA[<p>If you are in charge of dozen of Linux servers these days and therefore required to restart many of the servers with a support ticket (because many of the Data Centers where the servers are co-located does not have a web interface or IPKVM connected to the server for that purpose). Therefore the server restart requests in case of crash sometimes gets processed in few hours or in best case in at least half an hour.</p><p>I’m aware of the existence of Hardware Watchdog devices, which are capable to detect if a server is hanged and auto-restart it, however the servers I administrate does not have Hardware support for Watchdog timer.</p><p><span
id="more-816"></span></p><p>Thankfully there is a free software project called Watchdog which is easily configured and mitigates the terrible downtimes caused every now and then by a server crash and respective delays by tech support in Data Centers.</p><p>I’ve recently blogged on the topic of<a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html"> Debian Linux auto-restart in case of kernel panic</a> , however now i had to configure watchdog on some dozen of CentOS Linux servers.</p><p>It appeared installation &amp; configuration of Watchdog on CentOS is a piece of cake and comes to simply following few easy steps, which I’ll explain quickly in this post:</p><p><strong>1. Install with yum watchdog to CentOS</strong></p><blockquote><p>[root@centos:/etc/init.d ]# yum install watchdog<br
/> &#8230;</p></blockquote><p><strong>2. Add to configuration a log file to log watchdog activities and location of the watchdog device</strong></p><p>The quickest way to add this two is to use echo to append it in /etc/watchdog.conf:</p><blockquote><p>[root@centos:/etc/init.d ]# echo &#8216;file = /var/log/messages&#8217; &gt;&gt; /etc/watchdog.conf<br
/> echo &#8216;watchdog-device = /dev/watchdog&#8217; &gt;&gt; /etc/watchdog.conf</p></blockquote><p><strong>3. Load the softdog kernel module to initialize the software watchdog via /dev/watchdog</strong></p><blockquote><p>[root@centos:/etc/init.d ]# /sbin/modprobe softdog</p></blockquote><p>Initialization of softdog should be indicated by a line in dmesg kernel log like the one above:</p><blockquote><p>[root@centos:/etc/init.d ]# dmesg |grep -i watchdog<br
/> Software Watchdog Timer: 0.07 initialized. soft_noboot=0 soft_margin=60 sec (nowayout= 0)</p></blockquote><p><strong>4. Include the softdog kernel module to load on CentOS boot up</strong></p><p>This is necessary, because otherwise after reboot the softdog would not be auto initialized and without it being initialized, the watchdog daemon service could not function as it does automatically auto reboots the server if the /dev/watchdog disappears.</p><p>It’s better that the softdog module is not loaded via /etc/rc.local but the default CentOS methodology to load module from /etc/rc.module is used:</p><blockquote><p>[root@centos:/etc/init.d ]# echo modprobe softdog &gt;&gt; /etc/rc.modules<br
/> [root@centos:/etc/init.d ]# chmod +x /etc/rc.modules</p></blockquote><p><strong>5. Start the watchdog daemon service</strong></p><p>The successful initialization of Softdog in step 4, should have provided the system with /dev/watchdog, before proceeding with starting up the watchdog daemon it’s wise to first check if /dev/watchdog is existent on the system. Here is how:</p><blockquote><p>[root@centos:/etc/init.d ]# ls -al /dev/watchdogcrw&#8212;&#8212;- 1 root root 10, 130 Aug 10 14:03 /dev/watchdog</p></blockquote><p>Being sure, that /dev/watchdog is there, I’ll start the watchdog service.</p><blockquote><p>[root@centos:/etc/init.d ]# service watchdog restart<br
/> &#8230;</p></blockquote><p>Very important note to make here is that you should never ever configure watchdog service to run on boot time with chkconfig. In other words the status from chkconfig for watchdog boot on all levels should be off like so:</p><blockquote><p>[root@centos:/etc/init.d ]# chkconfig &#8211;list |grep -i watchdog<br
/> watchdog 0:off 1:off 2:off 3:off 4:off 5:off 6:off</p></blockquote><p>Enabling the watchdog from the chkconfig will cause watchdog to automatically restart the system as it will probably start the watchdog daemon before the softdog module is initialized. As watchdog will be unable to read the /dev/watchdog it will though the system has hanged even though the system might be in a boot process. Therefore it will end up in an endless loops of reboots which can only be fixed in a linux single user mode!!! Once again BEWARE, never ever activate watchdog via chkconfig!</p><p>Next step to be absolutely sure that watchdog device is running it can be checked with normal ps command:</p><blockquote><p>[root@centos:/etc/init.d ]# ps aux|grep -i watchdog<br
/> root@hosting1-fr [~]# ps axu|grep -i watch|grep -v greproot 18692 0.0 0.0 1816 1812 ? SNLs 14:03 0:00 /usr/sbin/watchdog<br
/> root 25225 0.0 0.0 0 0 ? ZN 17:25 0:00 [watchdog]</p></blockquote><p>You have probably noticed the defunct state of watchdog, consider that as absolutely normal, above output indicates that now watchdog is properly running on the host and waiting to auto reboot in case of sudden /dev/watchdog disappearance.</p><p>As a last step before, after being sure its initialized properly, it’s necessery to add watchdog to run on boot time via /etc/rc.local post init script, like so:</p><blockquote><p>[root@centos:/etc/init.d ]# echo &#8216;echo /sbin/service watchdog start&#8217; &gt;&gt; /etc/rc.local</p></blockquote><p>Now enjoy, watchdog is up and running and will automatically restart the CentOS host.</p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" rel="bookmark" class="crp_title">How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</a></li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" rel="bookmark" class="crp_title">How to load custom Kernel (tun) module in CentOS/ RHEL Linux</a></li><li><a
href="http://www.php2s.com/linux/installing-monit-and-restart-apache-automatically-on-centos.html" rel="bookmark" class="crp_title">Installing Monit and Restart Apache Automatically on CentOS</a></li><li><a
href="http://www.php2s.com/linux/how-to-set-static-ip-address-in-centos-6-2-linux-server.html" rel="bookmark" class="crp_title">How to Set Static IP Address in Centos 6.2 Linux Server</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-configure-vsftpd-on-rhel-centos-ubuntu-fedora-debian.html" rel="bookmark" class="crp_title">How to Install &#038; Configure Vsftpd on RHEL/CentOS/Ubuntu/Fedora</a></li><li><a
href="http://www.php2s.com/linux/howto-guide-enable-autostart-httpd-daemon-on-centos-6-2.html" rel="bookmark" class="crp_title">Howto Guide: Enable Autostart httpd Daemon on CentOS 6.2</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-memcached-on-centos-6-2-rhel-5-7-fedora-16.html" rel="bookmark" class="crp_title">How to Install Memcached on CentOS 6.2, RHEL 5.7, Fedora 16</a></li><li><a
href="http://www.php2s.com/linux/virtualbox-auto-start-vm-centos-fedora-redhat.html" rel="bookmark" class="crp_title">(Q/A)VirtualBox Auto Start VM Centos Fedora RedHat</a></li><li><a
href="http://www.php2s.com/linux/howto-install-webmin-1-570-1-on-centos-6-2-using-rpm.html" rel="bookmark" class="crp_title">Howto Guide: Install Webmin 1.570-1 on CentOS 6.2 using RPM</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-ntp-daemon-on-centos-rhel-fedora.html" rel="bookmark" class="crp_title">Install and Configure NTP on CentOS/ RHEL/ Fedora</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="restart centos">restart centos</a> (47)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="centos 6 install perl module">centos 6 install perl module</a> (4)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="watchdog centos">watchdog centos</a> (4)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="how to install centos 6 2 squid">how to install centos 6 2 squid</a> (4)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="howto install centos6 2">howto install centos6 2</a> (3)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="centos 6 setup ntp server">centos 6 setup ntp server</a> (3)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="centos watchdog howto">centos watchdog howto</a> (2)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="linux softdog">linux softdog</a> (2)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="yum watchdog">yum watchdog</a> (2)</li><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" title="fedora autostart softdog watchdog">fedora autostart softdog watchdog</a> (2)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to check fiber connectivity in VMware ESXi 5.0</title><link>http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html</link> <comments>http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html#comments</comments> <pubDate>Sun, 05 Feb 2012 07:20:12 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Virtualization]]></category> <category><![CDATA[ESXi]]></category> <category><![CDATA[VMware]]></category> <category><![CDATA[vSphere]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=813</guid> <description><![CDATA[Problem: On a VMware ESXi 5.0 host, how can I check if fiber storage adapters are properly connected to the fiber switch/SAN, i.e. if the fiber link is up? Solution: This information is shown nowhere in the vSphere Client, and there is no command-line tool to check it, either. The only way to verify if [...]]]></description> <content:encoded><![CDATA[<p><strong><span
style="color: #ff0000;">Problem</span>:</strong></p><p>On a VMware ESXi 5.0 host, how can I check if fiber storage adapters are properly connected to the fiber switch/SAN, i.e. if the fiber link is up?</p><p><strong><span
style="color: #3366ff;">Solution</span>:</strong></p><p>This information is shown nowhere in the vSphere Client, and there is no command-line tool to check it, either.</p><p>The only way to verify if a fiber link is up is to access the ESXi shell and go to /<span
style="color: #3366ff;">proc</span>/scsi/your_hba_driver (in my case, /<span
style="color: #3366ff;">proc</span>/scsi/qla2xxx); there is a (virtual) file there for each fiber port, and the contents of these files include one of the following:</p><p><span
id="more-813"></span></p><p><strong>For an active link:</strong></p><blockquote><p>Host adapter:Loop State = &lt;READY&gt;, flags = 0xaa68<br
/> Link speed = &lt;8 Gbps&gt;</p></blockquote><p><strong>For an inactive link:</strong></p><blockquote><p>Host adapter:Loop State = &lt;DEAD&gt;, flags = 0x1a268<br
/> Link speed = &lt;Unknown&gt;</p></blockquote><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-creat-tun-tap-devices-on-ubuntu-linux.html" rel="bookmark" class="crp_title">How to Create tun/tap devices on Ubuntu/ Linux</a></li><li><a
href="http://www.php2s.com/virtualization/esxi-4-backup-and-restore-configuration.html" rel="bookmark" class="crp_title">Esxi 4 Backup and Restore configuration</a></li><li><a
href="http://www.php2s.com/linux/install-fresh-centos-ilo-install-no-internet-connectivity-yum-wget-etc-fail.html" rel="bookmark" class="crp_title">Install fresh CentOS iLO install, no internet connectivity (yum, wget etc. fail)</a></li><li><a
href="http://www.php2s.com/linux/find-real-path-of-linux-symbolic-link-or-soft-link-files-%e2%80%93-linux-command-line.html" rel="bookmark" class="crp_title">Find Real Path of Linux Symbolic Link or Soft Link Files – Linux Command Line</a></li><li><a
href="http://www.php2s.com/programming/php-programming/draw-pie-chart.html" rel="bookmark" class="crp_title">How to Draw pie chart in PHP</a></li><li><a
href="http://www.php2s.com/linux/how-to-modify-iptables-during-kickstart-install-of-centos-6.html" rel="bookmark" class="crp_title">How to modify iptables during Kickstart Install of CentOS 6</a></li><li><a
href="http://www.php2s.com/linux/installing-monit-and-restart-apache-automatically-on-centos.html" rel="bookmark" class="crp_title">Installing Monit and Restart Apache Automatically on CentOS</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-ntp-daemon-on-centos-rhel-fedora.html" rel="bookmark" class="crp_title">Install and Configure NTP on CentOS/ RHEL/ Fedora</a></li><li><a
href="http://www.php2s.com/open-source/installing-and-tweaking-homebrew-on-mac-os-x.html" rel="bookmark" class="crp_title">Installing and Tweaking Homebrew on Mac OS X</a></li><li><a
href="http://www.php2s.com/programming/php-programming/cookie-based-login-form-and-get-last-login-time.html" rel="bookmark" class="crp_title">PHP Code: Cookie based login form and get last login time</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="host adapter:loop state = &lt;dead&gt;">host adapter:loop state = &lt;dead&gt;</a> (3)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="esxi5 watchdog">esxi5 watchdog</a> (2)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="how to check connectivity of fiber">how to check connectivity of fiber</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="Linux commands esxi5 0">Linux commands esxi5 0</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="linux fibre link">linux fibre link</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="restart fibre link linux">restart fibre link linux</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="up Fibre on esxi">up Fibre on esxi</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="vmware esxi 5 server linux">vmware esxi 5 server linux</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="vmware esxi server 5 0 linux commands">vmware esxi server 5 0 linux commands</a> (1)</li><li><a
href="http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html" title="vmware esxi5 dead paths">vmware esxi5 dead paths</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/virtualization/how-to-check-fiber-connectivity-in-vmware-esxi-5-0.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</title><link>http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html</link> <comments>http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html#comments</comments> <pubDate>Sun, 05 Feb 2012 07:02:56 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Debian]]></category> <category><![CDATA[How-To]]></category> <category><![CDATA[kernel]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=807</guid> <description><![CDATA[In this tutorial i will show you how to automatically reboot Debian Squeeze Linux on Kernel panic to avoid CPU overload or system crash. If you are a system administrator, you have probably wondered at least once how to configure your Linux server to automatically reboot itself if it crashes, is going through a mass [...]]]></description> <content:encoded><![CDATA[<p>In this tutorial i will show you how to automatically reboot Debian Squeeze Linux on Kernel panic to avoid CPU overload or system crash.</p><p>If you are a system administrator, you have probably wondered at least once how to configure your Linux server to automatically reboot itself if it crashes, is going through a mass CPU overload, e.g. the server <strong> load average </strong> &#8220;hits the sky&#8221;.</p><p>I just learned from a <a
href="http://blogs.techrepublic.com.com/opensource/?p=158"> nice article found here</a> that there is a kernel variable which when enabled takes care to automatically restart a crashed server with the terrible <strong> Kernel Panic </strong>message we all know.</p><p>The variable I&#8217;m taking about is <strong> kernel.panic </strong> for instance <strong> kernel.panic = 20 </strong> would instruct your GNU Linux kernel to automatically reboot if it experiences a kernel panic system crash within a time limit of 20 seconds.</p><p><span
id="more-807"></span></p><p>To start using the auto-reboot linux capabilities on a kernel panic occurance just set the variable to <strong> /etc/sysctl.conf </strong></p><blockquote><p><code>debian-server:~# echo 'kernel.panic = 20' &gt;&gt; /etc/sysctl.conf</code></p></blockquote><p>Now we will also have to enable the variable to start being use on the system, so execute:</p><blockquote><p><code>debian-server:~# sysctl -p</code></p></blockquote><p>There you go automatic system reboots on kernel panics is now on.<br
/> Now to further assure yourself the linux server you&#8217;re responsible of will automatically restart itself on a emergency situation like a system overload I suggest you check <a
href="http://sourceforge.net/projects/watchdog/"> Watchdog </a></p><p>You might consider checking out <a
href="http://forums.theplanet.com/lofiversion/index.php/t40908.html"> this auto reboot tutorial </a> which explains in simple words how watchdog is installed and configured.<br
/> On Debian installing and maintaining watchdog is really simple and comes to <strong>installing and enabling the watchdog system service, right afteryou made two changes in it&#8217;s configuration file </strong> <strong>/etc/watchdog.conf </strong></p><p>To do so execute:</p><blockquote><p><code>debian-server:~# apt-get install watchdog<br
/> debian-server:~# echo "file = /var/log/messages" &gt;&gt; /etc/watchdog.conf<br
/> debian-server:~# echo "watchdog-device = /dev/watchdog" &gt;&gt; /etc/watchdog.conf<br
/> </code></p></blockquote><p>Well that should be it, you might also need to load some kernel module to monitor your watchdog.<br
/> On my system the kernel modules related to watchdog are located in:</p><p><strong>/lib/modules/2.6.26-2-amd64/kernel/drivers/watchdog/</strong><br
/> If not then you should certainly try the <strong> software watchdog </strong> linux kernel module called <strong> softdog </strong>, to do so issue:<br
/> <code> </code></p><blockquote><p><code>debian-server:~# /sbin/modprobe softdog<br
/> </code></p></blockquote><p>It&#8217;s best if you load the module while the softdog daemon is disabled.<br
/> If you consider auto loadig the softdog software watchdog kernel driver you should exec:</p><blockquote><p><code> debian-server:~# echo 'softdog' &gt;&gt; /etc/modules<br
/> </code></p></blockquote><p>Finally a start of the watchdog is necessery:<code><br
/> </code></p><blockquote><p><code>debian-server:~# /etc/init.d/watchdog start<br
/> Stopping watchdog keepalive daemon....<br
/> Starting watchdog daemon....<br
/> </code></p></blockquote><p>That should be all your automatic system reboots should be now on!</p><p><span
style="text-decoration: underline;"><span
style="color: #888888;"><em><a
href="http://www.pc-freak.net/blog/how-to-automatically-reboot-restart-debian-gnu-lenny-linux-on-kernel-panic-some-general-cpu-overload-or-system-crash-2/"><span
style="color: #888888; text-decoration: underline;">Reference</span></a></em></span></span></p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/open-source/how-to-auto-restart-centos-linux-server-with-software-watchdog-softdog-to-reduce-server-downtime.html" rel="bookmark" class="crp_title">How to auto restart CentOS Linux server with software watchdog (softdog) to reduce server downtime</a></li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" rel="bookmark" class="crp_title">How to load custom Kernel (tun) module in CentOS/ RHEL Linux</a></li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" rel="bookmark" class="crp_title">How to disable Ipv6 on GNU / CentOS, Fedora, Debian, Redhat</a></li><li><a
href="http://www.php2s.com/linux/how-to-update-lib-modules-after-copying-disk-to-a-different-system.html" rel="bookmark" class="crp_title">How to update /lib/modules after copying disk to a different system?</a></li><li><a
href="http://www.php2s.com/linux/p-linux-pipes-%e2%80%93-event-triggers-action.html" rel="bookmark" class="crp_title">(P/S) Linux Pipes – Event triggers action</a></li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" rel="bookmark" class="crp_title">How to clear Squid Proxy Cache on Debian and Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/install-fresh-centos-ilo-install-no-internet-connectivity-yum-wget-etc-fail.html" rel="bookmark" class="crp_title">Install fresh CentOS iLO install, no internet connectivity (yum, wget etc. fail)</a></li><li><a
href="http://www.php2s.com/linux/installing-monit-and-restart-apache-automatically-on-centos.html" rel="bookmark" class="crp_title">Installing Monit and Restart Apache Automatically on CentOS</a></li><li><a
href="http://www.php2s.com/linux/how-to-make-a-usb-boot-cd-for-ubuntu-11-10.html" rel="bookmark" class="crp_title">How to make a USB Boot CD for Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-apache-httpd-on-centos-6-2.html" rel="bookmark" class="crp_title">Howto Guide: Install &#038; Start Apache or Httpd Service on CentOS 6.2</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="debian kernel panic auto reboot">debian kernel panic auto reboot</a> (10)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="debian kernel crash">debian kernel crash</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="ubuntu watchdog howto">ubuntu watchdog howto</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="jak restartovat linux debian">jak restartovat linux debian</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="kernel watchdog reboot script">kernel watchdog reboot script</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="panic=1 debian">panic=1 debian</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="reboot debian server">reboot debian server</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="debian kernel panic howto">debian kernel panic howto</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="ubuntu setup auto reboot">ubuntu setup auto reboot</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" title="watch dog implementation in linux">watch dog implementation in linux</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>PHP Tutorial: A Quick Way to Break up a URL into usable Pieces</title><link>http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html</link> <comments>http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html#comments</comments> <pubDate>Thu, 02 Feb 2012 16:01:05 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[PHP]]></category> <category><![CDATA[Programming]]></category> <category><![CDATA[php]]></category> <category><![CDATA[php code]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=800</guid> <description><![CDATA[PHP has a built in function which allows for the quick breaking up of a well formed URL into usable pieces, namely parse_url. This function parses a URL and returns an associative array containing any of the various components of the URL that are present. It is important to note that parse_url does not validate [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/02/php-logo.jpg"><img
class="alignleft  wp-image-801" title="php-logo" src="http://www.php2s.com/wp-content/uploads/2012/02/php-logo-300x207.jpg" alt="php logo 300x207 PHP Tutorial: A Quick Way to Break up a URL into usable Pieces" width="210" height="145" /></a>PHP has a built in function which allows for the quick breaking up of a well formed URL into usable pieces, namely parse_url.</p><p>This function parses a URL and returns an associative array containing any of the various components of the URL that are present. It is important to note that parse_url does not validate the given URL, it simply breaks it up into parts. Partial URLs are also accepted, and whilst parse_url tries its best to parse them correctly, it may return -1 if the URL provided is too malformed.</p><p><span
id="more-800"></span></p><p>So what exactly does it break an URL up into then?</p><p>Well, given an URL like below, parse_url would return the following:</p><blockquote><p>$url = &#8216;http://username:password@hostname/path?arg=value#anchor&#8217;;</p><p>print_r(parse_url($url));</p><p>echo parse_url($url, PHP_URL_PATH);</p></blockquote><p>&nbsp;</p><p>The output:</p><blockquote><p>Array<br
/> (<br
/> [scheme] =&gt; http<br
/> [host] =&gt; hostname<br
/> [user] =&gt; username<br
/> [pass] =&gt; password<br
/> [path] =&gt; /path<br
/> [query] =&gt; arg=value<br
/> [fragment] =&gt; anchor<br
/> )</p><p>/path</p></blockquote><p>So pretty useful if you want say just the host or query value from a given URL then!</p><p>Another thing to note is that it is not designed to work with relative URLs, meaning that you do need to provide it with fully qualified URLs in order to get something usable back.</p><p>Still, a pretty nifty little function to keep in mind when writing parsing scripts…</p><p><span
style="text-decoration: underline;"><em><span
style="color: #888888; text-decoration: underline;"><a
href="http://www.codeunit.co.za/2012/01/27/php-a-quick-way-to-break-up-a-url-into-usable-pieces/"><span
style="color: #888888; text-decoration: underline;">Reference</span></a></span></em></span></p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/howto-install-webmin-1-570-1-on-centos-6-2-using-rpm.html" rel="bookmark" class="crp_title">Howto Guide: Install Webmin 1.570-1 on CentOS 6.2 using RPM</a></li><li><a
href="http://www.php2s.com/programming/php-programming/cookie-based-login-form-and-get-last-login-time.html" rel="bookmark" class="crp_title">PHP Code: Cookie based login form and get last login time</a></li><li><a
href="http://www.php2s.com/linux/how-to-split-files-on-linux-freebsd-netbsd-and-openbsd.html" rel="bookmark" class="crp_title">How to Split files on Linux FreeBSD, NetBSD and OpenBSD</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-a-perl-module-in-linux-without-root-permission.html" rel="bookmark" class="crp_title">How to Install A Perl Module In Linux Without Root Permission</a></li><li><a
href="http://www.php2s.com/open-source/installing-and-tweaking-homebrew-on-mac-os-x.html" rel="bookmark" class="crp_title">Installing and Tweaking Homebrew on Mac OS X</a></li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" rel="bookmark" class="crp_title">How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</a></li><li><a
href="http://www.php2s.com/programming/php-programming/php-memory-usage-information-class.html" rel="bookmark" class="crp_title">PHP Memory Usage Information Class</a></li><li><a
href="http://www.php2s.com/programming/web-programming/fixing-apache-13permission-denied-access-to-403-forbidden.html" rel="bookmark" class="crp_title">Fixing Apache (13)Permission denied: access to / 403 Forbidden</a></li><li><a
href="http://www.php2s.com/programming/php-programming/a-dynamic-bar-chart.html" rel="bookmark" class="crp_title">A Dynamic Bar Chart in PHP</a></li><li><a
href="http://www.php2s.com/linux/installing-webmin-on-ubuntu-12-04-server-using-apt.html" rel="bookmark" class="crp_title">Installing Webmin on Ubuntu 12.04 Server using APT</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="PHP LOGO">PHP LOGO</a> (176)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="logo php">logo php</a> (31)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="www php2s com">www php2s com</a> (7)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="logo of php">logo of php</a> (6)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="php tutorial">php tutorial</a> (5)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="php[">php[</a> (3)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="PHP powered">PHP powered</a> (2)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="php tutorials">php tutorials</a> (2)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="splitting up a url php">splitting up a url php</a> (1)</li><li><a
href="http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html" title="url contains ?arg=">url contains ?arg=</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/programming/php-programming/php-tutorial-a-quick-way-to-break-up-a-url-into-usable-pieces.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to disable Ipv6 on GNU / CentOS, Fedora, Debian, Redhat</title><link>http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html</link> <comments>http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html#comments</comments> <pubDate>Thu, 02 Feb 2012 15:37:55 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Networking]]></category> <category><![CDATA[Servers]]></category> <category><![CDATA[Administration]]></category> <category><![CDATA[ipv6]]></category> <category><![CDATA[Server]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=795</guid> <description><![CDATA[In this tutorial you will learn how to disable IPv6 on Debian and other linux distributions (RHEL, CentOS, Fedora, Ubuntu). I have few servers, which have automatically enabled IPv6 protocols (IPv6 gets automatically enabled on Debian), as well as on most latest Linux distribituions nowdays. Disabling IPv6 network protocol on Linux if not used has [...]]]></description> <content:encoded><![CDATA[<p>In this tutorial you will learn how to disable IPv6 on Debian and other linux distributions (RHEL, CentOS, Fedora, Ubuntu).</p><p>I have few servers, which have automatically enabled IPv6 protocols (IPv6 gets automatically enabled on Debian), as well as on most latest Linux distribituions nowdays.</p><p><span
id="more-795"></span></p><p><strong>Disabling IPv6 network protocol on Linux </strong> if not used has 2 reasons:</p><ol><li>Security (It&#8217;s well known security practice to disable anything not used on a server)<br
/> Besides that IPv6 has been known for few criticil security vulnerabilities, which has historically affected the Linux kernel.</li><li>Performance (Sometimes disabling IPv6 could have positive impact on IPv4 especially on heavy traffic network servers).<br
/> I&#8217;ve red people claiming <em>disabling IPv6</em> improves the DNS performance, however since this is not rumors and did not check it personally I cannot positively confirm this.</li></ol><p>Disabling IPv6 on all GNU / Linuces can be achieved by changing the kernel sysctl settings <span
style="color: #800080;"><strong> net.ipv6.conf.all.disable_ipv6</strong></span> by default <em>net.ipv6.conf.all.disable_ipv6</em> equals 1 which means IPv6 is enabled, hence to <span
style="color: #800080;"><strong>disable IPv6</strong></span> I issued:</p><blockquote><p><code>server:~# sysctl net.ipv6.conf.all.disable_ipv6=0<br
/> </code></p></blockquote><p>To set it permanently on system boot I put the setting also in<span
style="color: #800000;"> <em> /etc/sysctl.conf </em></span>:</p><blockquote><p><code>server:~# echo 'net.ipv6.conf.all.disable = 1 &gt;&gt; /etc/sysctl.conf</code></p></blockquote><p>The aforedescribed methods should be working on most <em>Linux kernels version &gt; 2.6.27 </em>in that number it should work 100% on recent versions of <em><span
style="color: #3366ff;">Fedora, CentOS, Debian and Ubuntu</span>.</em><code><br
/> </code><br
/> <strong>To disable<span
style="color: #800080;"> IPv6 protocol on Debian</span> Lenny </strong>its necessery to blackist the ipv6 module in <span
style="color: #800000;"><em>/etc/modprobe.d/blacklist </em></span>by issuing:</p><blockquote><p><code>echo 'blacklist ipv6' &gt;&gt; /etc/modprobe.d/blacklist </code></p></blockquote><p>On<span
style="color: #800080;"><strong> Fedora </strong>/ <strong>CentOS </strong></span>there is a another<strong> universal &#8220;<span
style="color: #800080;">Redhat</span>&#8221; way disable IPv6</strong>.</p><p>On them disabling IPv6 is done by editting<span
style="color: #800000;"> /etc/sysconfig/</span>network and adding:</p><blockquote><p><code>NETWORKING_IPV6=no<br
/> IPV6INIT=no </code></p></blockquote><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/networking/how-to-create-an-ip-ip-tunnel-among-three-networks.html" rel="bookmark" class="crp_title">How to create an ip-ip tunnel among three Networks</a></li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" rel="bookmark" class="crp_title">How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</a></li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" rel="bookmark" class="crp_title">How to load custom Kernel (tun) module in CentOS/ RHEL Linux</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-configure-vsftpd-on-rhel-centos-ubuntu-fedora-debian.html" rel="bookmark" class="crp_title">How to Install &#038; Configure Vsftpd on RHEL/CentOS/Ubuntu/Fedora</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-turn-on-telnet-service-on-rhel-febora-centos-ubuntu-freebsd-debian.html" rel="bookmark" class="crp_title">how to install &#038; turn on telnet service on RHEL, Fedora, CentOS, Ubuntu, FreeBSD, Debian</a></li><li><a
href="http://www.php2s.com/programming/php-programming/cookie-based-login-form-and-get-last-login-time.html" rel="bookmark" class="crp_title">PHP Code: Cookie based login form and get last login time</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-and-configure-ntp-daemon-on-centos-rhel-fedora.html" rel="bookmark" class="crp_title">Install and Configure NTP on CentOS/ RHEL/ Fedora</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-apache-httpd-on-centos-6-2.html" rel="bookmark" class="crp_title">Howto Guide: Install &#038; Start Apache or Httpd Service on CentOS 6.2</a></li><li><a
href="http://www.php2s.com/programming/php-programming/a-dynamic-bar-chart.html" rel="bookmark" class="crp_title">A Dynamic Bar Chart in PHP</a></li><li><a
href="http://www.php2s.com/programming/php-programming/draw-pie-chart.html" rel="bookmark" class="crp_title">How to Draw pie chart in PHP</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="centos 6 disable ipv6">centos 6 disable ipv6</a> (54)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="disable ipv6 centos 6 2">disable ipv6 centos 6 2</a> (42)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="centos 6 2 ipv6 disable">centos 6 2 ipv6 disable</a> (20)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="ubuntu 12 04 disable ipv6">ubuntu 12 04 disable ipv6</a> (16)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="rhel 6 2 disable ipv6">rhel 6 2 disable ipv6</a> (16)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="fedora 16 disable ipv6">fedora 16 disable ipv6</a> (14)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="disable ipv6 redhat 6 2">disable ipv6 redhat 6 2</a> (12)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="disable ipv6 centos 6">disable ipv6 centos 6</a> (11)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="disable ipv6 in centos 6 2">disable ipv6 in centos 6 2</a> (10)</li><li><a
href="http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html" title="disable ipv6 on centos 6 2">disable ipv6 on centos 6 2</a> (8)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-disable-ipv6-on-gnu-centos-fedora-debian-redhat.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>How to clear Squid Proxy Cache on Debian and Ubuntu</title><link>http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html</link> <comments>http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html#comments</comments> <pubDate>Thu, 02 Feb 2012 15:28:42 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[Debian]]></category> <category><![CDATA[Squid]]></category> <category><![CDATA[Squid Proxy]]></category> <category><![CDATA[Ubuntu]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=791</guid> <description><![CDATA[In this tutorial i will show how to clear squid proxy cache on Debian and Ubuntu Linux. It was necessery to clean up some squid cache for some proxy users on a Debian host. Until now I’ve used to run only custom build Squid server on Slackware Linux. Thus I was curious if Debian guys [...]]]></description> <content:encoded><![CDATA[<p>In this tutorial i will show how to clear squid proxy cache on Debian and Ubuntu Linux. It was necessery to clean up some squid cache for some proxy users on a Debian host. Until now I’ve used to run only custom build <strong>Squid</strong> server on Slackware Linux.</p><p>Thus I was curious if Debian guys were smart enough to implement a proxy cache cleaning option as an option to be passed on to squid’s init script.</p><p><span
id="more-791"></span></p><p>Honestly I was quite suprised squid clear cache option is not there;</p><blockquote><p><code>squid-cache:~# /etc/init.d/squid3<br
/> Usage: /etc/init.d/squid3 {start|stop|reload|force-reload|restart}<br
/> squid-cache:/#<br
/> </code></p></blockquote><p>As it was not embedded into init script I still hoped, there might be some Debian way to do the proxy cache clearing, so I spend some 10 minutes checking online as well as checked in <em>squid3</em>‘s manual just to find there is no specific command or Debian accepted way to clean squid’s cache.</p><p>Since I couldn’t find any Debian specific, way I did it the old fashioned way <img
src="http://www.pc-freak.net/blog/wp-includes/images/smilies/icon_wink.gif" alt="icon wink How to clear Squid Proxy Cache on Debian and Ubuntu"  title="How to clear Squid Proxy Cache on Debian and Ubuntu" /> (deleted directory/file structures in <strong> /var/spool/squid3/*</strong> and used squid’s <strong> -z </strong> option, to recreate the swap directories.</p><p>Here is how:</p><blockquote><p><code>squid-cache:~# /etc/init.d/squid3 stop;<br
/> squid-cache:~# rm -Rf /var/spool/squid3/*;<br
/> squid-cache:~# squid3 -z; /etc/init.d/squid3 start<br
/> </code></p></blockquote><p>Finally I was quite amazed to realize, there was not even a crontab script to periodically clear and re-create proxy cache.</p><p>My previous experience with maintaning an office Squid proxy cache has prooved, that periodic cache clean ups are very helpful, especially to resolve issues with cached unreslovable DNS entries in the server.<br
/> Clearing up squid cache every week or something, guarantees that failure to resolve certain hosts at certain times would not stay unresolvable like forever <img
src="http://www.pc-freak.net/blog/wp-includes/images/smilies/icon_wink.gif" alt="icon wink How to clear Squid Proxy Cache on Debian and Ubuntu"  title="How to clear Squid Proxy Cache on Debian and Ubuntu" /></p><p>In that manner of thougths, I decided to put the following crontab which will twice a month clear up proxy’s cache, to possibly solve some failed squid DNS issues.</p><blockquote><p><code>squid-cache:~# crontab -u root -l &gt; file;<br
/> echo '00 04 12,26 * * /etc/init.d/squid3 stop; rm -Rf /var/spool/squid3/*; squid3 -z; /etc/init.d/squid3 start &gt;/dev/null 2&gt;&amp;1'<br
/> &gt;&gt; file; crontab file<br
/> </code></p></blockquote><p>By the way, implementing the <strong>squid clear cache</strong> in <strong>Debian</strong> and <strong> Ubuntu </strong>‘s init scripts and putting a periodic proxy clear up cron, seems like a feature worthy to be proposed to the distro developers and hopefully be embbed in some of the upcoming distro releases <img
src="http://www.pc-freak.net/blog/wp-includes/images/smilies/icon_wink.gif" alt="icon wink How to clear Squid Proxy Cache on Debian and Ubuntu"  title="How to clear Squid Proxy Cache on Debian and Ubuntu" /></p><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" rel="bookmark" class="crp_title">How to generate new passowrd for SQUID Proxy Server user with digest user authentication</a></li><li><a
href="http://www.php2s.com/linux/how-to-restrict-web-access-by-time-using-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">How to Restrict Web Access By Time Using Squid Proxy Server on CentOS 6.2/ RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/step-by-step-install-and-configure-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">Step by Step Install and Configure Squid Proxy Server on CentOS 6.2 / RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/install-configure-squid-proxy-server-on-centos-or-enterprise-linux-5-and-implement-access-control-list-to-block-website.html" rel="bookmark" class="crp_title">Install &#038; Configure Squid Proxy Server on CentOS or Enterprise Linux 5 and Implement ACL</a></li><li><a
href="http://www.php2s.com/linux/new-64-bit-linux-system-has-regular-processes-ps-grep-etc-taking-up-way-too-much-virt-mem.html" rel="bookmark" class="crp_title">New 64 bit linux system has regular processes (ps, grep etc) taking up way too much VIRT mem</a></li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" rel="bookmark" class="crp_title">How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</a></li><li><a
href="http://www.php2s.com/programming/web-programming/ruby-reload-script-or-console-without-restarting-%e2%80%93-ruby-on-rails.html" rel="bookmark" class="crp_title">Ruby Reload Script or Console Without Restarting – Ruby on Rails</a></li><li><a
href="http://www.php2s.com/linux/installing-lamp-linux-apache-mysql-php-on-ubuntu-11-10.html" rel="bookmark" class="crp_title">Installing LAMP (Linux, Apache Mysql PHP) on Ubuntu 11.10</a></li><li><a
href="http://www.php2s.com/linux/how-to-load-custom-kernel-tun-module-in-centos-rhel-linux.html" rel="bookmark" class="crp_title">How to load custom Kernel (tun) module in CentOS/ RHEL Linux</a></li><li><a
href="http://www.php2s.com/linux/virtualbox-auto-start-vm-centos-fedora-redhat.html" rel="bookmark" class="crp_title">(Q/A)VirtualBox Auto Start VM Centos Fedora RedHat</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="squid clear cache">squid clear cache</a> (13)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="clear cache squid ubuntu">clear cache squid ubuntu</a> (6)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="clear squid cache">clear squid cache</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="clear squid cache ubuntu">clear squid cache ubuntu</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="how to clear squid cache in ubuntu">how to clear squid cache in ubuntu</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="flush squid cache debian">flush squid cache debian</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="hapus cache proxy ubuntu">hapus cache proxy ubuntu</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="how to clear cache squid in ubuntu">how to clear cache squid in ubuntu</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="squid proxy clear cache">squid proxy clear cache</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" title="squid cache clear script">squid cache clear script</a> (3)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html/feed</wfw:commentRss> <slash:comments>1</slash:comments> </item> <item><title>How to generate new passowrd for SQUID Proxy Server user with digest user authentication</title><link>http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html</link> <comments>http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html#comments</comments> <pubDate>Thu, 02 Feb 2012 07:04:16 +0000</pubDate> <dc:creator>Frank Boros</dc:creator> <category><![CDATA[Linux]]></category> <category><![CDATA[How-To]]></category> <category><![CDATA[Squid]]></category> <category><![CDATA[Squid Proxy]]></category><guid
isPermaLink="false">http://www.php2s.com/?p=782</guid> <description><![CDATA[This tutorial will show you how to  generate new password for proxy user configured on SQUID proxy server configured with digest user authentication. I found the squid password generate script, which generates the one line string which needs to go to the squid user password file: #!/bin/sh user="$1"; realm="$2"; pass="$3"; if [ -z "$1" -o [...]]]></description> <content:encoded><![CDATA[<p><a
href="http://www.php2s.com/wp-content/uploads/2012/02/squid_proxy_server.jpg"><img
class="alignleft  wp-image-777" title="squid_proxy_server" src="http://www.php2s.com/wp-content/uploads/2012/02/squid_proxy_server-300x269.jpg" alt="squid proxy server 300x269 How to generate new passowrd for SQUID Proxy Server user with digest user authentication" width="88" height="79" /></a>This tutorial will show you how to  generate new password for proxy user configured on SQUID proxy server configured with digest user authentication.<br
/> I found the squid password generate script, which generates the one line string which needs to go to the squid user password file:</p><p><span
id="more-782"></span></p><blockquote><p><code>#!/bin/sh<br
/> user="$1";<br
/> realm="$2";<br
/> pass="$3";<br
/> if [ -z "$1" -o -z "$2" -o -z "$3" ] ; then<br
/> echo "Usage: $0 user password 'realm'";<br
/> exit 1<br
/> fi<br
/> ha1=$(echo -n "$user:$realm:$pass"|md5sum |cut -f1 -d' ')<br
/> echo "$user:$realm:$ha1"</code></p></blockquote><p>You can alternatively <a
href="http://www.php2s.com/wp-content/uploads/2012/02/squid_generate_pass.zip"> download the squid_generate_pass.sh script here </a></p><p>The script accepts three arguments;<br
/> <code></code></p><blockquote><p><code>proxy-server:~# ./squid_generate_pass.sh<br
/> <strong> Usage: ./squid_generate_pass.sh user password 'realm' </strong></code></p></blockquote><p>Thus to generate a new user and password and insert it immediately into let’s say a squid configured user/pass file in <strong> /etc/squid3/users </strong> execute command:</p><blockquote><p><code>proxy-server:~# ./squid_generate_pass.sh admin_user MySecretPassword 'Squid_Configured_Realm'<br
/> &gt;&gt; /etc/squid3/users</code></p></blockquote><p>Where <strong> Squid_Configured_Realm </strong> depends on the realm name configured in <strong>squid.conf</strong>, for example if <em> squid.conf </em> includes some auth configuration similar to:</p><blockquote><p><code>auth_param digest program /usr/lib/squid3/digest_pw_auth -c /etc/squid3/users<br
/> auth_param digest children 2<br
/> auth_param digest realm My_Proxy_Realm<br
/> acl localusers proxy_auth REQUIRED</code></p></blockquote><p>The realm script argument should be <strong> My_Proxy_realm </strong>. If <em> squid_generate_pass </em> does completes without errors, it should add a line to <em> /etc/squid3/users </em> file similar to:</p><blockquote><p><code>proxy-server:~# cat /etc/squid3/users<br
/> admin_user:My_Proxy_realm:3bbcb35e505c52a0024ef2e3ab1910b0</code></p></blockquote><div
id="crp_related"><h2>You might be interested in this:</h2><ul><li><a
href="http://www.php2s.com/linux/how-to-clear-squid-proxy-cache-on-debian-and-ubuntu.html" rel="bookmark" class="crp_title">How to clear Squid Proxy Cache on Debian and Ubuntu</a></li><li><a
href="http://www.php2s.com/linux/how-to-restrict-web-access-by-time-using-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">How to Restrict Web Access By Time Using Squid Proxy Server on CentOS 6.2/ RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/step-by-step-install-and-configure-squid-proxy-server-on-centos-6-2-rhel-6.html" rel="bookmark" class="crp_title">Step by Step Install and Configure Squid Proxy Server on CentOS 6.2 / RHEL 6</a></li><li><a
href="http://www.php2s.com/linux/p-linux-pipes-%e2%80%93-event-triggers-action.html" rel="bookmark" class="crp_title">(P/S) Linux Pipes – Event triggers action</a></li><li><a
href="http://www.php2s.com/programming/web-programming/ruby-reload-script-or-console-without-restarting-%e2%80%93-ruby-on-rails.html" rel="bookmark" class="crp_title">Ruby Reload Script or Console Without Restarting – Ruby on Rails</a></li><li><a
href="http://www.php2s.com/linux/install-configure-squid-proxy-server-on-centos-or-enterprise-linux-5-and-implement-access-control-list-to-block-website.html" rel="bookmark" class="crp_title">Install &#038; Configure Squid Proxy Server on CentOS or Enterprise Linux 5 and Implement ACL</a></li><li><a
href="http://www.php2s.com/networking/how-to-configure-passwords-to-secure-your-cisco-router-on-different-mode.html" rel="bookmark" class="crp_title">How to Configure Passwords to Secure your Cisco Router on Different Mode</a></li><li><a
href="http://www.php2s.com/database/how-to-secure-mysql-database-server.html" rel="bookmark" class="crp_title">How to Secure MySQL Database Server to Prevent Anonymous Access</a></li><li><a
href="http://www.php2s.com/linux/how-to-automatically-reboot-restart-debian-gnu-lenny-squeeze-linux-on-kernel-panic.html" rel="bookmark" class="crp_title">How to automatically reboot (restart) Debian GNU Lenny / Squeeze Linux on Kernel Panic</a></li><li><a
href="http://www.php2s.com/linux/how-to-install-apache-httpd-on-centos-6-2.html" rel="bookmark" class="crp_title">Howto Guide: Install &#038; Start Apache or Httpd Service on CentOS 6.2</a></li></ul></div><h4>Incoming search terms:</h4><ul><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="configure squid proxy server ubuntu with user athentication">configure squid proxy server ubuntu with user athentication</a> (5)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="centos proxy server authentication">centos proxy server authentication</a> (4)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="step by step squid proxy server configuration mysql authentication in centos">step by step squid proxy server configuration mysql authentication in centos</a> (3)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="how to generate password for squid proxy">how to generate password for squid proxy</a> (2)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="squid proxy server centos 6 user authentication">squid proxy server centos 6 user authentication</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="squid proxy server authentication">squid proxy server authentication</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="squid proxy centos user and password">squid proxy centos user and password</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="squid proxy authentication rhel 6">squid proxy authentication rhel 6</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="squid proxy authentication php 5 3">squid proxy authentication php 5 3</a> (1)</li><li><a
href="http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html" title="user authentication php in squid3">user authentication php in squid3</a> (1)</li></ul>]]></content:encoded> <wfw:commentRss>http://www.php2s.com/linux/how-to-generate-new-passowrd-for-squid-proxy-server-user-with-digest-user-authentication.html/feed</wfw:commentRss> <slash:comments>0</slash:comments> </item> </channel> </rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Database Caching 58/190 queries in 0.212 seconds using disk: basic
Object Caching 8865/9158 objects using disk: basic

Served from: www.php2s.com @ 2012-05-19 04:38:38 -->
