If you have multiple virtual hosts in your server and you specified different log files for each, it is more organized and easy to locate, but the downside is Linux has so called file descriptors or the number of files that it can be handle. Basically , it can be increased but I think it’s not really recommended just for the sake of it.
Making your apache logs more organized can be done by many ways, one way is via piped logging and use rotatelogs. And based on my tips before named Automatic unlimited subdomains via Apache mod_rewrite, one issue is the log files. But there’s one method to solve this, and this is by splitting up your log files.
INTRODUCTION
Data backup is the process of making copies of data in order to protect and restore original files whenever data loss happens. Aside from automated routine data backup, this method does not protect against failure and natural disasters. This is where off-site data backup comes in.
OBJECTIVE
To establish an off-site backup of important data such as website and configuration files, and database, by copying and burning it to a removable media via DVD.
Sample Scenario:
We need to backup the webserver files and database, and burn it on DVD disc.
PRE-BACKUP PROCEDURES:
Automatic unlimited subdomains via Apache mod_rewrite
Posted in Quick Tips & Tricks by admin | 7 CommentsWondering how blogger website gives you a subdomain from the blogspot.com domain based on your username of your choice? Well, the concept for this tutorial is somewhat related with it on setting up unlimited subdomains. I’m not sure how do they do it because it could be done by any script, hardcoded or not, thru static or dynamic way via database, many possibilities, and one possible way is thru URL rewriting via Apache’s mod_rewrite.
Requirements of this setup:
a. Apache 2.x or later
mod_rewrite module should be enable. To check if it’s enabled you should see this line on your httpd.conf
Obviously, this is really an old procedure, actually this is my documentation way back early 2006 when it’s my first time to work with asterisk. This procedure was implemented before in about 30-50 call center agents using softphones and it quite worked well.
So many things have changed, as we all know, from asterisk 1.2 to asterisk 1.6 , and Asterisk Management Portal is popularly known now as FreePBX. Other packages were also updated now, many changes but still asterisk is standing there as the best open source telephony system. We had many community and commercial PBX softwares today that are asterisk-based, that’s how big asterisk right now comparing back 2006
There’s an easy way of installing Apache, Mysql and PHP and it’s via yum. You can install or update httpd,mysql-server and php, php-mysql and some minor changes on your configuration files and you’re good to go. Well, the procedure below is one way to install also, if you’re quite bored and want to develop your sysadmin skills.
I. Operating System Installation
1. The typical type of installation is thru CD-ROM or DVD. If you want network install, you should have a CentOS boot disk to boot the server
Do you want a free Web Conferencing? Then you can try DIMDIM.
Dimdim lets anyone deliver synchronized live presentations, whiteboards and web pages and share their voice and video over the Internet – with no download required
Official Dimdim Website: www.dimdim.com
You can try the Open source Community Edition.
This is based on Dimdim Installation Procedure for CentOS
This step-by-step procedure was tested and implemented successfully on CentOS 5.2 32 bit (64 bit won’t work since the dimdim installation pack is for 32-bit only)
Requirements
Assuming you already have mysql server installed on your machine, the reason you are
installing phpmyadmin is to ease your administration of your MySQL like database creation and deletion, create/alter/drop/view tables and execute any SQL statements, privilege and trigger management, stored procedures, and backup/ maintenance
phyMyAdmin is a tool built in PHP to manage and administer your MySQL servers via your browser.
Requirements:
1.PHP
2.MySQL
3.php-mysql
4.gd/gd-devel
5. Apache
Installation and Configuration of Mailwatch for MailScanner
Posted in Tutorials by tux | No CommentsMailWatch for MailScanner is a web-based front-end to MailScanner and features include displays of inbound/outbound mail queue size, load Average and today’s totals for messages, spam, viruses and blocked content on each page header, Quarantine management allows you to release, delete or run sa-learn across any quarantined messages etc.
Tested on CentOS 4.4, MailScanner ver. 4.57.6, Sendmail-8.13
Requirements:
a. Working MailScanner setup
b. MySQL
c. Apache
d. PHP (w/ MySQL and GD Support)
e. Perl
f. DBD
g. DBD-MySQL
Here’s one trick to do that:
Step 1. Install FreeTDS
FreeTDS Website: http://www.freetds.org/ choose FreeTDS source distribution
Compile parameter: –prefix=/usr/local/freetds –enable-msdblib
Then, copy /etc/ld.so.conf, to /usr/local/freetds/lib; and then run ldconfig
Step 2. Change /usr/local/freetds/etc/freetds.conf
[sql2k]
host = your.mssql.server.ip
port = 1433
client charset = cp950
tds version = 8.0
b. tds version: 4.2 (for MS SQL Server 6.x); 7.0 (for 7.x); 8.0 (for 2000)
Step 3. Test FreeTDS connect to MS SQL Server
#cd /usr/local/freetds/bin
#./tsql -S sql2k -U sa
1> use mydatabase
2> select * from mytable
3> go
1.compile cronolog (http://cronolog.org) and install it on /usr/local/sbin
2. backup orig /usr/local/apache-tomcat-5.5.20/bin/catalina.sh on /root
3. edit lines on catalina.sh from
org.apache.catalina.startup.Bootstrap “$@” start \
>> “$CATALINA_BASE”/logs/catalina.out 2>&1 &
to
org.apache.catalina.startup.Bootstrap “$@” start 2>&1 \
| /usr/local/sbin/cronolog “$CATALINA_BASE”/logs/catalina.out.%Y-%m-%d >> /dev/null &
4. Removed the line
touch “$CATALINA_BASE”/logs/catalina.out
5. Restart web service
#/usr/local/tomcat/bin/shutdown.sh
# service httpd stop
# /usr/local/tomcat/bin/startup.sh
#service httpd start
TESTING
1. Check tomcat logs to see generated Catalina.out per day
# ls -la /usr/local/tomcat/logs
-rw-r–r– 1 root root 65607 Nov 6 14:55 catalina.out.2007-11-06
2. browse ww2.freelinuxtutorials.com and login using test account to see if tomcat is working


