Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

speeding up disk-based laptop by moving /usr to flash?



On 12/2/2009 11:43 PM, Brendan Kidwell wrote:
> On Wed, Dec 2, 2009 at 7:51 AM, Jerry Feldman<gaf-mNDKBlG2WHs at public.gmane.org>  wrote:
>
>> I don't think that would affect performance, and may even hurt
>> performance. Remember that when Linux loads a program or a shared
>> library, the location of that program or shared object effectively
>> becomes part of swap. The program and its dependent shared libraries are
>> mapped into memory, but only loaded into pages when needed.
>>
>
> I'm not convinced that it wouldn't improve performance. Consider starting up
> OpenOffice.org (everyone's favorite gigantic application). A huge pile of
> executables and SOs get memory mapped and lots and lots of pages in those
> get randomly read and executed. On a filesystem that has a very low seek
> time, all things being equal, it should perform better than a typical disk,
> and streaming throughput would be of secondary concern I think. But all
> things are equal only in high school physics problems.
>
> The only way to really answer the question is to backup the whole system and
> start reconfiguring and testing it.
>
> Tom's suggestion of ZFS's demand-sensitive selective striping or some more
> generic solution involving a Linux filesystem seems attractive as well. I'd
> love it if I could find a good Linux based "ReadyBoost"-like flash-aware
> cache module.
>
> Lifehacker actually suggests mounting /dev/your-flash-memory as a secondary
> swap device. I don't see how that'll do any good unless you have far too
> little RAM. Doesn't swap get cleared whenever you shut down, so you have no
> accumulated effect of keeping often-used objects in cache? And don't memory
> mapped files like executables NEVER get loaded into swap, since in this case
> the RAM is just shadowing sectors of storage?
>
> What I would do is to look at possibly replacing the X41 since prices
>> are now very low. Most new laptops today are built for Windows 7 which
>> requires more memory so those laptops have more memory builtin.
>>
>
> At this point I don't think any replacement I'd be happy with would be in my
> price range. And also, for reference, my motherboard is apparently already
> maxed out with 1.5GB of RAM.

I don't think the RAMdisk idea would do much good. Linux already uses 
any RAM that isn't otherwise in use as a disk cache; setting aside space 
for a RAMdisk would take away from the size of the cache, so you would 
just be replacing a flexible and dynamically allocated resource with a 
less flexible, statically allocated one.

A disk cache in flash memory might help. Even Microsoft thought it was a 
good idea for a while -- ReadyBoost -- though their implementation 
doesn't seem to work very well.

As for swap, the first question to ask is whether any existing swap 
space is even getting used. Typically on my Linux systems with 2-4GB of 
RAM the swap space never gets touched or used in only some token amount.

If you do decide to give some flash a try, make sure that the memory 
that you use is fast enough to help. I tried out one of the 16GB "133x" 
Kingston CF cards (the ones that MicroCenter sold for a while) in my 
Zaurus and it was painfully slow; I couldn't get smooth playback of MP3 
files from it although other CF cards had no trouble, and writing to it 
was slower than to my older Lexar CF cards. It went back to the store.






BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!



Boston Linux & Unix / webmaster@blu.org