13:55 Thank a Plugin Developer Day » WordPress Development Blog

WordPress by itself is very simple — what makes it compelling for most of its users is the wide array of plugins (and themes) available for WP. The average WordPress blog has about 5 plugins installed! Today we just passed 4,000 plugins available in our plugin directory. (Which is also embedded into everyone’s WordPress 2.7 or above.)

I declare January 28th our official “Thank a Plugin Developer” day. To celebrate take a look at the plugins you use and love, visit the author’s site, find their contact form, and drop them a note thanking them. (Or Paypal!) Look for the links in the plugin directory to “author homepage” and also to donate directly if they’ve specified a Paypal address.

Thank you to everyone who has ever written a plugin for WordPress, and here’s to the next four thousand. :)

Convert Your Old PC To Network Attached Storage With FreeNasMakeUseOf.com » 车东's shared items in Google Reader

One of the biggest problems still plaguing the environment today are the mass amounts of electronics being tossed out on a daily basis. This goes for everything from cell phones to televisions to your outdated stereo system. But most of all it’s the personal computer that still lacks consistent recycling.

The majority of both business and home PCs are typically either thrown out with the everyday trash, or turned over to one of the few electronics recycling warehouses in your area. These warehouses usually require some type of fee for disposal as well. Until we get some type of environmentally friendly method for computer recycling, I am going to recommend trying your own way. Such as adding that much needed storage to your home or work network. The simplest and cheapest method for doing this is using the open source FreeNAS.

FreeNas is an open source NAS (Network Attached Storage) operating system. FreeNAS does this with simply 32MB of data on a USB flash drive, hard drive or live boot CD. All of the configuration runs in a easy to use web interface and supports a wide range of protocols, including CIFS (samba), FTP, NFS, AFP, RSYNC and iSCSI. It supports both IDE and SATA drives. It also includes software based RAID (0,1,5), allowing you protection on failed drives.

After you have completed downloading the latest FreeNAS ISO image or LiveCD, you simply take your old, but still running PC and boot-up to install the image or simply run it from the Live CD, if that’s what you would prefer. Like I said before, you may also install this onto a compact flash or USB drive as well.

Once installed, you have a large plethora of options to choose from. Even including the ability for Active Directory integration into your Windows based business network.

The FreeNAS project has been around for a little while, so they already have a pretty good base of users, who can help you out on a moment’s notice. Their website is very easy to navigate, and there is plenty of documentation, and even a wiki on Novell’s site.

So if you have an old PC laying around and you want to get some use out of it, it can’t hurt to download and burn the LiveCD of FreeNAS. Once you get it up and running, your options are limitless. Use it as a multimedia storage device, an FTP server or even as an alternative backup location.

Have any of you used FreeNAS before?  Do you have any other suggestions for free Network Attached Storage?

Enjoyed the article? Please leave a comment and tell us what you think about it.

New on MakeUseOf …

Categorized under: , , , , ,

Related posts

09:34 The perils of InnoDB with Debian and startup scripts » MySQL Performance Blog

Are you running MySQL on Debian or Ubuntu with InnoDB? You might want to disable /etc/mysql/debian-start. When you run /etc/init.d/mysql start it runs this script, which runs mysqlcheck, which can destroy performance.

It can happen on a server with MyISAM tables, if there are enough tables, but it is far worse on InnoDB. There are a few reasons why this happens -- access to open an InnoDB table is serialized by a mutex, for one thing, and the mysqlcheck script opens all tables. One at a time.

It's pretty easy to get into a "perfect storm" scenario. For example, I'm working with one client right now who has a hosted multi-tenanting application that keeps each customer in its own database. So they have a lot of databases and a lot of tables. And they're running on Amazon EC2 with 8G of RAM and EBS storage, which is slower than typical directly-attached server-grade RAID storage. Since they have a lot of tables, InnoDB uses over 3.5G of memory for its data dictionary (the subject for another post -- we're working on a fix) and so we can't make the buffer pool as large as we'd like to.

To avoid physical I/O all the time we need to get some reasonable amount of data into the buffer pool. But we have to do this without death-by-swapping, which would be extremely slow on this machine, so we need to stop the buffer pool and the OS cache from competing. My chosen strategy for this was to set innodb_flush_method=O_DIRECT. We could also tune the OS, but in my experience that's not as effective when you're really pushing to get memory into the buffer pool. Remember we have 3.5G of memory less to play with, solely due to the data dictionary.

But this strategy will only reduce physical reads if the buffer pool follows a typical access pattern. That is, some of the data is in your working set and will stay in the buffer pool, some small part of it will move in and out of the buffer pool, and some won't be needed.

And that's where the Debian startup script breaks down entirely, because it doesn't follow this pattern. It's going to open every table, regardless of whether user queries require it or not. On big servers I've seen it literally run for days (or longer). In the meanwhile, it'll interfere with everything else going on. Look what happens:

CODE:
  1. mysql> show processlist;
  2. +------+------------------+----------------+-------------
  3. | Id   | User             | State          | Info       
  4. +------+------------------+----------------+-------------
  5. |    7 | debian-sys-maint | NULL           | CHECK TABLE tableA...
  6. 739 | user             |                | NULL       
  7. | 4776 | user             |                | NULL       
  8. | 6318 | user             | Sending data   | insert into tableB...
  9. | 6322 | user             | update         | insert into
  10. | 6327 | user             |                | NULL       
  11. | 6328 | user             | statistics     | select ...
  12. | 6334 | user             | statistics     | select ...
  13. | 6337 | user             |                | NULL       
  14. | 6340 | user             | Sending data   | select ...
  15. | 6342 | user             | statistics     | select ...
  16. | 6344 | user             |                | NULL       
  17. | 6345 | user             | Updating       | update ...
  18. | 6346 | user             | Sorting result | insert ...
  19. | 6351 | user             |                | NULL       
  20. | 6355 | user             |                | NULL       
  21. | 6356 | user             | statistics     | select ...
  22. | 6357 | user             | statistics     | select ...
  23. | 6358 | user             | Sending data   | select ...
  24. | 6359 | user             | statistics     | select ...
  25. | 6360 | user             |                | NULL       
  26. | 6361 | user             |                | NULL       
  27. +------+------------------+----------------+-------------

