Comeback

And that’s it! over 3 months since I ever had a thought about blogging! Maybe I wouldn’t make a come back this soon if Matt over there didn’t wrote that scary post about the recent WordPress worm. I’m invulnerable to it since I turned off user registration since day 1 :P. However, lacking behind in updates isn’t something an IT professional should get used to so I paid 3 hours to have this blog upgraded and moved to a new domain, since my old one is going to expire in December anyways (The Koreans hosting it decided to cheapen themselves earlier this year by violating their own mission to bring free domains. Oh well).

Not the first time I move nor upgrade; in fact maybe I should consider doing WP upgrades and moves for other people for profit: it’s so smooth it almost feels good 😛 Can you imagine it? I described the process once before already but this time the situation is a bit different: I’m not moving host, everything is already in the database so Import/Export isn’t really necessary (and it costs time + bandwidth to do so).

1. I installed WP at the new domain and copy all the plug-in and upload over

2. I crafted the wp-config.php for the new domain to make sure all changes are dealt with. This time there is no change from WP 2.7 to 2.8

3. I changed the domain in the CP and have to login to the new domain. It says a database upgrade is needed, I hit next and got a blank admin screen. Befuddled

4. Google a bit, the first hit says this is caused by plugins, I moved them out and reload, it worked! All the posts are there and the theme is kept

5. Add the plugins back one by one until I found the one causing problem: No follow in posts

6. Edit the images to point to the new domain: if I were to use Import/Export like last time, the server will have to pull all the file over (which is on the same server, a waste of bandwidth) but the image URL in the posts will be automatically updated. This time I just move them over to the new domain’s directory, so I updated the posts’ images by two simple SQL queries:

UPDATE wp_posts SET guid = replace(guid, 'http://silentwind.co.cc', 'silentwind.za.net');
UPDATE wp_posts SET post_content = replace(post_content, 'http://silentwind.co.cc', 'silentwind.za.net');

Images should be displaying by now.

More disassembly

I concluded my last blog post streak with a disassembling post, it’s quite appropriate to have another one right now to celebrate my comeback 😛 This is going to be a short one: my TV Box which is used to watch analog TV with my computer’s monitor.

It used to work fine when new but when it’s about 6 months of age, its image quality gradually decrease until I’m more frustrated by watching TV with it than not at all, at which point I thrown it into storage. When I pulled it back out 2 weeks ago for a sudden need, it worked. But the next day it refused to display most of the channel :/

So I took it apart, maybe I can do something about it, it’s better than being furious at it anyway.

Pict0031

To the top is the outer case and the speaker (the one with a couple of wire dangling). To the bottom is the main circuit board, which is also everything. All the components are soldered to the board so nothing else could be taken apart without damaging it

Pict0033

Close up of the mainboard

I noticed a variable resistor above the chip in the middle (the one with the number 4 on it). I plugged everything in, turned it on and start tuning it left and right slowly to no avail. Later, I decided to turn it all the way to the left (so it would rise and possibly allow me to take something else out :P), this time it gives crystal clear picture and got all the channels. What confuses me is if from the start, it was working well because the resistor were at the top then what kind of mysterious force pushed it down later?

Chinese stuff after all, heh.

Disassembling that MP3 player

Almost everyone has one of them. They are cheap, they are convenient, they are a good way to show off. I had one from years ago but rarely use it since I hate anything that isn’t rechargeable (the ISO-14000 kind of guy). The button are a little off since I move it around a lot and must have broken something :/

So, when I have a new set of screwdrivers, it became my first victim :P.

I got off on the wrong foot: I tried to crack open the top side (the side with the screen) when actually I should do it otherwise. I found out eventually, but the casing suffered heavy scratches; and I acidentally peeled of a capacitor too 🙁

The rest is only a few screws, loose them and here are the results

Back

Battery side

Front

Screen side

Nice look inside Chinese manufacturing “technology”. All they’ve been doing is make a cheap (I mean really cheap) processor and bridge between the storage and the USB interface. It’s the Processor you see in the middle. AT is for Actions semiconductor. The storage chip is Samsung’s and the Radio is from Phillips.

It turned out what I’ve worried about this poor thing’s quality doesn’t matter that much. As long as the computer can recognize it, the thing will just work fine, the rest of the parts are from more qualified manufactures 😛

IMO, when stripped bare, the LCD looks a lot sexier, you can see the bright LED illuminating the fiber optics plate beneath. They look pretty good but is covered by the original casing. My guess is they make color by blending 4 LEDs: red, green, blue and white as they seem to be the strongest colors and have only one dot of light to the left side.

