Canonical Did Shoot Its Own Foot With Unity

Posted by Pavel | Posted in General Information | Posted on 22-07-2012-05-2008

0

Unity seems to has been a thorn since it’s introduction and the reason for a mass exodus away from Ubuntu – which WAS the dominant distro (even trouncing on RedHat/Fedora long ago to take the crown).

According to DistroWatch, Mint seems to have a significant lead over Ubuntu and includes MATE: http://www.linuxmint.com/download.php

I’ve not used Mint, but for what I have been reading lately, it’s definitely a solid and working alternative for Ubuntu.

Oracle Seeks To Lure CentOS Users

Posted by Pavel | Posted in Linux News | Posted on 22-07-2012-05-2008

0

Yes, Oracle strikes again. This time Oracle seeks to lure CentOS users and attract  them to Oracle Linux  by releasing a migration service designed to help Linux users to move from CentOS.

It seems that (following Oracle’s perspective) you shouldn’t switch from CentOS to RHEL, but switch to Oracle Linux and pay even more for very, very, very lousy support.

In the migration service’s page Oracle posted a laughable chart with the “update delay” comparison between Oracle Linux and CentOS. They also claim to have “a large paid team of developers, QA, and support engineers that work to make sure this is reliable.”. So they are proud comparing themselves with people that work for free and for the love of it. (Oracle, are you serious!?)

First of all, the issue that Oracle highlighted, that existed in the first 3 quarters of 2011, has been fixed. CentOS now has 2 full time developers and Johnny Hughes has created a graph that shows the same information, in 2012 (EL6 Kernel release times) that Oracle depicted:

http://bit.ly/NEdAB8

As you can see, in 2012 CentOS has delivered the Kernels 48% faster than Oracle (25 days compared to 37 days).

CentOS also delivered the bugfix kernel for EL6 released 17 hours faster than Oracle.

The speedy updates are not just kernels … if you check turn around time for all packages in 2012, CentOS has been much faster than Oracle. Expect this to continue.

Also, expect the CR repo to be used for all future point releases … not just if the developers encounter problems.

While CentOS developers will not be petty enough to post a Migration script from Oracle Linux to CentOS (I can’t believe they posted that … REALLY?), Johnny Hughes announced that he will likely help anyone who asks him for help with that specific migration.

Ubuntu’s Constants Updates

Posted by Pavel | Posted in General Information | Posted on 16-07-2012-05-2008

0

I’m quite impressed of how annoying can a distribution become in the process of downloading updates once and again, and again and again.

For some reasons I’ve been using Ubuntu at work and at home (from my wife’s laptop) and these are some of the things that I just don’t understand about it:

  1. It updates every single day
    How is it possible that I have to download a lot of stuffs every single day? There’s no day where the annoying updates manager doesn’t pops up like a freaking soda, interrupting my work just to download a bunch of garbage.I think I have downloaded the size of the entire ISO like 4 to 5 times just based in dumb updates.
  2. “Unity”, really? I mean, are you serious?
    At work I’m stuck at Ubuntu 10.04. Surprisingly, it just works. It normally does what you tell it to do.At home, the story has another ending because I have 11.10. That pile of dancing icons seems to be alive and completely decided to make me die of a heart attack: It responds when it “thinks” it should, it’s horribly slow, it tends to disappear minimized applications, the menu’s have been reorganized following a ‘why to make it easy when it can be hard’ methodology, etc.
  3. Oh, that “Terminal”
    Every time I use that thing I get to the same question: “Whose brilliant, marvelous, outstanding idea was to add a whitespace after you autocomplete with Tab?”. Just try it out, open that thing and type: tail /etc[press tab here].

Fortunately, I hope to be able to bring back my desktop from my past place, where I have installed Slackware. I just hope it gets here in the time before Ubuntu makes me have a heart attack.

How To Make Backups Of Your Websites

Posted by Pavel | Posted in Linux Administration | Posted on 12-07-2012-05-2008

1

In a previous entry, I showed how to make backups in tape drives. While tape drives are still used these days (believe it or not), a lot of people would take most benefit of different approaches to make backups of their web applications, blogs, etc. Today I’ll be sharing short article about how to make backups of your website.

 

Quick Overview:

  • Preparing everything for your backup
  • Backing up your database and website files
  • Configuring your backup script to run automatically
  • Testing your backup

Preparing everything for your backup

As we need an automated backup solution for our websites, let us provide our script a way to connecting to the database without prompting for a password.

You can copy and edit the following text, then save it as .my.cnf in the home directory of your website. E.g.: if your home directory is “/home/my_website/”, then this file should be placed at “/home/my_website/.my.cnf” (note the leading dot ‘.’ in the file name)

[mysql]
user=your_mysql_user
password=your_mysql_password
host=localhost
database=website_db_name

[mysqldump]
user=your_mysql_user
password=your_mysql_password
host=localhost

Now, let us create a subdirectory called ‘bin‘ (from ‘binary’) in our home directory, that’s where our script will be placed. It’s possible that this directory already exists, in this case you can skip this section. The subdirectory should be created as ‘/home/my_website/bin‘.

 

Backing up your database and website files

Now, copy and edit this lines, and save it as “backup.sh” in your “/home/my_website/bin” directory. So after you have created it, it should reside in ‘/home/my_website/bin/backup.sh’

#!/bin/bash
#
# Copyright 2012,  Pavel Espinal  , SD, RD,
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
#    notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR “AS IS AND ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
# GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
# EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# Backup date string (to append to backup name)
# This is a date string that will be attached to your backup so you can
# know how recent it is
date_bk="`date +%F-[%A-%Hh-%Mm-%Ss]`"