Notice all those processes in 'statistics' status. Why is that happening? Look at SHOW INNODB STATUS:

CODE:
  1. =====================================
  2. 090128  8:29:03 INNODB MONITOR OUTPUT
  3. =====================================
  4. Per second averages calculated from the last 15 seconds
  5. ----------
  6.  
  7.  
  8. SEMAPHORES
  9. ----------
  10. OS WAIT ARRAY INFO: reservation count 39125236, signal count 13530611
  11. --Thread 1161714000 has waited at row0sel.c line 3326 for 0.00 seconds the semaphore:
  12. S-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  13. a writer (thread id 1158064464) has reserved it in mode  exclusive
  14. number of readers 0, waiters flag 1
  15. Last time read locked in file btr0sea.c line 746
  16. Last time write locked in file btr0sea.c line 1624
  17. --Thread 1164011856 has waited at row0sel.c line 3326 for 0.00 seconds the semaphore:
  18. S-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  19. a writer (thread id 1158064464) has reserved it in mode  exclusive
  20. number of readers 0, waiters flag 1
  21. Last time read locked in file btr0sea.c line 746
  22. Last time write locked in file btr0sea.c line 1624
  23. --Thread 1164822864 has waited at row0sel.c line 3326 for 0.00 seconds the semaphore:
  24. S-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  25. a writer (thread id 1158064464) has reserved it in mode  exclusive
  26. number of readers 0, waiters flag 1
  27. Last time read locked in file btr0sea.c line 746
  28. Last time write locked in file btr0sea.c line 1624
  29. --Thread 1161849168 has waited at row0sel.c line 3326 for 0.00 seconds the semaphore:
  30. S-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  31. a writer (thread id 1158064464) has reserved it in mode  exclusive
  32. number of readers 0, waiters flag 1
  33. Last time read locked in file btr0sea.c line 746
  34. Last time write locked in file btr0sea.c line 1624
  35. --Thread 1163336016 has waited at btr0sea.c line 1529 for 0.00 seconds the semaphore:
  36. X-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  37. a writer (thread id 1158064464) has reserved it in mode  exclusive
  38. number of readers 0, waiters flag 1
  39. Last time read locked in file btr0sea.c line 746
  40. Last time write locked in file btr0sea.c line 1624
  41. --Thread 1159956816 has waited at btr0sea.c line 1127 for 0.00 seconds the semaphore:
  42. S-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  43. a writer (thread id 1158064464) has reserved it in mode  exclusive
  44. number of readers 0, waiters flag 1
  45. Last time read locked in file btr0sea.c line 746
  46. Last time write locked in file btr0sea.c line 1624
  47. --Thread 1157658960 has waited at btr0sea.c line 746 for 0.00 seconds the semaphore:
  48. S-lock on RW-latch at 0x2aaaae0b70b8 created in file btr0sea.c line 139
  49. a writer (thread id 1158064464) has reserved it in mode  exclusive
  50. number of readers 0, waiters flag 1
  51. Last time read locked in file btr0sea.c line 746
  52. Last time write locked in file btr0sea.c line 1624
  53. Mutex spin waits 0, rounds 5023577, OS waits 24953
  54. RW-shared spins 34364070, OS waits 33800501; RW-excl spins 5756394, OS waits 5297208

Everyone is waiting for mutexes, and they are all waiting for thread 1158064464 which has reserved it. If you hunt through the TRANSACTIONS section, you can see the OS thread IDs, and that one is the debian-sys-maint thread. You also see the other threads:

CODE:
  1. ---TRANSACTION 0 228527423, ACTIVE 0 sec, process no 30034, OS thread id 1159956816 starting index read, thread declared inside InnoDB 500
  2. mysql tables in use 7, locked 0
  3. MySQL thread id 6424, query id 1579718 10.255.106.47 user statistics

And correlating the thread ID back to the semaphores, you see thread 1159956816 is waiting for the semaphore.

Notice that this is effectively a global lock. The debian-sys-maint thread is not touching the same tables as the other queries; it's just touching the same internal structures. So a user working on table A can interfere with a user that wants access to table B.

The real solution is to disable this startup process. It's not even needed for InnoDB. Sooner or later you'll find yourself fighting with it. You can just put "exit 0;" at the top.

The solution I chose in this case?

CODE:
  1. mysql> KILL 7;

Immediately afterward everything cleared up.


Entry posted by Baron Schwartz | 3 comments

Add to: delicious | digg | reddit | netscape | Google Bookmarks

04:23 Video: Storage in the Cloud at Joyent » High Scalability - Building bigger, faster, more reliable websites.

Ben Rockwood of Joyent speaks on "Storage in the Cloud" at the first OpenSolaris Storage Summit.
Ben is the Director of Systems at Joyent. The Joyent Accelerators are based on OpenSolaris and ZFS. He has deep experience with OpenSolaris in the Real World.


^==Back Home: www.chedong.com

^==Back Digest Home: www.chedong.com/digest/

<== 2009-01-27
  一月 2009  
      1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31  
==> 2009-01-29