January28
To set an alternate SMTP port in Microsoft Outlook Express:
- In Microsoft Outlook Express go to Tools > Accounts
- Click the Mail tab.
- Click the account and then click Properties.
- Click the Advanced tab
- Change “Outgoing mail (SMTP)“. The alternate port will be provided to you by your host, which is generally 25 or 587
- Click Apply and then OK.
To set an alternate SMTP port in Mozilla Thunderbird:
- In Mozilla Thunderbird go to Tools > Account Settings
- Now, select “Outgoing Server (SMTP)” at the bottom of the list that you see in the left panel.
- Select the account and click Edit
- Change Port from 25. The alternate port will be provided to you by your host, which is generally 25 or 587.
- Click OK.
January27
Looking to create a website just like youtube.com , dailymotion.com?
I will highly recommend taking into consideration one of the popular video sharing script- PHPMotion.
PHPmotion is a free video sharing software that also has support for other types of media such as audio/mp3 sharing. PHPMotion- Content Managent System or (media cms application) will allow you to create and run your very own Video Sharing website, Music Sharing Site, Picture Sharing Site.
- PHPmotion is 100% free to download and to use
- Template based design of PHPmotion means you change the look and feel.
- A growing user base of over 100 000 webmastes have already downloaded PHPmotion
- PHPmotion also has a fully featured admin area to manage your site
- Full support for mp3 audio (can be disabled)
- Supports playlists
- Fully CSS based template for easy editing
System Requirements:
Servers – Linux/Unix server
– PHP 4.3 and above (including support of CLI)
- MySQL database server
- LAME MP3 Encoder
- Libogg + Libvorbis
- Mencoder and also Mplayer
- FFMpeg-PHP
- GD Library 2 or higher
- CGI-BIN
- Be able to run background processes
PHP Settings
– open_basedir = (no value)
- upload_max_filesize = 100M
- post_max_size = 100M
- max_execution_time = 1500
- session.gc_maxlifetime = 14000
- safe_mode = off
- Thread saftery = disabled
- enable_dl = On
January20
You can use the following commands to uninstall Tomcat.
cd /usr/sbin/stoptomcat
rm -f /usr/sbin/starttomcat
rm -f /usr/sbin/startomcat
rm -f /usr/sbin/stoptomcat
It is important that you remove all mod_jk lines from httpd.conf, including addmodule, loadmodule, and include line.
January18
While doing a mysql start you may sometimes get the following error:
Starting MySQLCouldn’t find MySQL manager (/var/lib/bin/mysql) or server (/var/lib/bin/mysqld_safe)
To fix this you need to comment out or remove the basedir directive line from /etc/my.cnf file
[mysql.server ]
server=mysql
#basedir=/var/lib
Now restart mysql
# service mysql restart
January17
You can disable direct root login for ProFTP by modifying the proftpd.conf file.
Modify /etc/proftpd.conf
Add RootLogin off
Restart ProFTP
/sbin/service proftpd stop
/sbin/service proftpd start
November26
mod_evasive and mod_security modules are used to secure Apache Web Server from DDoS and brute force attacks by implementing web application firewall.
Download the source
wget http://www.zdziarski.com/projects/mod_evasive/mod_evasive_1.10.1.tar.gz
tar -xzvf mod_evasive_1.10.1.tar.gz
cd mod_evasive
Compile in the mod_evasive apache module using apxs
For Apache 2
/usr/local/apache/bin/apxs -i -a -c mod_evasive20.c
For Apache 1.3
/usr/local/apache/bin/apxs -i -a -c mod_evasive.c
If the apxs path is not /usr/local/apache/bin/apxs replace it with the appropriate path
Edit your httpd.conf /usr/local/apache/conf/httpd.conf
Add the below lines:
======================
DOSHashTableSize 3097
DOSPageCount 2
DOSSiteCount 50
DOSPageInterval 1
DOSSiteInterval 1
DOSBlockingPeriod 10
DOSEmailNotify user@yourdomain.com
======================
Restart apcahe:
/etc/init.d/httpd restart
November25
To flush the exim queue from the command line do the following:
At the command line prompt type:
exim -qff
If you need to turn on debugging for a more detailed picture when flushing the mail queue then use the following command:
exim -qff -d9
November24
Any non-optimal SQL commands or statements that take too long or lengthy time to execute will use up a lot of system resources, causing MySQL database to run slower.
MySQL has built-in functionality to capture slow query log or identify queries that take a long time to execute. You can enable the full SQL queries logs to a file or only slow running queries log.
To enable you just need to add some lines to your my.cnf file, and restart. Add the following:
* To enable slow Query Log only
log-slow-queries = /var/log/mysql/mysql-slow.log
long_query_time = 1
After enabling slow query, mysqld writes a statement to the slow query log file and it consists of all SQL statements that took more than long_query_time seconds to execute. The time to acquire the initial table locks is not counted as execution time. mysqld only log after SQL statements has been executed and after all locks have been released, so log order might be different from execution order. The minimum and default values of long_query_time are 1 and 10, respectively.
* To enable full Log Query
log=/var/log/mysqldquery.log
The above will log all queries to the log file.
Restart MySql after making the changes.
November24
If you are getting “(13)Permission denied: /home/username/public_html/shop/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable, referer: http://www.yourdomain.com/shop/index.html” error in apache error logs file /usr/local/apache/logs/error_log as well as the site is showing 403 Forbidden Error.
Then first please check the permissions of your folder and .htaccess file because folder permission are most likely 755 and .htaccess permission 644. Permissions can be changed via FTP or SSH.
In case you still are getting the same problem, then it might be the Frontpage Extensions causing the problem. To fix:
* Login into your CPanel account
* Click on Frontpage Extensions icon
* Click on Reinstall extensions button beside your problem domain.
* Done.
(make sure to have a backup copy of your data before reinstalling Frontpage)
November23
Telnet sends clear text passwords and usernames through logins and should be disabled on all web servers and replaced with SSH.
TELNET server listens for incoming messages on port 23, and sends outgoing messages to port 23.
1. Login to your server through SSH and su to root.
2. Type pico /etc/xinetd.d/telnet
3. Look for the line: disable = no and replace with disable = yes
4. Now restart the inetd service: /etc/rc.d/init.d/xinetd restart
5. Turn off it through chkconfig as well because it can still start through that.
/sbin/chkconfig telnet off
6. Scan your server to ensure port 23 is closed.
nmap -sT -O localhost
Also run ps -aux | grep telnet and if you find anything other than “grep telnet” you may kill the process.