Pict0008

Blue

Pict0009

Red

It works fine even when disassembled (and lose a certain capacitor :”>). I guess that control screen brightness, since that’s the only setting not working.

In the end I’m too lazy to reassemble the thing. Furthermore, the buttons are off because the plastic handle inside is swollen and broken. Cheers to Chinese plastic! I can hold it back with glue but why do so when I can hit the circuits directly? So now I have the weirdest MP3 player I’ve ever seen. At least it does not electrocute me 😛 and is about 30% smaller from the original one (the case is damn big =__=).

Also, it’s not until I completely disassembled the thing I found many have disassembled their MP3s too; anh this website. They have a nice guide how to do what I’ve done to recover dead player. The site is a community run by owners of the MP3s. It turns out that they are pretty popular around the world. They have everything you’ll ever need related to these things (circut map, specs, firmware etc.)

The MP3s came under a variety of brands and forms but the internals are just the same. Some folks even made a computer out of it. There are also a resource editor and (code) disassembler so you can modify your MP3’s animation, logo and strings.

Something you may not know about your HDD

It’s inside your computer, and it doesn’t care whether you are a gaming maniac or an internet a holic. As long as you have to turn on your computer daily, one day it will make Murphy’s Law apply to you too: bad stuff will happen when it can cause the most damage.

Take a look around the internet; you’ll see you are not the only one concerned about how long your data will live. The crude fact is: your drive is not immortal. For most people who uses their computer daily, their HDD (from this point, it means magnetic platter drives)’s life will span from 3 to 5 years [4], really short if you ask me. If you don’t have enough money to replace a drive every time this period comes around, you’d better not store anything important there.

Besides obvious factors that will damage your data like a magnetic field, electric shock or physical shock, an invisible element could be temperature [5]. There are HDD fans to address this issue, those fans are quite cheap, they cost from $2 to $5. Others claim those fans will blow dust to other components. Well, if they would mitigate the heat issue that would not be a problem with me, since I take my time to physically clean my computer’s components every 3 months.

From the above source [5], there is also a ridiculous sounding argument: spinning drives will cause drive motor’s lubricant’s to spit out and condensed on the platters, making the drive crash. If that were such the case, why would they use such a lubricant in the first place? However, the spin may have something to do with it, as with every motor, any kind of movement would wear them out over time. It’s possible to stop your drive from spinning when you don’t use it through power management or some utilities. You can’t use this however, if your drive is frequently read from or written to [6].

Years ago, some guy from Quantum claimed that there’s little can you do to prolong your hard drive’s life span [1], so does Google’s 2007 research [2]

Failure rates are known to be highly correlated with drive models, manufacturers and vintages. Our results do not contradict this fact For example, Figure 2 changes significantly when e normalize failure rates per each drive model Most age-related results are impacted by drive vintages. However, in this paper, we do not show a breakdown of drives per manufacturer, model, or vintage due to the proprietary nature of these data.

You may think that high usage will make your drive fail you sooner. Actually the situation is more complex than that.

Hard drives less than three years old and used a lot are less likely to fail than similarly aged hard drives that are used infrequently, according to the report.

“One possible explanation for this behavior is the survival of the fittest theory,” said the authors, speculating that drives which failed early on in their lifetime had been removed from the overall sample leaving only the older, more robust units.” [3][7]

So, use your drive frequently when it’s still have warranty to make sure they are good, before giving them a rest :P. Some may say drives nowadays’ lifespan is shorter than before because of their high spin rates. That may be true though, but I can recall I hardly have my hard drive read or written when I was programming Pascal on a ram drive back in my 486 time :). As a matter of fact, the two hard drives I have back then still work now, a 200MB and a 800MB with spin rate somewhere below 5k. Sadly, you can’t have Visual Studio 200x to compile anything without writing to your HDD, even if you lay all your files on memory, VS would never fit csc there.

Back to the main topic, Google’s report also reveals that the temperature – failure correlation is complex too.

As you can see, the lowest failure rate is reached when the drive is around 40 degrees Celsius, be careful applying HDD fans. Though I think I will need one when my drive get older. When transferring the aftermath remains from the crashed drive to the new drive, I noticed the older drive (Samsung) is hotter than the newer (Seagate), though I’m unsure this is because of their age or being a brand matter like Google said.

