Differences between revisions 3 and 18 (spanning 15 versions)
Revision 3 as of 2011-04-01 13:03:57
Size: 8060
Editor: SamatJain
Comment:
Revision 18 as of 2011-05-09 23:39:01
Size: 13091
Editor: SamatJain
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
= Monitoring SSD reliability =

{{{#!text_markdown
The Internet is abuzz with talk about solid state reliability right now (see a [recent article by Jeff Atwood][atwoodssd]). Random, catastrophic failures aside, how can you know how much life you've eaten into your <abbr title="solid-state disk">SSD</abbr>?

If you've an Intel SSD, it's pretty easy; they export a [S.M.A.R.T.][smart] attribute "Media Wearout Indicator". Starting at 100 (new), the attribute decreases to, well, zero. Forget how to do that on Linux? It's easy:

<pre><samp><span class="prompt">$</a> <kbd>sudo smartctl -a /dev/sda | grep Media_Wearout_Indicator</kbd>
233 Media_Wearout_Indicator 0x0032 098 098 000 Old_age Always - 0
</samp></pre>

The SSD in my laptop is at 98, and my oldest SSD in another system (from mid-2009) is at 97. Yours?

On to the real news: the [OpenStreetMap][osm] project has [switched their tile rendering server to an SSD][ssdswitch]. A newer, consumer-grade <abbr title="multi-level cell">MLC</abbr>-based Intel 320 Series 600 GB SSD, in fact. Conveniently, OpenStreetMap monitors their servers with Munin, which by default [graphs all S.M.A.R.T. attributes][osmsmart], including Media Wearout Indicator.

Other than the initial import of the tile rendering database, OSM tile rendering does not consume many write cycles. But it definitely hammers the disk to death on reads. Keep a lookout on these graphs to see how their SSD ages over time. Don't forget to [contribute to OpenStreetMap yourself][osmcontribute] so we can see that number go down a bit quicker (I'm pretty sure OSM doesn't mind!).

  [atwoodssd]: http://www.codinghorror.com/blog/2011/05/the-hot-crazy-solid-state-drive-scale.html
  [smart]: http://en.wikipedia.org/wiki/S.M.A.R.T.
  [ssdswitch]: http://gis.638310.n2.nabble.com/Quicker-Tile-Rendering-td6342010.html
  [osm]: http://www.openstreetmap.org/
  [osmsmart]: http://munin.openstreetmap.org/openstreetmap/yevaud.openstreetmap/smart_sda.html
  [osmcontribute]: http://wiki.openstreetmap.org/wiki/Beginners%27_guide
}}}

= Using my Creative Commons-licensed photos =

