Install Mod Rewrite Cpanel Tutorial
Install Mod Rewrite Cpanel Tutorial' title='Install Mod Rewrite Cpanel Tutorial' />My recommended domain registrar and web host, plus how to connect the two up so that your site is up quickly. DSO modphp vs. CGI vs. PHP vs. Fast. CGIThis is one of the most common topics that I see customers will ask about. As highly important as PHP handlers are, they often the least understood. They seem complicated, but its not too hard to understand. You dont have to know that exact science of how it all works, but one should learn the basics if you want to take your website seriously. Picking the right PHP handler for your website will give you the optimal speeds you want and maybe allow you to save some money by using a cheaper hosting package. So I invite you to take a few minutes and learn something new. What are PHP handlers. In order to run a PHP site, the server must interpret the PHP code and generate a page when visitors access the website. It interprets the code based on which PHP library you are using, such as PHP 4 or PHP 5. A PHP handler is what actually loads the libraries so that they can be used for interpretation. PHP handlers determine how PHP is loaded on the server. Install Mod Rewrite Cpanel Tutorial' title='Install Mod Rewrite Cpanel Tutorial' />There are multiple different handlers that can be used for loading PHP CGI, DSO, su. PHP, Fast. CGI. Each handler delivers the libraries through different files and implementations. Each file and implementation affects Apaches performance, because it determines how Apache serves PHP. It is critical for your servers performance that you select the handler that fits your situation. High Heat-Major League Baseball-2004. Install Mod Rewrite Cpanel Tutorial' title='Install Mod Rewrite Cpanel Tutorial' />Selecting the right handler is just as important as the PHP version itself. One handler is not necessarily always better than another it depends on your unique setup. I-restart-litespeed-on-cpanel.jpg' alt='Install Mod Rewrite Cpanel Tutorial' title='Install Mod Rewrite Cpanel Tutorial' />What caching do you need, what modules do you need, etc Note You may assign different PHP handlers to different versions of PHP. For example, version 5 may be handled by CGI while PHP 4 is handled by DSO. How to change the handler. Changing the handler on c. Install Mod Rewrite Cpanel Tutorial' title='Install Mod Rewrite Cpanel Tutorial' />Panel is very easy to do and only takes seconds. Log into WHM and navigate to Main Service Configuration Configure PHP and Su. Exec. You simply select your PHP handler choice from the drop down menu. Learn how to log into your WordPress Dashboard. CPanel use by default suPHP, that means the webserver have the same permission of the ownership owner. The problem is that the mails are store with also the sames. Then hit Save New Configuration. Note If you do not see your desired choice in the drop down menu, it may need to be compiled on the server first. Run an Easy Apache to compile it. List of PHP handlers. DSO modphpDSO is also known as modphp. DSO stands for Dynamic Shared Object. This is an older configuration but is generally considered the fastest handler. It runs PHP as an Apache module. This means that PHP scripts will run as the Apache user, which is the user nobody. DSO has two drawbacks. First, all files created by a PHP script will have the ownership of nobody. They will not be readable from the web. Websites that need to upload files through PHP will run into file permission issues. This is common with Word. Press users that upload files through the Word. Press interface or utilize the auto update feature. These will fail with DSO. The second drawback is a security issue. Created files will have the nobody ownership. If a hacker finds an exploit in your PHP script, they could implement a file that has the same privileges as important system files that are also owned by nobody. This will give them the ability to modify files outside of that users account. This is really bad for anyone who does reselling or simply is hosting other persons sites. You would not one user to be able to affect another user. However, if there is only one account on the server or if all the accounts are yours, then DSO may be right for you. The speeds benefits of DSO are unquestionable. An easy way to prevent the hack issue is to always keep your sites software up to date. Check with your PHP scripts developer to keep up on the new releases. If you are the only one being hosted on the server, this is easy to do as its part of your webmaster duties already. However, if youre reselling, it would be unreasonable to expect all your users to keep their software up to date. They simply may not be as diligent as you. DSOs low CPU usage typically amounts in higher speeds and load times over most other handlers. It is also the default setting on most servers. CGICGI stands for Common Gateway Interface. The CGI handler will run PHP as a CGI module as opposed to an Apache module. CGI still runs PHP processes as the Apache nobody user. However, if you have su. EXEC enabled, it will allow you to see the user that made the request. The CGI method is intended as a fallback handler for when DSO is not available. According to c. Panels own documentation, this method is neither fast nor secure, regardless of whether or not su. EXEC is enabled. http docs. All. DocumentationWHMDocsMore. Phphandlerssu. PHPsu. PHP stands for Single user PHP. PHP also runs PHP as a CGI module instead of an Apache module. It differs from CGI in that PHP scripts that are called from the web will run under the user that owns them, as opposed to nobody. PHP is typically the default handler and is recommended by c. Panel for serving PHP because you will be able to see which user owns the account that is running the PHP script. PHP is beneficial in that if you are using a file upload tool on your site such as an automatic updater or themeplug in installer for Word. Press, the files will already have the right ownership permissions. Toyota Mark X Manual here. Uploading and other Word. Press functions will not work without su. PHP or Fast. CGI. PHP also offers a security advantage that any php script that is not owned by the particular user such as another account or root will not be executable. Also, files that have permissions set to world writeable will likewise be non executable. This means that if one account is compromised, the malicious scripts will not be able to infect other accounts. The drawback is that su. PHP generally runs a much higher CPU load. In addition, you CANNOT use an Opcode Cache such as Xcache or APC with su. PHP. It is strongly recommend that you install a caching plug in to supplement this ned. If you find that your server is still continually struggling with CPU usage, you will want to consider switching to DSO or Fast. CGI. If you DO switch to either su. PHP or Fast. CGI, you will need to update the file permissions and ownership. See my other article for automatic fixperms on c. Panel servers http boomshadow. Fast. CGIFast. CGI aka modfcgid or FCGI is a high performance variation of CGI. It has the securityownership benefits of su. PHP in that PHP scripts will run as the actual c. Panel user as opposed to nobody. The difference with Fast. CGI is that it can drastically save on CPU performance and give speeds close to that of DSO. It can also be used with an opcode cacher like e. Accelerator or APC, which can help further speed the loading of pages. The drawback is Fast. CGI has a high memory usage. This is because rather than creating the PHP process each time it is called, like su. PHP, it keeps a persistent session open in the background. This is what lets it work with an opcode caching software. If you like the securityownership benefits of su. PHP and you can afford a major increase in memory usage meaning you already have a low average memory usage, you may wish to consider using Fast. CGI. Comparison Graph DSO CGI Su. PHP Fast. CGILow CPU usageLow Memory consumptionRuns PHP as site owner instead of Apache only w su. EXECGood securitySpecial Note for Word. Press Users. If you are using Word.