Thursday, August 31, 2006

An alternative and clever way of scheduling tasks with perl.

Writing perl scripts that are better suited for scheduled tasks.

http://www.oreillynet.com/sysadmin/blog/2006/08/scheduling_perl_scripts_outsid.html

Sunday, August 27, 2006

Viewing mpeg and DVD in Suse 10.1

I installed Suse 10.1 in my laptop, this is a real peace of heaven, i love it. I like the installation (targeted for the general public, not only specialists) and Novell knows what the administrators and normal users want, and that is simplicity, easy to learn and manage. Suse Linux do not installs selinux by default or LVM like Fedora, i like this and the explanaitions given by Novell for doing so.

Now i want to see mpeg in my Suse 10.1, you will not be able to see them by default, you will need to use the program "yast" to install needed packages that do not come by default.

1) Run yast as root user, and add a new source for the installation, add the pacman repository:
Link: http://en.opensuse.org/Additional_YaST_Package_Repositories
Add the pacman repository

2) Execute: yast -i kaffeine-mozilla

This will install win32 drivers to see mpeg and DVD, also Kaffeine player.

Please, write here your opinion about Suse Linux or other distros.

Saturday, August 26, 2006

Simple rotation backup with tar

To do a simple backup in a few lines, that mantains a history of the past 7 days, you can use this simple script:

#!/bin/bash
# fecha has a formated date
fecha=`date +"%d-%m-%Y"`
# Backup and gzip the directory
tar zcvf /backups/trunk-$fecha.tgz /var/www/repository
# Rotate the logs, delete older than 7 days
find /backups/ -mtime +7 -exec rm {} \;


You are invited to post your little, simple though usefull scripts.

Friday, August 18, 2006

How to disable selinux

I have compiled apache in FC5 and when i wanted to start the daemon i received an error with security permissions. The problem was selinux that comes enabled by default.

I had to disable it manualy, this is done so:

$ setenforce 1
$ sestatus | grep -i mode
Current mode: enforcing
Mode from config file: permissive

------
Edit /etc/selinux/config and set SELINUX=disabled to make the change permanent.