{{{#!text_markdown

Since I've become [a photobug][flickr] and licensed those photos under the [Creative Commons][cc], I've been getting a lot of requests for reuse. After all, that's what <abbr title="Creative Commons">CC</abbr>-licensed content is for!

  [flickr]: http://flickr.com/photos/tamasrepus "Samat Jain's Flickr photostream"
  [cc]: http://creativecommons.org/

The "BY" bit in CC licenses, which [stands for attribution][ccby], means authors/creators must be attributed if you decide to use a work. It does not specify how a work should be attributed or cited (though, there are some [guidelines in CC's FAQ][ccfaq]), leaving it up to the owner of the work—the way it should be, of course.

  [ccby]: /2011/04/15/What-does-the-BY-in-Creative-Commons-license-names-mean
  [ccfaq]: http://wiki.creativecommons.org/Frequently_Asked_Questions#How_do_I_properly_attribute_a_Creative_Commons_licensed_work.3F

Flickr does a [terrible job][flickrcc] letting people know how to attribute works. If you're reading this, I've probably directed you here asking how I'd like you to cite or attribute any of my photos.

  [flickrcc]: http://daggle.com/flickr-fail-on-creative-commons-attribution-691

[flickr-photo:id=2869038143,size=m]

}}}

= Drupal 7 upgrade post-mortem =

{{{#!text_markdown
This weekend, I upgraded [Samat Says][samatsays] (this blog, in case you missed the memo) to [Drupal 7][d7].

  [samatsays]: http://blog.samat.org/
  [d7]: http://drupal.org/drupal-7.0

For my Drupal 4.6/4.7-based site, I had created my own theme, [Sands][sands]. Lack of time prevented me from porting Sands to Drupal 5 or 6, and it's unlikely it will be ported forward. I'm probably going to recreate it with one Drupal 7's many starter themes, however.

  [sands]: http://wiki.samat.org/Sands

}}}
Line 4: Line 65:
Earlier this week, [Mozilla released Firefox 4 Mobile][ff4mobilerelease] (née Fennec) for both Android and Maemo. A couple weeks ago, [Mozilla released Firefox 4 Mobile][ff4mobilerelease] (née Fennec) for both Android and Maemo.
Line 8: Line 69:
I've had an Android phone since 2008 and honestly, I've never browsed the web on my phone as much as I have in the past few months since I started using Firefox 4 Mobile. It really is that much better! Here are my thoughts (focused on the Android version) on why—which, mostly, is a treatise on how much Google is dropping the ball on Android's built-in browser. I've had an Android phone since 2008 and honestly, I've never browsed the web on my phone as much as I have in the past few months when I started using Firefox 4 Mobile. It really is that much better! Here are my thoughts (focused on the Android version) on why.
Line 16: Line 77:
It's a *complete* pain to type user names and passwords on mobile keyboards, exacerbated by the fact I personally practice good security and use a different password for each site on the web. Because Firefox Sync makes available on my phone all the passwords I've saved on my desktop, I never need fumble entering or remember anything anymore. It's a *complete* pain to type user names and passwords on mobile keyboards, exacerbated personally since I practice good security and use a different password for each site on the web. Because Firefox Sync makes available on my phone all the passwords I've saved on my desktop, I never need fumble entering or remember anything anymore.
Line 18: Line 79:
I use the web a lot (who doesn't?), proof of which is my 15 MiB history file. Sync makes available that same browsing history, everywhere. Having your browser history available to do simple things like coloring visited links purple really makes a difference (e.g., think about looking through apartment listings on Craigslist). I use the web quite a bit (who doesn't?), proof of which is my 15 MiB history file. Sync makes available that same browsing history, everywhere. Having your browser history available to do simple things like coloring visited links purple really makes a difference (e.g., think about looking through apartment listings on Craigslist).
Line 20: Line 81:
Having history available also powers Firefox 4 Mobile's Awesome Bar. I don't need to remember exact URLs anymore, or rely on a search engine—I can just start typing a keyword and Firefox's Awesome Bar automatically searches the URLs and page titles of pages I've visited, just like it does on the desktop. Having history available also powers Firefox 4 Mobile's Awesome Bar. I don't need to remember exact URLs anymore, or rely on a search engine—I can just start typing a keyword and Firefox's Awesome Bar automatically searches URLs and page titles of pages I've visited, just like it does on the desktop.
Line 45: Line 106:
The iPhone has had multi-touch Javascript events (think pinch-to-zoom, essential for mapping widgets) for quite a while, while such events have been [missing from Android from its inception][androidmt]. Firefox 4 Mobile has had [multi-touch support][ffmt] since last year, though, it's slightly different than the WebKit implementation and, IMHO, a bit more difficult to use without built-in gesture handling (i.e. no easy-to-use pinch Javascript event). The iPhone has had multi-touch Javascript events (think pinch-to-zoom, essential for mapping widgets) since its debut, but such events are still [missing from Android][androidmt] while introduced much later. Firefox 4 Mobile has had [multi-touch support][ffmt] since last year, though, it's slightly different than the WebKit implementation and, IMHO, a bit more difficult to use without built-in gesture handling (i.e. no easy-to-use pinch Javascript event). Also, Firefox Mobile is [leading the way][fftes] in supporting the (draft) [W3C TouchEvents specification][w3cte].
Line 49: Line 110:
  [fftes]: http://digdug2k.wordpress.com/2011/05/02/touchevents/
  [w3cte]: https://dvcs.w3.org/hg/webevents/raw-file/default/touchevents.html
Line 50: Line 113:
## Other stuff

Firefox 4 Mobile also supports add-ons. While I haven't found the need for any, there are some neat ports, like [Adblock Plus Mobile][adpmobile]. Expect the [list of add-ons][listaddons] to grow quickly.

  [adpmobile]: https://addons.mozilla.org/en-US/mobile/addon/adblock-plus/
  [listaddons]: https://addons.mozilla.org/en-US/mobile/
Line 57: Line 126:
[Go download Firefox 4 Mobile now][download] from Mozilla's landing page if you've not done so already. You can also get it from the [Android Market][market], or, if you don't or can't use the Android Market, get the [latest Firefox 4 Mobile release from Mozilla's FTP site][ftp] instead. Also, if you're playing [][spark], please [tag me][sparktag]! [Go download Firefox 4 Mobile now][download] from Mozilla's landing page if you've not done so already. You can also get it from the [Android Market][market], or, if you don't or can't use the Android Market, get the [latest Firefox 4 Mobile release from Mozilla's FTP site][ftp] instead. Also, if you're playing [Mozilla's Spark][spark], please [tag me][sparktag]!
Line 63: Line 132:
  [sparktag]: spark   [sparktag]: https://spark.mozilla.org/en-US/user/tamasrepus?f=t
Line 71: Line 140:
In my opinion, the best software keyboard for Android is [Swiftkey][swiftkey] (proprietary software, unfortunately). SwiftKey crashes when used with Firefox 4 Mobile… despite a [transparent bug report from Mozilla][swiftkeybug] requesting more information, SwiftKey appears to blame Firefox for the problem.
Line 72: Line 142:
  [swiftkey]: http://swiftkey.net/
  [swiftkeybug]: https://bugzilla.mozilla.orhttps://bugzilla.mozilla.org/show_bug.cgi?id=617298g/show_bug.cgi?id=617298

Monitoring SSD reliability

The Internet is abuzz with talk about solid state reliability right now (see a recent article by Jeff Atwood). Random, catastrophic failures aside, how can you know how much life you've eaten into your SSD?

If you've an Intel SSD, it's pretty easy; they export a S.M.A.R.T. attribute "Media Wearout Indicator". Starting at 100 (new), the attribute decreases to, well, zero. Forget how to do that on Linux? It's easy:

$ sudo smartctl -a /dev/sda | grep Media_Wearout_Indicator
233 Media_Wearout_Indicator 0x0032   098   098   000    Old_age   Always       -       0

The SSD in my laptop is at 98, and my oldest SSD in another system (from mid-2009) is at 97. Yours?

On to the real news: the OpenStreetMap project has switched their tile rendering server to an SSD. A newer, consumer-grade MLC-based Intel 320 Series 600 GB SSD, in fact. Conveniently, OpenStreetMap monitors their servers with Munin, which by default graphs all S.M.A.R.T. attributes, including Media Wearout Indicator.

Other than the initial import of the tile rendering database, OSM tile rendering does not consume many write cycles. But it definitely hammers the disk to death on reads. Keep a lookout on these graphs to see how their SSD ages over time. Don't forget to contribute to OpenStreetMap yourself so we can see that number go down a bit quicker (I'm pretty sure OSM doesn't mind!).

Using my Creative Commons-licensed photos

Since I've become a photobug and licensed those photos under the Creative Commons, I've been getting a lot of requests for reuse. After all, that's what CC-licensed content is for!

The "BY" bit in CC licenses, which stands for attribution, means authors/creators must be attributed if you decide to use a work. It does not specify how a work should be attributed or cited (though, there are some guidelines in CC's FAQ), leaving it up to the owner of the work—the way it should be, of course.

Flickr does a terrible job letting people know how to attribute works. If you're reading this, I've probably directed you here asking how I'd like you to cite or attribute any of my photos.

[flickr-photo:id=2869038143,size=m]

Drupal 7 upgrade post-mortem

This weekend, I upgraded Samat Says (this blog, in case you missed the memo) to Drupal 7.

For my Drupal 4.6/4.7-based site, I had created my own theme, Sands. Lack of time prevented me from porting Sands to Drupal 5 or 6, and it's unlikely it will be ported forward. I'm probably going to recreate it with one Drupal 7's many starter themes, however.

Why I use Firefox 4 Mobile, & Other Thoughts

A couple weeks ago, Mozilla released Firefox 4 Mobile (née Fennec) for both Android and Maemo.

I've had an Android phone since 2008 and honestly, I've never browsed the web on my phone as much as I have in the past few months when I started using Firefox 4 Mobile. It really is that much better! Here are my thoughts (focused on the Android version) on why.

Sync

Firefox 4 Mobile's number 1 killer feature is Sync, which syncs tabs, logins, browser history, and bookmarks across multiple devices. The most useful of these are logins and browser history.

It's a complete pain to type user names and passwords on mobile keyboards, exacerbated personally since I practice good security and use a different password for each site on the web. Because Firefox Sync makes available on my phone all the passwords I've saved on my desktop, I never need fumble entering or remember anything anymore.

I use the web quite a bit (who doesn't?), proof of which is my 15 MiB history file. Sync makes available that same browsing history, everywhere. Having your browser history available to do simple things like coloring visited links purple really makes a difference (e.g., think about looking through apartment listings on Craigslist).

Having history available also powers Firefox 4 Mobile's Awesome Bar. I don't need to remember exact URLs anymore, or rely on a search engine—I can just start typing a keyword and Firefox's Awesome Bar automatically searches URLs and page titles of pages I've visited, just like it does on the desktop.

As a freedom-loving, free and libre open source software advocate, another bit about Sync I love is that it is an autonomous web service. That is, you can download the server-side component of Sync and run it yourself, should you not trust Mozilla.

Google has a Sync-like feature in Android 3.0 for its built-in web browser and Chrome for your desktop, but so far nothing is available for anyone stuck on older versions of Android. It also isn't autonomous—you're locked into trusting Google.

HTML5

Firefox 4 Mobile has much better HTML5 support, in the sense it supports more New & Exciting Web Technologies (NEWT), such as CSS3, SVG, and new Javascript APIs.

Firefox has dropped vendor-specific prefixes for many CSS3 properties, including box-shadow, text-shadow, etc. All in all, it makes your CSS that much more clean.

There's support for SVG, only recently supported in Android 3.0.

There's support for notifications via a proprietary API. Recently landed in Chrome 10, it's still missing (AFAIK?) in Android 3.0, even with 3.0's rich notifications support.

The iPhone has had multi-touch Javascript events (think pinch-to-zoom, essential for mapping widgets) since its debut, but such events are still missing from Android while introduced much later. Firefox 4 Mobile has had multi-touch support since last year, though, it's slightly different than the WebKit implementation and, IMHO, a bit more difficult to use without built-in gesture handling (i.e. no easy-to-use pinch Javascript event). Also, Firefox Mobile is leading the way in supporting the (draft) W3C TouchEvents specification.

Other stuff

Firefox 4 Mobile also supports add-ons. While I haven't found the need for any, there are some neat ports, like Adblock Plus Mobile. Expect the list of add-ons to grow quickly.

When Firefox 4 Mobile was in beta, Mozilla didn't do a very good job alerting people to its high system requirements. However, on release, a supported platforms and systems requirements page is first and foremost. A summary: you need a phone with at least 512 MiB RAM. The official builds require an ARMv7-generation processor (or more specifically, one that supports ARM's Thumb instruction set), but there are unsupported builds for older ARMv6 devices that have enough RAM (e.g. T-Mobile's MyTouch Slide, aka the HTC Espresso). Not to gloat, but Firefox 4 Mobile for Android works great on my T-Mobile G2.

Go download Firefox 4 Mobile now from Mozilla's landing page if you've not done so already. You can also get it from the Android Market, or, if you don't or can't use the Android Market, get the latest Firefox 4 Mobile release from Mozilla's FTP site instead. Also, if you're playing Mozilla's Spark, please tag me!

On to other thoughts…

Firefox 4 Mobile's previous name was Fennec 2.0, a name I much prefer. But somewhere along the way, Mozilla decided to take a page from Microsoft's marketing playbook—home of atrocities like Microsoft Windows Live Mesh and Microsoft Windows Server Base Operating Systems Management Pack for Microsoft Operations Manager 2005. What makes it worse is disambiguating Firefox 4 Mobile for Android and Firefox 4 Mobile for Maemo means you're using 5 words for a product title.

In my opinion, the best software keyboard for Android is Swiftkey (proprietary software, unfortunately). SwiftKey crashes when used with Firefox 4 Mobile… despite a transparent bug report from Mozilla requesting more information, SwiftKey appears to blame Firefox for the problem.

Patient care in the ICU in terms of vectors and topological spaces

Biomedical Informatics, Medicine

A few weeks ago, Timothy G. Buchman gave a talk at the Columbia DBMI weekly research seminar. During the QA session, someone asked why patients in intensive care units (ICUs) were given such “extreme” treatments, often causing them to develop new health problems and complications, keeping them in the hospital. He replied with this wonderful mathematical metaphor about patient care.

You are a point in an n-dimensional space. Each dimension is some vital sign or homeostatic attribute, e.g. blood pressure, blood glucose, temperature, etc. Homeostasis is defined a polytope in that space. As you do the various things of life, your point moves within the space defined by that polytope. For example, when you eat, your blood sugar goes up, and the point moves along in the blood sugar dimension; when you take a cold shower, your body temperature is reduced, and you move along in that dimension. Young people have a large space inside their homeostatic polytope

When you leave this homeostatic polytope, you're considered “sick.” If you travel to far from it, you die.

People who enter the ICU have points that are moving away from their homeostatic polytope. Their movement away can be represented as a vector, representing how quickly their condition is deteriorating.

Treatments in the ICU represent vectors that try to point you back towards your homeostatic polytope.


SamatsWiki: DraftBlogs (last edited 2016-08-19 22:04:14 by SamatJain)