Info: Linux I/O Performance Tests For HDD ageing calculation

Posted on Updated on

Hard Disk Data Transfer Speed measuring technique

How do you find out how fast is your hard disk under Linux? Is it running at SATA I (150 MB/s) or SATA II (300 MB/s) speed without opening computer case or chassis?

hdparm -tT /dev/sda
 Timing cached reads:   19884 MB in  2.00 seconds = 9954.83 MB/sec
 Timing buffered disk reads: 276 MB in  3.00 seconds =  91.88 MB/sec

To find HDD supported speed

hdparm -I /dev/sda | grep -i speed


       *    Gen1 signaling speed (1.5Gb/s)
       *    Gen2 signaling speed (3.0Gb/s)
       *    Gen3 signaling speed (6.0Gb/s)

Similarly you can use the dd command as follows to get speed info too:

Disk speed indicative of performance, different test different things,  on virtual environments (such as OpenVZ and KVM) and dedi, some tests might be better for some of them.

You can use the dd command as follows to get speed info too:

dd if=/dev/zero of=test bs=64k count=16k conv=fdatasync 
16384+0 records in 
16384+0 records out 
1073741824 bytes (1.1 GB) copied, 24.6998 s, 43.5 MB/

How to judge your result (note that this is only accurate for the exact test above)

  • 0-25 MB/s -> Garbage
  • 25-70 MB/s -> Acceptable
  • 70-120 MB/s -> Good
  • >120 MB/s -> Excellent

Error: No space left on device: mod_rewrite: Parent could not create RewriteLock file

Posted on

 Apache  service on a Server stops while restart it shows following messages in error_logs
[Thu Jun 20 20:04:20 2013] [crit] (28)No space left on device: mod_rewrite: Parent could not create RewriteLock file /usr/local/apache/logs/rewrite_lock
Configuration Failed

Such errors appears when you are running out of Disk Space or Quota which is assigned (which can be increased to fix the issue) OR when semaphores of the server gets full. Semaphores are often used to restrict the number of threads than can access some (physical or logical) resource.

Using the below command you can semaphores list.

root@server04 [~]# ipcs -s | grep nobody

So, In-order to clear the semaphores list. We have execute the following command.

root@server04 [~]# ipcs -s | grep nobody | awk '{print $2}' | xargs -n 1 ipcrm sem

After clearing the semaphores list, restart the apache server. Now, it will starts without any issues.But, it is an temporary solution it will re-occur when Semaphores get full.

Add following lines in “/etc/sysctl.conf” to get this issue fixed permanently. These values will increase the limits of Semaphores on the Server.

# Increases the semaphore limits & extend Apache’s uptime.

kernel.msgmni = 512
kernel.sem = 250 128000 32 512

Then load the new settings into the kernel using the command.

root@server04 [~]# sysctl -p
Now you are in safe zone.

How to Block login Gtalk , Yahoo , Hotmail IM’s on Desktop

Posted on Updated on

I Face the requirement that need to block all the Internet messenger on users desktop but they need to web login, and  block chat on web page also. Here I found some of the way to do it just add some lines host file.

The host file on

windows : C:/windows/system32/drivers/etc/hosts
Linux : /etc/hosts
MAC : /etc/hosts

1. Disable google chat

2. Disable hot mail Chat

3. Disable Yahoo chat

4.Disable skype Chat

How to block USB access in MAC????

Posted on Updated on

For OS X the guide describes disabling USB and Firewire storage:

1. Log on with an administrator account.
2. Browse to ‘/System/Library/Extensions’ folder on the system disk.
3. Trash both IOUSBMassStorageClass.kext and IOFireWireSerialBusProtocolTransport.kext which are found in this directory.
4. Empty the trash.
5. Reboot the machine.

Disabling USB storage on a Windows platform is only a little more complicated: