Top 10 Ubuntu apps, #4: The gParted disk partition utility reformats hard drives into practically any format including: FAT16, FAT32, NTFS, and HFS+. Additionally, gParted can resize existing partitions without corrupting the data. Fear not Windows and Mac users, gParted comes as a live CD so you can leverage it for all your partitioning needs.
Ubuntu […]
ubuntu disk format utility
Partitioned Tables
This means primary keys and unique keys work as expected over the whole table,
and the MySQL query optimizer can optimize queries against partitioned tables more
intelligently than with merge tables.
Here are some important benefits of partitioned tables:
• You can specify that certain rows are stored together in one partition, which can
reduce the […]
Merge table performance impacts
The way MySQL implements merge tables has some important performance implica-
tions. As with any other MySQL feature, this makes them better suited for some uses
than others. Here are some aspects of merge tables you should keep in mind:
• A merge table requires more open file descriptors than a non-merge table con-
[…]
Character Sets and Collations
A character set is a mapping from binary encodings to a defined set of symbols; you
can think of it as how to represent a particular alphabet in bits. A collation is a set of
sorting rules for a character set. In MySQL 4.1 and later, every character-based value
can have a character set and a collation.* MySQL’s […]
How to Tune and Maintain the Query Cache
Once you understand how the query cache works, it’s easy to tune. It has only a few
“moving parts”:
query_cache_type
Whether the query cache is enabled. Possible values are OFF, ON, or DEMAND, where
the latter means that only queries containing the SQL_CACHE modifier are eligible
for caching. […]
Here are some types of optimizations MySQL knows how to do
Reordering joins
Tables don’t always have to be joined in the order you specify in the query.
Determining the best join order is an important optimization; we explain it in
depth in “The join optimizer” on page 173.
Converting OUTER JOINs to INNER JOINs
[…]
Query states
Each MySQL connection, or thread, has a state that shows what it is doing at any
given time. There are several ways to view these states, but the easiest is to use the
SHOW FULL PROCESSLIST command (the states appear in the Command column). As a
query progresses through its lifecycle, its state changes many times, and there […]
Restricting User Logins SSH
By default, SSH Secure Shell does not impose any login restrictions in addition to those provided by the operating system. However, you can restrict connections based on host, user name, or group.
The restrictions are defined in the sshd2_config file using the following syntax:
keyword pattern
Note: All the patterns used in the examples below are in accordance […]
Disable ssh root direct login
For security reasons it is not a good idea to permit ssh root direct login, it is better to login as another user, and then switch to root using the ’su -’ comand, to do this, you need to disable root from login directly using ssh protocol, this will decrease the possibility of a hacker […]
MySQL Newsletter: June 2009
Articles in this newsletter:
Highlights
- MySQL Enterprise Monitor with Enhanced Query Analyzer (Beta) is Available Now!
- Small to Mid-Size Business Solutions from MySQL
- For ISVs: Take the MySQL OEM Life Cycle Survey and Win a $150 Amazon.com Gift Certificate
- Case Study: thePlatform Migrates Media Publishing System to MySQL and Achieves 23x Performance Gain with the MySQL […]
Query Execution Basics
Follow along with the illustration to see what happens when you send MySQL a
query:
1. The client sends the SQL statement to the server.
2. The server checks the query cache. If there’s a hit, it returns the stored result
from the cache; otherwise, it passes the SQL statement to the next […]
Join Decomposition
Many high-performance web sites use join decomposition. You can decompose a join
by running multiple single-table queries instead of a multitable join, and then per-
forming the join in the application. For example, instead of this single query:
mysql> SELECT * FROM tag
-> JOIN tag_post ON tag_post.tag_id=tag.id
-> JOIN post ON tag_post.post_id=post.id
-> WHERE tag.tag='mysql';
You might run […]
Slow Query Basics: Optimize Data Access
We’ve found it useful to analyze a poorly performing query in two steps:
1. Find out whether your application is retrieving more data than you need. That
usually means it’s accessing too many rows, but it might also be accessing too
many columns. Fetching more rows than needed, Fetching all columns […]
Notes on Storage Engines
We’re not trying to write an exhaustive list; our goal is just to
present some key factors that are relevant to schema design.
The MyISAM Storage Engine
Table locks
MyISAM tables have table-level locks. Be careful this doesn’t become a
bottleneck.
No automated data recovery
If the MySQL server […]
Pros and Cons of a Normalized / Denormalized Schema
Normalized updates are usually faster than denormalized updates.
• When the data is well normalized, there’s little or no duplicated data, so there’s
less data to change.
• Normalized tables are usually smaller, so they fit better in memory and perform
better.
• The lack of redundant data means there’s less need for DISTINCT […]
Testing: A Sample Test Plan
http://it.toolbox.com/blogs/enterprise-solutions/testing-a-sample-test-plan-3283
Craig Borysowich (Chief Technology Tactician) posted 2/24/2005 |
If you decide to use the 10 step process for developing a test plan, I have provided a fairly comprehensive description of the tasks and events involved. But, I thought that having an example of a test plan created using the process may clarify some questions […]
Testing Overview
Purpose of Testing
Testing accomplishes a variety of things, but most importantly it measures the quality of the software you are developing. This view presupposes there are defects in your software waiting to be discovered and this view is rarely disproved or even disputed.
Several factors contribute to the importance of making testing a high priority of […]
Static Code Analizers for Python
www.doughellmann.com/articles/CompletelyDifferent-2008-03-linters/
Old-school developers remember lint, the static code analysis tool for C programs. There are several similar programs available for Python, and they can all help you clean up your act.
This month we continue examining Python development tools you have told me you can’t live without. A fair number of you have mentioned that you use […]
Beware of Autogenerated Schemas
We’ve covered the most important data type considerations (some with serious and
others with more minor performance implications), but we haven’t yet told you about
the evils of autogenerated schemas.
Badly written schema migration programs and programs that autogenerate schemas
can cause severe performance problems. Some programs use large VARCHAR fields for
everything, or use different data types for columns […]
Choosing Optimal Data Types
MySQL supports a large variety of data types, and choosing the correct type to store
your data is crucial to getting good performance. The following simple guidelines can
help you make better choices, no matter what type of data you are storing:
Smaller is usually better.
In general, try to use the smallest data type […]