Even though they say SMART failure somehow correlated to actual drive failure, you can’t depend on that not-so-smart feature to know when your drive is going to fail you. Actually, Google can’t even model how SMART errors affect failure rates

The attribute with highest failing rate is “anything” :P.

Google’s research shows that drives which have their first bad sector have 10 times probability to fail that intact drives. I may agree with this. The first time you hear a click from your drive (I mean a clear click you can hear from half a meter away, from outside the case), you can start backup your data, as your drive may fail you anytime from the next 2 weeks.

In the end, what you can do, you don’t know (because Google is mean :()! Despite being extensive and well conducted, Google’s research can’t accommodate every possible use case a normal user (e.g. you) will encounter. You can’t just stop yourself from turning the computer on (to control drive usage) those days, the net has become something you need like air, water or food! Thus, it’s best to simply do what you feel best to keep what you value most with you. There is a tip that works for everyone though: backup early, backup often and make as many backups as possible.

For a conclusion, there is a Wikibook dedicated to this topic, which I would recommend. [3]

Side story

When netbooks comes out, a new kind of HDD is introduced for the public too: solid state drive or SSD (my definition for a hard drive is something fixed in your computer and is not a removable media drive). My first opinion about them is that they won’t last long, since their life depends on the number of times data is written on them, what would happen if you download stuff, short on memory and the OS have to swap, or surf the internet with them (in which case the cache will get written and rewritten, again and again). Some of my colleagues already have their pen drives (which is basically the same technology as SSDs) failed after about 2 or 3 years usage. And lastly, the netbooks are cheap, the pen drives are cheap to, and cheap stuff rarely had high quality. 😛

However, some folks from a Mac forum may have proved that I’m wrong [8]. SSD can be written around 1 million times, plus they have 25% bonus capacity for wear leveling. They calculated that SSDs could outlive the owner if used sparsely. Well, time will tell.

References

(Don’t flame me for not having them sorted)

[1] Why good hard drives go bad

[2] Failure trends in a large disk drive population

[3] Minimizing hard disk drive failure and data loss

[4] How to Take Care of Your Hard Drive to Prevent a Crash

[5] BAD SECTOR: bn cht, nguyên nhân và phòng tránh

[6] Using spin down to prolong the life of old hard disks

[7] Hard disk test ‘surprises’ Google

[8] Replace Hard Drive with Flash Card “SSD”

about:brief and about:scribeFire

Don’t know when I started… Somewhere during the last week. I looked at Firefox’s featured add-ons list while updating my plugins (yes, I manually update
them for compatibility’s sake), I noticed Brief and ScribeFire (with nice logos :P), they are all free and are featured, which implies they are good for something. Why don’t give them a spin?

Brief

013009-0249-aboutbriefa1.png

Yes. I use Windows. Don't laugh!

This plugin lets you read feeds and that’s it! It has a nice interface with fold in and out effects (possibly some jQuery hidden behind); it now works with NoScript (they said so in the change log). Its advantages over Firefox’s live bookmark are:

  • You get to see the content of the post from the feed.
  • You can rate, mark read and deletes items.
  • Set individual update rate for each feed, or for all feeds.
  • Nice and customizable interface. (If you know CSS)

To me, at first it looked like a nice alternative to Microsoft Outlook’s feed functionality and I like its customizable interface. I have a feed with oversize pictures inside, it makes me scroll to see the content, all I have to do is go to the customization interface, and type some simple CSS

.article-content {
    width: 80% !important;
    overflow: hidden;
    font-size: 12pt !important;
}

font {
    font-size: 12pt !important;
}

Basically, the above CSS set the width of the content element to roughly 80% of the full window width, tell Firefox to trim off anything that come further than the edge, force all text size to 12 points to readability; and that’s it! The text content is wrapped nicely inside the window’s width, oversized pictures are trimmed off, should I want to view then, and “View Image” will come in handy.

To see brief’s elements on the page, go to Brief’s page description. Yes you can use some web development tools but trust me, all you got inspecting the page is a bunch of JavaScript insert :P.

<body>
    

But because it inherited from Firefox’s Live bookmark, it also share LB’s limitations like you can’t read the full post inline (if the publisher have chosen to publish it short), this can be frustrating reading feeds with lots of item. You want to read it? New tab! Shouldn’t a feed reader simplify the reading process? And looks like it’s compatible only with feeds which the Live Bookmark feature in Firefox is capable of reading.

And as a plugin, it has problems of its own, like it can rarely update the feeds on itself. At first I thought this was BetterCache’s fault, but even after disabling BetterCache, it still won’t update my feeds even if I clicked on each of them and choose “Update feed”. To have the feeds refreshed I have to go to the bookmark sidebar and update the like bookmarks there. Only then would the new items appear

So, if you want a news reader and like to pray that the updates work (possibly it just doesn’t like me), and always wanted to change the way how your news look, then Brief is right; but if you are looking for something that will satisfy all your reading need, there’s still a long way to go.

ScribeFire

A lightweight blogging plugin (about 500K). It lets you conveniently blog about stuff you like (a site, an image, you tube video etc.) straight from Firefox with a mouse click (or F8).

Yes, it implements many popular blogging services like WordPress, Blogger, Xanga, and custom blogs that implement the MetaWebLog API. For the basic part, it allows you to create / edit posts in a WordPad-like interface.

013009-0249-aboutbriefa2.png

It is capable of

In short, it lets you perform all the basic function all the blogging platform allows you in common. It’s quite good, I tried several posts and it does its job really fast, comparable to Word’s; there’s also some “extra” function like:

  • Insert a Flickr Image: You can search for Flickr images which match a keyword and insert it to your post, albeit the process is slow. I would prefer a Flickr-code text box, insert the image page URL and get the picture inside that page inserted (Flickr scatter a transparent 1×1 GIF over its images you can’t just save image as…)
  • Insert a You tube video: Same as Flickr.
  • Blogging toolbar: when you visit a blog of yours that you have registered with ScribeFire, you can quickly edit your posts and page by clicking their titles, nice feature that WordPress lacks, but can be fixed with a simple template tag (but that’s another story).

    013009-0249-aboutbriefa3.png

    Blogging toolbar

  • Managed ads: Haven’t tried this feature. Looks like it lets you insert and track ads easier, but I don’t like this one. I know that the plugin maker has the right to make some dough from this but it makes me suspicious if this plugin’s authenticity. To this point I trust it solely because it’s Mozilla-featured, and I’m still dubious. Furthermore, the space it takes to the left of the page looks clumsy; I just want to remove it off sight!

And as all my suspicions went, it’s right to some point. Since I began writing this post, I haven’t opened ScribeFire’s home page, I turned off all Firefox’s updates and only open some posts from my server (which is like thousands of miles away from ScribeFire’s), look at the traffic to and from my computer and see I’ve got:

013009-0249-aboutbriefa4.png

See that nice IP? 8.10.72.201, let’s find out where is it

013009-0249-aboutbriefa5.png

Surprise!

I could find out what it is trying to send back home, but doesn’t like to. I’m not going to use this for long anyway. Yes, it does its primary function quite good, but I doesn’t like that interface. Would you prefer the editor you see several paragraph above or this:

013009-0249-aboutbriefa6.png

Blogging with Word

I know that Word doesn’t have the full functionality set, but I feel more inspired blogging with Word than ScribeFire. UI over functionality, how superficial I am :P. But that’s not the only drawback of this plugin.

  • Every time you insert an image, you will have to wait for it to upload if it’s from your computer, in contrast with Word which uploads the image after you have published the post. ScribeFire’s approach makes the user wait, even if the delay is relatively short on broadband, it’s still a delay and the user (me) isn’t comfortable with it. It does have the advantage of easier control on which image has been uploaded and which have not (Word always upload all images every time you publish a post), but again, Word does not make the user wait: money can’t buy time but it can buy server space :P.
  • No find function in the code view (while the near-WYSIWYG editor has). You have like 1000 lines of HTML for your post? Forget your custom classes!
  • You can open multiple instances of it, ScribeFire will slow you browser down for a while but it will let you. This may easily confuse you and have you edit in the wrong window, especially when you are busy. And that lead to post conflict…

Both of the plugins are new, they have the potential to become better but for the moment, I’m done testing.

Notes on blogging with Microsoft Word 2007

Word 2007… Interesting piece of software, even enough to provoke a full-scale debate on ISO’s decision to have two standards at a time (isn’t standards are intended to unite people in the first place? :))) but that’s not in the scope of what I want to write right now. And no, I’m not going to tell you where to click in Word to start writing. You can read the good-but-is-the-only-blogging-article at Microsoft Office online for that.

