Misconfiguration of mod_security will cause your website to not properly function and return fatal errors. This problem can only be solved by disabling mod_security and filtering rules.

Create .htaccess in your website's root directory (var/www). Or you could just add the following lines if you already have an existing .htaccess.

SecFilterEngine Off
SecFilterScanPOST Off

This will disable ModSecurity (mod_security) module running in your site or server.

To uninstall ModSecurity (mod_security), comment out or delete the related mod_security entries from httpd.conf file. This is located in /etc/httpd/conf/ directory. The lines that should be removed include:

AddModule mod_security.c
LoadModule security_module modules/mod_security.so
Include “/usr/local/apache/conf/modsec.conf” (or maybe similar to this line)

Save the file (httpd.conf) and restart Apache (/etc/init.d/httpd restart)


ModSecurity will no longer be loaded by the system.

I am running Plesk for Linux and I've noticed that emails are sent very very slow. As a result, emails are delayed..

I was able to research a fix to at least speed up the sending of emails in Plesk.

Login thru SSH and go to /etc/xinetd.d and edit the smtp_psa file.

The file should look like this:
------------------------------------------------------------------------------------------------------

service smtp
{
socket_type = stream
protocol = tcp
wait = no
disable = no
user = root
instances = UNLIMITED
server = /var/qmail/bin/tcp-env
server_args = /usr/sbin/rblsmtpd -r bl.spamcop.net -r cbl.abuseat.org -r sbl-xt.spamhaus.org /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true
------------------------------------------------------------------------------------------------------

you are going to do is, add "-Rt0" (minus the quotes" ") to "server_args" so it will look like:

server_args = -Rt0 /usr/sbin/rblsmtpd -r bl.spamcop.net -r cbl.abuseat.org -r sbl-xt.spamhaus.org /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true


Save the file, and restart xinetd:

/etc/init.d/xinetd restart

This should help speed up the sending of emails in Plesk.

Im using Wordpress 2.2.1. All of sudden I'm unable to post new items. It just shows a blank white page. Strange. I have seen similar problems on different forums while I was browsing. Good thing I stumbled to this topic. It's about a recent wordpress website exploit.

Quoting:



The hacker exploited several WordPress vulnerabilities in administrative scripts to gain full access to the website (as permitted to apache user), including the ability to upload & run scripts, delete any file owned by apache user, view the file and directories etc.


The author mentioned about a file that was planted in the /tmp directory. The file name according to him was ro8kbsmawge.txt. I immediately checked the server and bummer! The hacker was able to put this in the /tmp directory -->ro8kfbsmag.txt. :(

I removed the file and as expected, I was able to post and publish new topics again.

So for all the guys out there facing the similar problem, I urge you to check your mahines as they may be compromised. If you're on a shared hosting, fire a support request to your hosts so that they can also be alerted. I also urge you to read the link I gave you because it helped me a lot in solving my problem.

Lesson learned. Restrict the /wp-admin folder to your network or ip address only. I'll continue reading Angsuman's post so that I can also pinpoint where the hacker came from and block his ip address from accessing the server again.

100% CPU usage on VPS


Although my VPS is up, it continues to run very slowly. I checked on the resources being used by the VPS thru VZPP,https://ip_address:4643/ and I found out that under Resources, the CPU usage was at 100% and in red zone. The System Usage and Disk Usage are healthy, though.

When I checked on the System processess, the number of processess running is at 357. Suspecting that there may be a system limit that exceeded in the QoS settings, I went to VZMC (Virtuozzo Management Console) and under the Primary Memory related parameters, I noticed that the avnumproc is set to 40.

avnumproc is the average number of processes that will be run inside VPS.

The solution here is to increase the value set in the avnumproc (I've set mine to Unlimited).
Also, set a higher value on your numproc. This also has something to do as to how many processes the system can use.

IP04 Four Port IP-PBX

This looks promising ---> IP04 Four Port IP-PBX

From the wiki, the IP04 is a 4 port IP-PBX that runs Asterisk and uClinux on a powerful embedded Blackfin processor. It's complete IP-PBX with 4 analog ports. No PC required!

The article is worth reading. Maybe I'll be able to play with this one too soon.





Looking for the Centos 5.0 Livecd root password? I've spent hours looking for this one. But here you go:


12qwaszx


Ciao!

How to turn on PHP error messages

Turning on PHP error messages is very useful in determining when a PHP page fails.

You can set the php handling in the php.ini. Set the following lines to ON:

error_reporting
display_errors

If you only want to check a particular page, just add this line on top of your script:

ERROR_REPORTING(E_ALL);

You may also want to try out some informations from this page.

While I was checking the site stats of this blog, I've noticed that some people are looking for ways on how to turn off PHP safe mode in Cpanel. On my previous post, I have mentioned that it can be done on a server-wide setting. But what if you want to disable safe mode on particular domains only on Cpanel?

This can be done by adding a simple line below the httpd.conf entry of that domain.

php_admin_flag safe_mode On

Output:

ServerAdmin webmaster@yourdomain.com
DocumentRoot /home/youruser/public_html
BytesLog domlogs/yourdomain.com-bytes_log
User youruser
Group youruser
ServerName http://www.yourdomain.com/
ServerAlias yourdomain.com http://www.yourdomain.com/
CustomLog domlogs/yourdomain.com combined
ScriptAlias /cgi-bin/ /home/youruser/public_html/cgi-bin/
php_admin_flag safe_mode On

On shared hosting accounts, just ask a request from your hosting provider. Most of the hosts are enabling safe mode in PHP for security purposes.

Goodluck!

Edit:

From Dave:

The proper way to do this on cPanel 11 is to edit the configuration file using WHM ( Web Host Manager).

1. Login to WHM.
2. Go into the Service Configuration menu and locate the PHP Configuration Editor.
3. From there you can set the various PHP settings such as disabling SAFE MODE.

For custom modifications of Apache and PHP, please refer to this link:
http://www.cpanel.net/support/docs/ea/ea3/

Bunch of thanks Dave!




moscontent::store failed ... or something similar.


After we have migrated the contents of a Mambo website to a different server, we were unable to create new contents in the administration panel. We are using Plesk 8.1 for Windows.The above error shows.

Quick fix: If you have encountered this error be sure to disable "strict" mode in your Mysql configuration.

Here's how you do it:

Using Phpmyadmin

1. As an administrator, login to your Plesk control Panel.
2. Click Servers then hit the Sql Servers Icon.

3. Click the Mysql tab, open Webmin.

4. Click Run SQL Query, or Query.

5. To check the current SQL server mode, type:

SELECT @@global.sql_mode;

If the output of the command returns the following line,

STRICT_TRANS_TABLES

Then you should continue reading my post. :D

6. To disable the mode that affects the operation, type this sql command on the query window:

SET @@global.sql_mode='NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION';
7. Test and see if the solution works.
You can also use the same commands on a mysql command line client.



Advanced Stream Redirector (asx) is designed to store a list of
Windows Media files to play during a multimedia presentation.Due to its nature
it is not available for Linux OS.
http://en.wikipedia.org/wiki/Advanced_Stream_Redirector

Allow .asx files in Plesk for Linux

Impossible?

The answer is NO. It is possible. With just a little tweaking, you can attain your goal.

The solution:

1. Locate the domains conf directory. It is usually under the /home/httpd/vhosts/domain/ directory.

2. Look for the httpd.include file. Open the file using your favorite text editor. E.g. vi

3. Add the line:

AddType video/x-ms-asf asf asx

Restart the http service (/etc/init.d/httpd restart or service httpd restart), test and you should now have a working .asx file under Linux.

Common SSH commands

I've compiled some of the common linux/unix shell commands. I believe this will be a great jumpstart for all *nix lovers like me.

Goodluck!


cd : change directory
ex. cd /root (brings you to the /root directory)
cd .. : moves you the upper directory
ex. if you're in /root
cd .. ( brings you to the cd / directory)

cd ~ : directs you to your home directory (/home)

cd - : brings you to the last directory you were in
cat : print file contents to the screen
syntax:
cat filename.txt - this prints the contents of the file filename.txt to your screen

ls : lists all the contents of a directory including all the files/directories in it.

ls -al : shows all files,directories,including hidden ones and the details/attributes for each file
ex.
[root@localhost var]# ls -al

total 220

drwxr-xr-x 27 root root 4096 Feb 5 20:25

drwxr-xr-x 23 root root 4096 Mar 22 23:11

chmod : changes the permissions of a particular file/directory.
Syntax:
From left to right:
USER - GROUP - EVERYONE

chmod filename

0 = --- No permission

1 = --X Execute only

2 = -W- Write only

3 = -WX Write and execute

4 = R-- Read only

5 = R-X Read and execute

6 = RW- Read and write

7 = RWX Read, write and execute


ex.
chmod 755 filename - gives read,write and execute permissions on the USER and read and execute permissions only to the Group and Everyone. This will look like:

drwxr-xr-x 3 root root 4096 Sep 5 2007 filename
chown : changes the file ownership
USER GROUP
drwxr-xr-x 3 root root 4096 Sep 5 2007 filename
Syntax:
chown owner.owner filename - this sets the owner of the user and group to "owner"
chown .owner filename - this sets the owner of the group to "owner"
Ex.
chown apache:apache filename
The output would be:
From
drwxr-xr-x 3 root root 4096 Sep 5 2007 filename
It will be
drwxr-xr-x 3 apache apache 4096 Sep 5 2007 filename

du - (disk usage) displays the file space allocated to each file and directory contained in the current directory

-a, display an entry for each file (and not directory) contained in the
current directory
-H, calculate disk usage for link references specified on the command line
-k, show sizes as multiples of 1024 bytes, not 512-byte
-L, calculate disk usage for link references anywhere
-s, report only the sum of the usage in the current directory, not for each
file
-x, only traverse files and directories on the device on which the pathname
argument is specified.
-h, show filesize in nice human readable format.

This prints the summary disk space usage of the current directory.

Ok so that's it for now. I will be updating this post from time to time so be sure to bookmark the link.


Cheers!

How to recover Plesk password

Yes. Its possible to recover your lost/forgotten Plesk password. Plesk uses a utility called plesksrvclient.exe. It is located in the "adminbin" folder of your Plesk installation directory.


The first step is to connect via RDP (Remote Desktop Protocol). Click on Start, choose Run then type there:

"C:\Program Files\SWsoft\Plesk\admin\bin\plesksrvclient.exe" -get


How to change Plesk interface logo

I'll show teach you how to change the Plesk interface logo. The logo is visible to the admin and clients.


It's easy. Here's how:

1. Log in to Plesk as administrator.
2. On the Server Administration page, click Logo Setup.
3. Click Browse. A local file browser window displays.
4. Select the logo image file from your local computer, and click Open.
5. In the Enter new URL for logo text box, type in the URL of the Web site you want the image to link to.
6. Click OK.

Hope that helps.

On my Trixbox setup, I was able to fix the hangup problem on a Wildcard TDM400p card by adding the following lines on zapata.conf:

busydetect=yes
busycount=4

Also, you might want to try other suggestions from the article Resolving Hangup Detection Problems fxo,tdm and voicemail in Asterisk Guru.


Earlier, we we're unable to access the Plesk Control Panel for the admin and clients. It doesn't show the login page or the usual error Page cannot be displayed.
Cause:
Offline management was disabled.

From Parallels KB,

Virtuozzo Power Panel has the following login mechanisms:
If
OFFLINE_MANAGEMENT parameter is set to "yes", VZPP accepts the VE "root" login
with the corresponding password when connecting to VE IP address.
If
OFFLINE_MANAGEMENT is enabled and Plesk Control Panel is installed in the VE -
loging in the VE using Plesk credentials (user admin with the corresponding
password) is supported on the VE IP address. In this case, however, the
management capabilities available via web interface are limited.

The Service VE administrative credentials (user vzagent0 with the
corresponding password) are supported as well. Upon administrative login all the
VEes on the Node are manageable.When offline management is on for a VE and the
VE has Plesk installed, Plesk panel interface works via Service VE (in other
words, port 8443 is forwarded to Service VE). In this case some additional
Virtuozzo-related functionality is added to Plesk interface.

Solution:

Enable offline management.

1. Go to the hardware node using your favorite ssh client. E.g. putty.exe

2. Type:
vzctl set (node id) --offline_management yes --save
Example. If the node ID is 101 then type:
vzctl set 101 --offline_management yes --save

That's it. You should now be able to access the Plesk control panel.

Intel CPU uCode loading error


While I was setting up this machine for a Trixbox project, I've encountered an error during the first bootup of the machine. My machine was an ASUS P5PE-VM motherboard,socket 775 with a Core 2 Duo processor and 2 Gigs of memory.


Intel CPU uCode loading error

Press F1 to resume...


Solution:


UPDATE BIOS.


Go get the latest BIOS update from support.asus.com.


1. Download the latest BIOS Update. ( It is important that you download the BIOS update that matches your motherboard's model.)




2. Save the downloaded file on a floppy disk.


3. Boot from the boards Support Cd. Browse the floppy disk.


4. To obtain a backup of your latest Bios settings, type:


afudos /0filename


5. Finally to update the BIOS, type:


afudos /ifilename <-- Type here the filename of the BIOS Update. It ends with a .rom file.


Important: The machine should not be restarted while the update is running.


After the update, restart. You should now boot with no problem.




Another set of great user guides/how-to's for Asterisk users that can help them have a working VOIP setup:

1. Trixbox 2 without Tears - http://dumbme.voipeye.com.au/trixbox2/trixbox2_without_tears.pdf

2. Trixbox without Tears(older version) - http://dumbme.voipeye.com.au/trixbox/trixbox_without_tears.pdf

3. The Trixbox Dumb Me Guide - http://aussievoip.com.au/wiki/DumbMe

4. Nerd Vittles Guide to Trixbox 1.0 and Freepbx 2.1.1(Part 1) - http://nerdvittles.com/index.php?p=137

5. Trixbox 2.0 Install - http://voipusers.org.nz/wiki/Trixbox_2.0_install_guide_for_dummies

6. Trixbox Quick Install Guide - http://www.trixbox.org/wiki/trixbox-quick-install-guide

You can also check out asteriskguru.com or send me a note!

For zipping up an entire directory, use the command:

zip -r directory directory


This creates the archive directory.zip, containing all the files and directories in the directory directory that is contained within the current directory.

zip directory *


This creates a zip file named directory.zip and contains all the files on the current working directory.

zip -j directory directory/*

You can use this if you want to create a zip archive and omits its directory name.

-j option - Store just the name of a saved file (junk
the path), and do not store directory names. By default, zip will store the full
path (relative to the current path).


Looking for an Asterisk Guide?

Here's a great how to that is documented for Asterisk newbies. I am using it as a guide as well.

http://members.optusnet.com.au/~bsharif/asterisk/AsteriskForDumbMe.htm

Ok. So I am playing around with Trixbox lately. I got a Asus P5B-VM board, 8 Gigs of memory, 2 Sata hard drives, and a Jmicron Controller. A pretty good setup for a VOIP system. But I'm having a strange problem. First, the installation asks for driver disk. I use the all-generic-ide=1 option and the installation continues.But, it proceeds with the Centos 4 install only!

I've seen on different forums that the Jmicron Controller is causing the problem. Trixbox still doesn't have a driver for such controller. Jmicron only supports 2.6.18 kernels. Too bad for me. Guess we'll have to try a different board.
I'll keep you posted!

ISO Image, from the definition of wikipedia, is an archive file (a.k.a. disk image) of an optical disc using a coventional ISO format that is supported by many software vendors. ISO image files typically have a file extension of .ISO but Mac OS X ISO images often have the extension ".CDR". The name "ISO" is taken from the ISO 9660 file system used with CD-ROM media but the term ISO image can refer to any optical disc image, even a UDF image.

CD/DVD-ROM to .ISO

If you are looking for a cd/dvd -rom to iso creator, Lucersoft is offering this free handy tool. No need for you to install the program. It's that easy.

1. Download the file here.

2. Unzip the file on your hard drive/Desktop.

3. Just click on the icon, and it will automatically locate where your CD/DVD-ROM is.

4. Hit the "Create ISO" button. It will ask for a location. Your new disk image will be stored there. Then click "Save". After a couple of minutes, you will have your own ISO image!