NightlyArt Revival

gonna revive the Net, single-handedly

Tag: OS X

changed home directory on OS X

done with root user

Unfortunately, I’m not in the luxury of writing a full-fledged article about this. Feel free to browse the original articles from OS X Daily here and the steps to enable root account on OS X here.

But, I have something to share with you about the post-process.

1. I ran the Disk Verify to fix permission errors (if there was any error).
2. uTorrent can’t be used anymore, needed to re-install.

That’s all. I was lucky I got no errors during the process.


Enjoy your weekend.

from lastpass to keepass

I figured out that I didn’t use LastPass on FireFox at all (and I didn’t really like it… the interface). I made my fingers to type something on the Google and came up with the same solution I used on Windows previously, the KeePass. One problem: KeePassX (KeePass for OS X) can’t recognize the .csv file generated by the LastPass Export Tool. Hence, I needed to find a solution.

Simple python script called lastpass2keepass, which is available on the GitHub. The step is quite simple:

python exportedFile.csv

lastpassexport test

The next step is: using the KeePassX import tool, choose Import from… >> KeePass XML to import the recently converted XML file.

import from keepass XML


OS X’s virtual memory (VM)

What the hell is Virtual Memory? For Linux aficionado, it is the SWAP space. In simpler words Virtual Memory acts like RAM, but it uses HDD as the space instead of a unit of physical RAM chip. The benefit of having SWAP active on your machine is it can boost performance when you’re lacking RAM capacity as in you need to run few applications that need more than 4.5 GB RAM but you only have 4 GB RAM, hence the 0.5 GB will be moved to SWAP. That’s simplest way to explain, and maybe technically inaccurate.

@pali7x recommended me to turn of the encryption on the VM because it can boost up performance a bit. So, I give a go. Simply fire up the Terminal with this command line

sudo defaults write /Library/Preferences/ DisableEncryptedSwap -boolean yes

If you want to revert back to normal, simply change yes to no. The command line above disables the encryption on you SWAP space. If you want to check, you can use this command:

sysctl vm.swapusage

If you haven’t turned off the encryption on SWAP, it would return like this:

vm.swapusage: total = 64.00M used = 0.00M free = 64.00M (encrypted)

And if you just turned off the encryption, it will be like this:

vm.swapusage: total = 64.00M used = 0.00M free = 64.00M

checking sysctl

That’s it. Encryption is turned off. If you wanna be a bit radical (and you have RAM more 8GB or more), maybe you might want to fully disable SWAP space. It can be done by simply firing up your Terminal with this command:

sudo launchctl unload -w /System/Library/LaunchDaemons/

Warning! Please do research about turning off Virtual Memory.

… and why do I need to disable the encryption on VM?

Using HDD as the SWAP as the extension of RAM is a good idea, but the downside is the read/write speed on HDD is much slower than read/write speed on RAM. On OS X, encryption is forced on the SWAP space, adding the ‘insignificant lagginess’ in bargain for extra security. Normal end user won’t notice this, but for experienced user, you can really feel it (as the matter of fact, I do).

So, to reduce the ‘insignificant lagginess’ effect, I turned off the encryption. Turning the VM completely might minimize the lagginess even more, but I’m not gonna recommend it if you have RAM less than 8GB.

p/s: Please restart your OS X for the change(s) to take effect.

Spotlight disabled. the end.

My hunch was correct. The laggy and saggy performance was Spotlight‘s fault, or specifically, the underpinning processes: mds and mdworker. After series of hunting the trapped witch (which spanned from checking the SMART status, benchmarking using GeekBench and testing Disk Read/Write speed, fixing disk permission), I told @pali7x that I was a bit curious about the Spotlight‘s suspicious activity: always re-indexing from time to time, with ETA no shorter than 4 hours each time of re-indexing.

Use this command line to disable the Spotlight:

sudo launchctl unload -w /System/Library/LaunchDaemons/

The witch then got burned at stake. I restarted my MacBook, brew some tea and opened it again. Good lord there was no annoying spinning beachball, VLC much more responsive, Finder regained its responsiveness reading NTFS drive and HFS+. Everything back to normal again.

As for Spotlight, I haven’t done the full checkup/cleanup yet, and right now I’m relying on the QuickSilver.


That’s it!

Analyzing SMART status report

I’ve done analyzing the S.M.A.R.T status on this OS X. @pali7x recommends SMARTreporter, which can be downloaded here. These are the results.

