Server Benchmark with PHP 5 : ThePlanet, Hosteurope, Hetzner

This is a small benchmark test / performance comparison with PHP 5 between ThePlanet, Hosteurope and Hetzner Servers. Servers are not same, and there are RAM difference but in this test RAM plays no big role, but CPU plays. The server from Hosteurope is a virtual server with min. 2GB ram guarantie. The other two are dedicated root servers. ThePlanet's OS is Redhat enterprise, The other two are using Debian.

Hetzner : Intel® Core™ i7-920 Quad-Core with 8GB Ram
Hosteurope: 8 Cores Intel® Xeon® with min 2GB or more
ThePlanet: 2x DualCore Intel(R) Xeon(TM) CPU 3.40GHz with 2GB

[warn] [client] mod_fcgid: HTTP request length 137744 (so far) exceeds MaxRequestLen (131072), referer

As I want to add a forum entry I got Apache's 500 server internel error. i tried to change .htaccess, php-conf etec but no success.

Error was: [warn] [client] mod_fcgid: HTTP request length 137744 (so far) exceeds MaxRequestLen (131072), referer:

After a research check error-logs of virtual host I found that /etc/apache2/mods-available/fcgid.conf must be changed.

I added following directive:

MaxRequestLen 157286400

Failed to modify server : AWstats reporting is already enabled for this domain

I have a problem: I have a website which is older than 10 years. I was using a cpanel-whm server till 4 years ago. Than I changed to a Debian Lamp server with webmin. And upgraded the server last month. I had migrated cpanel-backups to webmin and after upgrade migrated webmin-backups to new webmin on new server. Awstats is not checked and not to see under logs tab. But when I try to check and activate Awstats under "edit virtual server" tab, I get this error: Failed to modify server : AWstats reporting is already enabled for this domain.

How can I pass this error? Thanks

mkfs takes very long time, how2 make it faster?

It is already 6 hours that I have started the command: mkfs -t ext3 -c -q /dev/sda1

It is a ATA SAMSUNG (sata 750 GB). How long does it take?

It is running under Debian 6 box i7 920 CPU with 8GB ram.

Failed to save mount : Mount failed :

I have tried to mount my second sata disk and got following error:

Failed to save mount : Mount failed :

mount: wrong fs type, bad option, bad superblock on /dev/sda1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

Any idea why and how2 fix it?

E: Sub-process /usr/bin/dpkg returned an error code (1)

I have a debian 64 bit lenny4 server and wanted to updatebind 9. Update is failed while I was trying with this commands:

 apt-get -y install bind9
 apt-get -y -f install bind9

I get this error at the end of shell window:
E: Sub-process /usr/bin/dpkg returned an error code (1)

This is the full output:

apt-get -y -f install bind9
Reading package lists... Done
Building dependency tree
Reading state information... Done
bind9 is already the newest version.
bind9 set to manually installed.

How to find your operating system information & version on Linux

You can find your Kernel version with uname -a but it wont say if your operating system is Centos, Redhat, Ubuntu 9 or Debian 5. To display os-details we can read the content from /proc/version.

cat /proc/version
Linux version 2.6.26-2-amd64 (Debian 2.6.26-19lenny1) ( (gcc version 4.1.3 20080704 (prerelease) (Debian 4.1.2-25)) #1 SMP Mon Oct 19 02:34:17 UTC 2009

Downloading websites in limited dept levels and output to one directory without folder hierarchy with WGET

I want to download the first two level pages of a couple of websites to one local directry. I use this code with ssh (using putty):

wget -r -l2 --no-directories

Replace string in big database or large text file

You have a cms and a big database with over 100 tables and 100.000 entries. And you need to replace all entries contain "" with "". How you do that? Editing all entries manually with phpmyadmin? It could takes weeks to complete. I have found a solution and want to share with you.


1. Export your whole database in a text file : db.sql
2. Replace string using Linux sed command
3. Empty your db and import new sql file

Export your mysql database into a text file: db.sql

mysqldump -u root -p your_database_name > db.sql

Argument List too Long

If you try to remove a directory with ie 500.000 files, you will get an error like this: Argument list is too long, cannot delete.

rm -Rfv ./some-dirs-with-unwanted-files

Instead of rm use find and rm.

find ./ -exec rm -vf {} \;
Syndicate content is a free online community for webdevelopers and beginners. Anybody can share their code, articles, tips, tutorials, code-examples or other webdesign related material on the site. Newbies can submit their questions and reply to existing questions. CW does not guarantee or warrant reliability of code, data and information published on the site. Use the site on your own risk. The site takes no responsibility of direct or indirect loss or any kind of harm to its users. The site also doesn't take responsibility of infected files or source code with any kind of infection or viruses, worms, spywares, malwares, trojan horses. CW reserves the right to edit, move, or delete any of content for any reason.