Word is not perfect for blogging. For example the category management is just ill-designed. You’ll have to click a button, select the category and then insert it. The on-page category has a drop down box but the only item inside is “none” (what the…?) and yes, I am using the latest service pack. Possibly someone will eventually tell this to Microsoft to be fixed in future release, but hey, Word is not the only thing Microsoft released for the blogger community! There is Windows Live Writer (which is part of Microsoft new “live.com”-ing-everything strategy) too, which appears better suited for the purpose (the demonstration has pictures, categories and stuff listed in a nice view). Unfortunately it’s a 125MB download, and that’s not financially feasible for me to download (and blog about it here). You can download, try, and tell me instead 😛 [edit: a review about WLW can be found here, it cover most of what WLW have to offer, though it has given WLW quite a bias ;)]

UPDATE: WLW is actually only 5MB 🙂

Back to Word… good for text for not so good for blogs, you may as well encounter some problem blogging:

  • No HTML editing
  • Limited picture upload & management
  • Clumsy interface
  • etc.

I tried and solved some stuff ^^

Picture uploads

Word is a Microsoft software, Live spaces is a Microsoft blogging platform. The irony? Live spaces is the only service that doesn’t provide Atom or XML-RPC so Word has to e-mail blog to Spaces, and because blogging is that hard, even if you read and followed the direction on Live Spaces help, Word will just pop an error up when you tried to blog with pictures. Also, wordpress.com won’t allow you to upload pictures either (self-hosted WordPress installations like mine do); and possibly some other service on Word’s “supported” list won’t either… The solution is uploading the pictures to a separate host. If you ever tried to click on”Picture Options” you’d see some choices

  1. My blog provider: Doesn’t work because you are reading this 😛
  2. Don’t upload picture: Awn, not helpful at all
  3. My own server: Make 2 fields appear: upload URL and source URL

