Install rar/unrar

To install rar/unrar

wget http://dag.wieers.com/packages/unrar/unrar-3.6.2-1.el4.rf.i386.rpm
rpm -Uvh unrar-3.6.2-1.el4.rf.i386.rpm

then

unrar e rarfile.rar

Alternativley if you are having problems with RPM’s, you can just get the CLI version of WinRar directly from www.rarlab.com. Make sure you have Glibc 2.4 though.

wget http://www.rarlab.com/rar/rarlinux-3.9.2.tar.gz
wget http://www.rarlab.com/rar/rarlinux-x64-3.9.2.tar.gz
tar xvzf rarlinux*
cd rar
make
make install

now you may get the error of not having glibc_2.4, here is the file download location for the glibc:

http://rpm.pbone.net/index.php3/stat/4/idpl/3284160/com/glibc-2.4-31.1.i686.rpm.html

Regular Expressions In Grep

Here is another excellent tutorial from Nixcraft

How do I use the Grep command with regular expressions under Linux operating systems?

Linux comes with GNU grep, which supports extended regular expressions. GNU grep is the default on all Linux systems. The grep command is used to locate information stored anywhere on your server or workstation.
Regular Expressions

Regular Expressions is nothing but a pattern to match for each input line. A pattern is a sequence of characters. Following all are examples of pattern:

Rest HERE

I love this guys shtuff…

A couple of current cpanel issues…

Currently there is a known issue where bandwidth reported in cPanel is skewed for sites with subdomains. This is something that cpanels’ development team is working on resolving, in the meantime, I would suggest disabling suspensions for bandwidth overusage on domains with subdomains.

————————————————————————————-

It seems that a recent cPanel update also caused an issue with PHPMyAdmin. Individual cPanel users are not able to import databases through PHPMyAdmin – only the root user logged into the main PHPMyAdmin area through WHM can perform this task at this time. As far as I can tell this seems to affect stable, current, and release customers at this time.

There is currently a ticket open with cPanel regarding this and they have said that it’s a known issue, and the only fix they currently have to offer is to make this change: edit

vim /usr/local/cpanel/3rdparty/etc/phpmyadmin/php.ini

and set

'upload_tmp_dir '

to

'upload_tmp_dir = /tmp '

You may also have to uncomment the line, as it’s often commented out. Then restart apache and cPanel:

/etc/init.d/httpd restart
/etc/init.d/cpanel restart

I’ve tried this on a few machines and it seems to be working on about 75% of them. There is no word yet on when they plan to release an official fix to upcp

————————————————————————————-

Net::SPF Perl Module install issue: The Net::SPF perl module doesn’t want to install on the server. This may be a bug with the package itself. cPanel was able to build SPF with a patch found here:

https://rt.cpan.org/Public/Bug/Display.html?id=53231

p.s. This is definitely not a cPanel bashing, quite the opposite; cPanel is very responsive to their clients needs and work tirelessly to resolve any and all issues which may arise. Personally, my hat is off to them for putting up with all the crap they do in the forums and elsewhere. They deserve much, much more credit than they actually get!

Linux file attributes

A little known aspect of the Linux file system is file attributes. They allow you to utilize certain options which you might think you need other software for, but they’re actually built into your file system. To view or change these you can use the lsattr and chattr commands. The available attributes are:

When a file with the ‘A’ attribute set is accessed, its atime record is not modified. This avoids a certain amount of disk I/O for laptop systems.

A file with the `a’ attribute set can only be open in append mode for writing. Only the superuser or a process possessing the CAP_LINUX_IMMUTABLE capability can set or clear this attribute.

A file with the `c’ attribute set is automatically compressed on the disk by the kernel. A read from this file returns uncompressed data. A write to this file compresses data before storing them on the disk. Note: please make sure to read the bugs and limitations section at the end of this document.

When a directory with the `D’ attribute set is modified, the changes are written synchronously on the disk; this is equivalent to the `dirsync’ mount option applied to a subset of the files.