# Which account to backup
# if your home directory is at "/home/my_website",
# then this should be "my_website"
user_bk="my_website"

# Which database to backup
# Name of the database you want to backup
database_bk="website_db_name"

# Backup recipient
# Email account where the backup should be sent to.
# I recommend you to put an email from your own website domain, then use a
# Gmail account to fetch these messages through POP3 :)
recipient_bk="backup@yourdomain.com"

# Name of files backup
filesBackupName_bk="${user_bk}Files-${date_bk}.tar.gz"

# Database backup name
dbBackupName_bk="${database_bk}DB-${date_bk}.sql.gz"

# DO NOT edit below this line (unless you know exactly what you are doing)

# Files backup
tar cf – /home/${user_bk}/public_html | gzip -c | \
 uuencode ${filesBackupName_bk} | \
 mail -s "Files Backup of ${date_bk}" ${recipient_bk}

# Database backup
mysqldump ${database_bk} | gzip -c | \
 uuencode ${dbBackupName_bk} | \
 mail -s "DB Backup of ${date_bk}" ${recipient_bk}

 

Configuring your backup script to run automatically

After you have created and uploaded the script to your ‘/home/my_website/bin’ directory, you must give the script execution rights. You can do this by modifiying the file permissions using any decent FTP client or through the command line:

chmod 744 /home/my_website/bin/backup.sh

 

Now that you have assigned the correct permissions to your file, you can go to your cPanel (assuming you have access to it) and configure a ‘cron job’ to run at the time you would like to backup your files. For example, If I want to to run my script every friday at 11:55 pm, I would add this line:

55 23  * *  fri /home/my_website/bin/backup.sh 1>/dev/null

 

Testing your backup

After setting a backup mechanism, the first thing you must do (and continue doing regularly) is to get sure that it is working, and from time to time downloading a backup and getting sure it is functional, otherwise bad things could happen, very bad things.

You could test your new backup system executing it from the command line. If you don’t know how to do it, tell a friend to do it for you; but under any circumstances trust your files to a backup you have not tested.

Finally, if there’s something you think I could make clearer in this article, just let me know.

How To Make Backups In Tape Devices

Posted by Pavel | Posted in Linux Administration | Posted on 11-07-2012-05-2008

0

After getting to my office and check my email, I found a message with a short and interesting question about how to make backups in tape devices.

To keep it short, the command used to manage tape devices is called ‘mt‘. It is this tool that allows us to control tape devices.

I am assuming that after attaching the tape, it is accessible through /dev/sr0.

Before starting, you might want to check the tape status to get information about the tape unit (this step is optional):

# mt -f /dev/sr0 status


If you we to see in which block we are:

# mt -f /dev/sr0 tell



Creating your backup:

First, let us rewind the tape

# mt -f /dev/sr0 rewind

Now, assuming we want to backup a directory called important_data , we do the following:

# tar czf /dev/sr0 important_data/

After it have completed, we can list the written files with this command

# tar tzf /dev/sr0



Restoring your backup

Assuming we want to restore our backup in the root (‘/’) directory, we would type the following

# cd /
# mt -f /dev/sr0 rewind
# tar xzf /dev/sr0 important_data


Now, let us rewind the tape and, if applicable, unload it.

# mt -f /dev/sr0 rewoffl


If we want to delete the information in the tape device, we type

# mt -f /dev/sr0 erase


And that’s basically how you do it. You might also want to check the man page of the ‘mt’ command in order to learn about a few more options that might come in handy while managing tape devices.

A New Path For Helping Community

Posted by Pavel | Posted in General Information | Posted on 10-07-2012-05-2008

0

After some years of taking some time to write articles, tips and some (hopefully) helpful material about Slackware Linux, I think it’s time to also take a new path in order to effectively  invest the time I want to dedicate to community.

For those of you who don’t know me, I’m currently hosting the Spanish translation of the “Slackware Linux Essentials” book at http://slackware-es.com. Besides of that, I used to take some time to write little ‘HowTOs’ at eSlackware.com in my native language, Spanish.

What will change?

  • First of all, I’ll likely to be redirecting the eSlackware.com domain to this one in order to focus readers attention at a single place (or maybe to the Slackware-es.com project).
  • I’ll try to translate any article originally written in Spanish that I think will globally help the Linux community.
  • I’ll not only focus on Slackware Linux.
  • I’ll not only focus on System Administration.

What will not change?

  • I will keep hosting “Slackware Linux Essentials” translation at slackware-es.com domain.
  • I will keep working on translating future versions of the book into Spanish (as time permits).
  • I will, from time to time, write articles/translations in Spanish in order to keep helping community members that are not so fluent in English.
Finally, what motivated  the change of plans?

Even if I really like Slackware (my favorite distribution so for the last 7 to 8 years), there are are other amazingly good distros (CentOS, Debian, etc.) with a non so closed development model, that I would like to get more involved.

Have you ever checked the Debian’s social contract? that is just so graceful that when you put that in contrast with things you read on some other project’s mailing lists or IRC support channel, you just see that huge difference in the way they approach to community. While some project’s answer to user’s request is “…it will be ready when it is ready” (directly implicating: if you don’t like it, get the h*ll out of here), projects like Debian states: “We will be guided by the needs of our users and the free software community. We will place their interests first in our priorities…”. That is just priceless, and it clearly indicates where you should focus your efforts to.

I’m not currently involved in the development of any distribution, but If I am to give my 2 cents to any project’s goal, it must be a project’s whose goal is aligned to mine.