01_SMART Reporter

The moment I installed SMARTreporter, this is what I got. HDD status is verified. There are 3 types of statuses; verified, failing and unknown. If the HDD is verified, the menubar icon is green. Green means safe, hence my HDD is running OK so far.

02_HDD status - verified

Let’s do the further check by using the OS X’s Disk Utility. Click on any disk, and simultaneously press “CMD” and “I“.

03_smart status verified on diskutil

Since the status shown is pretty simple and holds no detail, we need to further analyze the results from smartctl, and I’m at loss reading this.



If you need to read the raw output, you can get it here on PasteBin.

Please someone, help me T_T

fixing disk permission on OS X

Up till now I don’t know what’s happening on my MacBook. It was slower than before. These were the symptoms

1. Couldn’t quit (it became irresponsive, and I need to Force Quit it)
2. Right-click on Chrome became very laggy.
3. Saggy performance of Finder.
4. Finder read the NTFS Bootcamp drive really slow.
5. Spotlight couldn’t display results other than Dictionary and Web References.
6. Emptying Trash even for small size stuffs brought a progress bar dialog.

@pali7x said that it could be my HDD – wearing off. I was shocked, and I pissed my pants metaphorically. Changing the HDD means money, and moneys mean wallet, wallet means pants, and pants mean….

Cut the chase.

He said that I needed to repair the disk permission via Disk Utility on OS X. Here we go!

repairing disk permission OS X

Repairing. The first attempt it stuck on “Estimated time: 4 minutes”. Maybe because during the process I was playing a 720p anime on MplayerX, with Firefox (dTA) downloading a video of Edward Snowden, and the Chrome was there browsing few pages about the Journaling File System. I stopped it, and made a second attempt. Phew, craps were eased out.

done repairing permission

Tadaa! Culprits were busted by the Disk Utility. I shut my OS X down, and kept it cool for half an hour. After that, I resumed my works and fortunately, everything went almost normal. Almost.

Right now, I’m re-indexing the Spotlight.

[OS X] is not responding

This problem occurred to me early this morning. I tried to Quit this application, but it was hanging and I got to force quite it. I’m no fan of forcing something to shut down. I googled and I found the solution on Apple Support Communities. Since there are no images on that board, so I decided to write one, with pictures. Yeay! *giggles*

Here’s the original guide from the Support Communities.

the original guide

Layman would understanding close to nothing. Get your coffee ready, and read the rest of this article. The first step you need to do is to invoke a command dialogue to reach the folder, which is ridiculously easy.

go to folder

Got it? So, let’s proceed to the next steep, which is also an easy one. After you clicked Go to Folder… a small dialogue box pops up, and enter this:


go library container

And, obviously, click Go. You should reach to a folder which looks the same as this:

mail app

And yes, please Move To Trash everything inside that folder. Don’t worry, next time you open Mail again, the data in that folder are reconstructed, and your preferences on the Mail are gone (nothing gonna change actually. In my case, I just needed to expand the sidebar again. That’s all).  Your linked mail accounts remain intact.

As far as I’m concerned, this problem is caused by the sandbox of the Mail. To be honest, I don’t really know how the sandbox works in OS X and as far as I know, most applications inside OS X (which you download from Apple Store) come with sandbox. To prevent the malware infection I think.


CPU got overheated

Both CPU core temperature shot to 90%. At first, I suspected nothing other than living at the hot climate of the earth’s equator made my CPU went for a sun-bathing. The tip is, if you notice your temperature has gone aflame, you should check the Activity Monitor. Sometimes, there’s a culprit hiding and hogging your resources.

the cpu usage

In my case it was Folding@Home. Few days before I was experimenting with Stanford’s F@H. It turned out I didn’t properly remove it. I only deleted the app’s GUI, but not the core. Hence, the core was running rampantly even though I beheaded the GUI.

FaH is the culprit here

LOL FaH was using 388.5% of the whole CPU resource. Let’s take a closer look at the Activity Monitor.

folding at home core

So, we’ve found the culprit here so what do we do? Easy, go Google-ing and you’ll found the solution. If you installed F@H on your OSX and you wish to remove it, make sure you download the uninstaller here. Extract the zip, run the program and within seconds you’re done.

the cpu temperature back to normal

All is done, and the has gone back to normal. By the way, thanks to iStat Menus for the heat sensor.