A file with the `d’ attribute set is not candidate for backup when the dump(8) program is run.

The ‘E’ attribute is used by the experimental compression patches to indicate that a compressed file has a compression error. It may not be set or reset using chattr(1), although it can be displayed by lsattr(1).

The ‘e’ attribute indicates that the file is using extents for mapping the blocks on disk. It may not be removed using chattr(1).

The ‘I’ attribute is used by the htree code to indicate that a directory is being indexed using hashed trees. It may not be set or reset using chattr(1), although it can be displayed by lsattr(1).

The ‘h’ attribute indicates the file is storing its blocks in units of the filesystem blocksize instead of in units of sectors, and means that the file is (or at one time was) larger than 2TB. It may not be set or reset using chattr(1), although it can be displayed by lsattr(1).

A file with the `i’ attribute cannot be modified: it cannot be deleted or renamed, no link can be created to this file and no data can be written to the file. Only the superuser or a process possessing the CAP_LINUX_IMMUTABLE capability can set or clear this attribute.

A file with the `j’ attribute has all of its data written to the ext3 journal before being written to the file itself, if the filesystem is mounted with the “data=ordered” or “data=writeback” options. When the filesystem is mounted with the “data=journal” option all file data is already journalled and this attribute has no effect. Only the superuser or a process possessing the CAP_SYS_RESOURCE capability can set or clear this attribute.

When a file with the `s’ attribute set is deleted, its blocks are zeroed and written back to the disk. Note: please make sure to read the bugs and limitations section at the end of this document.

When a file with the `S’ attribute set is modified, the changes are written synchronously on the disk; this is equivalent to the `sync’ mount option applied to a subset of the files.

A directory with the ‘T’ attribute will be deemed to be the top of directory hierarchies for the purposes of the Orlov block allocator. This is a hint to the block allocator used by ext3 and ext4 that the subdirectories under this directory are not related, and thus should be spread apart for allocation purposes. For example it is a very good idea to set the ‘T’ attribute on the /home directory, so that /home/john and /home/mary are placed into separate block groups. For directories where this attribute is not set, the Orlov block allocator will try to group subdirectories closer
together where possible.

A file with the ‘t’ attribute will not have a partial block fragment at the end of the file merged with other files (for those filesystems which support tail-merging). This is necessary for applications such as LILO which read the filesystem directly, and which don’t understand tail-merged files. Note: As of this writing, the ext2 or ext3 filesystems do not (yet, except in very experimental patches) support tail-merging.