What is upload URL and source URL? Word help won’t tell you, Microsoft Office online won’t tell you either! It turned out after a couple of queries that, upload URL is something around an FTP address and source URL is the http address at which the picture should appear after being uploaded. The question turned to “what to fill in?” The links provided in the dialog box is just as helpless as the help 😛 You’ll have to find your own provider, which apparently must support the following

  1. FTP uploads
  2. HTTP direct link

Some image hosts support this, photobucket does have a plan with FTP access but that’s not quite cheap :P. IMO, it’s best to use a web host as you could use it for more advanced purposes later ^^. In this example, I’ll demonstrate with freehyperspace5.com, a free hosting service which anyone can register. You could choose your own host but try to avoid:

  1. Byet hosts: they have a high likelihood of deleting file storage only accounts even if their TOS doesn’t say so.
  2. Any other host that specified in their TOS that they are against picture hosting

Register an account at your host, remember [your username], [your password], [ftp host] and [homepage address], then go to word and type

  1. ftp://[your username]:[your password]@[ftp host] in the upload URL in Word, replace the square brackets with your own information. This looks something like ftp://wind:[email protected]
  2. http://[homepage address] for source URL

122608-1512-notesonblog1.png

Done! Press OK twice and now you are ready for picture (and smart art ^^) blogging with Word! No more manually uploading pictures and copy-paste the lengthy URL; just insert and publish! (For a demonstration, have a look at my previous posts, most of them are done with Word!)

Faster blogging

One proof that Word 2007 is designed in such a hurry: Every time you want to blog, you’ll have to click the big red button (the office button :P), choose new, wait for the dialog to appear, choose blog post, OK, wait for the blogging interface to appear… Sick, isn’t it? To start Word exclusively for blogging, you can follow these steps

  1. Browse to the word executable, usually it’s in C:Program FilesMicrosoft OfficeOffice 12winword.exe
  2. Right-click and choose Create shortcut
  3. Right-click the newly created shortcut and choose Properties, switch to the Shortcut tab
  4. In the Target field, add /t “C:Program FilesMicrosoft OfficeTemplates1033Blog.dotx” /q, replace “C:Program FilesMicrosoft Office” with your path if necessary 122608-1512-notesonblog2.png
  5. The /t tells Word which template to use at start, the /q (supposedly) suppress the splash screen

  6. Press OK
  7. Move the shortcut to where you want it to be: desktop, quick launch, or even start up if you want to blog every time you turn your machine on 😛

When I have some time available I’ll try to solve some more problems. (rest assured there are more, just wandering around you’ll see that Word’s blogging function is beta quality software and there hasn’t been any news from it from the word team since 2006)

PS: After some more looking, it turns out that Blogger has its own plugin for Word long ago (download it here), it worked on Word 2000 and above but the interface is not that interesting and it still does not allow you to post pictures – according to this podcast. To me the plug-in appears unupdated for a while…