When a file with the `u’ attribute set is deleted, its contents are saved. This allows the user to ask for its undeletion. Note: please make sure to read the bugs and limitations section at the end of this document.

The ‘X’ attribute is used by the experimental compression patches to indicate that a raw contents of a compressed file can be accessed directly. It currently may not be set or reset using chattr(1), although it can be displayed by lsattr(1).

The ‘Z’ attribute is used by the experimental compression patches to indicate a compressed file is dirty. It may not be set or reset using chattr(1), although it can be displayed by lsattr(1).

Round Robin vs. Weighted Round Robin LB

The round-robin algorithm is often used as a simple-yet-effective method of distributing requests to a single-point-of-entry to multiple servers in the background. It’s used by DNS servers, peer-to-peer networks, and many other multiple-node clusters/networks.

In a nutshell, round-robin algorithms pair an incoming request to a specific machine by cycling (or, more specifically, circling) through a list of servers capable of handling the request. It’s a common solution to many network load balancing needs, even though it does not result in a perfectly-balanced load distribution, strictly speaking.

Weighted round-robin provides a clean and effective way of focusing on fairly distributing the load amongst available resources, verses attempting to equally distribute the requests. In a weighted round-robin algorithm, each destination (in this case, server) is assigned a value that signifies, relative to the other servers in the pool, how that server performs. This “weight” determines how many more (or fewer) requests are sent that server’s way; compared to the other servers on the pool.

Say you have three servers that have been individually benchmarked and configured that are to be deployed in a weighted round-robin environment. The
first can handle 100 req/sec, the second can do 300 req/sec, and the last can only do 25 req/sec (all on average, tested with an automated benchmark serving
the same data). Normally, with such a discrepancy in the servers’ performance, the third would be excluded from the setup entirely. But in a weighted round-robin, each server can be assigned as much as it can handle in the round-robin configuration script/file:

Resource Weight
——– ——
server1.fqdn 4
server2.fqdn 12
server3.fqdn 1

It’s pretty clear what happens next: for every 12 requests sent to server two, 4 will be sent to server one, and just 1 will be sent to server 3. The result is a more even, if less equal, load distribution.

So in a nutshell, Weighted Round Robin works in a similar way to Round Robin, but assigns more requests to nodes with a greater ‘weight’. Over a period of time, nodes will receive a number of requests in proportion to their weight.

Weights must be positive integer values; a node with a weight of ‘4’ will receive 4 times as many requests as a node with a weight of ‘1’.

http://neosmart.net

WordPress : 10+ life saving SQL queries

From http://www.catswhocode.com

Although there’s lots of things that you can do in WordPress, sometimes you may need a quick fix for a specific problem. In those cases, working directly on the database can be a real life-saver. In this article, I’m going to show you 10+ extremely useful SQL queries for WordPress.How to execute SQL queries

For those who don’t know yet, SQL queries have to be executed within the MySQL command line interpreter or a web interface such as the popular PhpMyAdmin. Since we’re going to work on WordPress, you should note that the SQL Executionner plugin provides an easy-to-use interface that allows you to run SQL queries directly on your WordPress blog dashboard.

Although all the queries from this article have been tested, don’t forget that you shouldn’t test any of those on a production blog. Also, make sure that you always have a working database backup.

The rest of the article HERE

Geeks take heart…

From www.dailymail.co.uk

The perfect man is a geek with facial stubble… women’s secret turn-ons revealed

Most women claim to be attracted to tall, dark and handsome men, but a new study has revealed that facial stubble and a geeky personality are their biggest secret turn-ons.

Despite complaining that it looks unkempt and feels rough to touch, the unshaven look on a man is actually a turn-on for 41 per cent of women.

A slightly geeky personality came second, proving that women really do like a guy who knows their stuff when it comes to technology.

A hairy chest was voted third, followed by a man who loves to read or cries at a soppy film.

Other secret turn-ons to feature in the top ten include grey hair, glasses and being a passionate supporter of a sports team.

But almost one in five would never admit what they really find attractive in a man to other people.

A spokesman for www.onepoll.com, which carried out the research, said: ‘Publically, girls will claim they want a muscly guy, who is hair free and manly enough not to show his emotional side.

‘But these results prove that they secretly want something different. It seems women really do like a guy who is able to show a softer side, or who is carrying a little bit of extra weight.

‘I’m sure it’s a relief to men all over the country to find out that women aren’t actually looking for that perfect guy.’

The poll of 2,500 women also revealed that 91 per cent would actually prefer a guy who had a few flaws over someone who is perfect.

And more than half would rather a guy who was soft and cuddly instead of toned and muscly.

Almost two thirds would prefer to be with a naturally hairy man, while 56 per cent like a guy with a little bit of stubble over someone who is clean shaven or has a full beard.

Women also prefer a guy who doesn’t spend too much time on his appearance, with 63 per cent saying they would like a man who got ready quickly rather than fussing over what he looked like.

Fifty-eight per cent of women even want a guy who doesn’t care what he eats over someone who is watching his weight and counting calories.

OMG... i'm freakin PREFECT!!! lol...

Logstalgia

http://code.google.com/p/logstalgia/

Description

Logstalgia is a website traffic visualization that replays or streams Apache web-server access logs as a pong-like battle between the web server and an never ending torrent of requests.

Requests appear as colored balls (the same color as the host) which travel across the screen to arrive at the requested location. Successful requests are hit by the paddle while unsuccessful ones (eg 404 – File Not Found) are missed and pass through.

The paths of requests are summarized within the available space by identifying common path prefixes. Related paths are grouped together under headings. For instance, by default paths ending in png, gif or jpg are grouped under the heading Images. Paths that don’t match any of the specified groups are lumped together under a Miscellaneous section.

The simulation can be paused at any time by pressing space. While paused, individual requests can be inspected by passing over them with the mouse.

Requirements

The display is rendered using OpenGL and requires a 3D accelerated video card to run.

An example access log is included.