Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Compcache: Use compressed ram as fast swap.
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
NotQuiteSane
Guru
Guru


Joined: 30 Jan 2005
Posts: 488
Location: Klamath Falls, Jefferson, USA, North America, Midgarth

PostPosted: Tue Sep 02, 2008 4:04 am    Post subject: Reply with quote

I'm having some trouble with the script.

I patched the kernel, and can sucessfully load all required modules.

however when i do

Code:
pixel# ./use_compcache.sh 774144


i see:

Code:
pixel# swapon -s
Filename                                Type            Size    Used    Priority
/dev/hda2                               partition       2008116 0       -3
/dev/hda3                               partition       2008116 0       -4
/dev/ramzswap0                          partition       258704  0       100
pixel#


I seem to be only activating the default amount. goal is 756mb. any suggestions?

NQS
_________________
These opinions are mine, mine I say! Piss off and get your own.

As I see it -- An irregular blog, Improved with new location

To delete French language packs from system use 'sudo rm -fr /'
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 2995
Location: Bay Area, CA

PostPosted: Tue Sep 02, 2008 4:58 am    Post subject: Reply with quote

NotQuiteSane wrote:
I'm having some trouble with the script.

I patched the kernel, and can sucessfully load all required modules.

however when i do

Code:
pixel# ./use_compcache.sh 774144


i see:

Code:
pixel# swapon -s
Filename                                Type            Size    Used    Priority
/dev/hda2                               partition       2008116 0       -3
/dev/hda3                               partition       2008116 0       -4
/dev/ramzswap0                          partition       258704  0       100
pixel#


I seem to be only activating the default amount. goal is 756mb. any suggestions?

NQS
By the time you run ./use_compcache.sh 774144, you have already 'modprobe'd the compcache module. Do: swapoff /dev/ramzswap0 && rmmod compcache && ./use_compcache.sh 774144
Back to top
View user's profile Send private message
NotQuiteSane
Guru
Guru


Joined: 30 Jan 2005
Posts: 488
Location: Klamath Falls, Jefferson, USA, North America, Midgarth

PostPosted: Tue Sep 02, 2008 4:41 pm    Post subject: Reply with quote

devsk wrote:
By the time you run ./use_compcache.sh 774144, you have already 'modprobe'd the compcache module. Do: swapoff /dev/ramzswap0 && rmmod compcache && ./use_compcache.sh 774144


doing that gives:

Code:
pixel# swapoff /dev/ramzswap0 && rmmod compcache && /home/nqs/Desktop/compcache-0.4/use_compcache.sh 774144
Loading modules ...
Module: tlsf already loaded.
Module: compcache not found in current directory
Setting up swap device ...
swapon: cannot stat /dev/ramzswap0: No such file or directory
Could not add compcache swap device.
pixel#


i'm running from /home/nqs. once i can get it all going, i'll move the script to a more standard location.

system info:
Code:
pixel# uname -a
Linux pixel 2.6.26-tuxonice1sep08-2 #5 Mon Sep 1 21:39:21 PDT 2008 i686 Intel(R) Pentium(R) M processor 1.86GHz GenuineIntel GNU/Linux
pixel#


Code:
pixel# emerge --info
Portage 2.2_rc8 (default-linux/x86/2007.0, gcc-4.3.1, glibc-2.6.1-r0, 2.6.26-tuxonice1sep08-2 i686)
=================================================================
System uname: Linux-2.6.26-tuxonice1sep08-2-i686-Intel-R-_Pentium-R-_M_processor_1.86GHz-with-glibc2.0
Timestamp of tree: Mon, 01 Sep 2008 15:15:02 +0000
app-shells/bash:     3.2_p33
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.5.2-r6
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 2.0.0
sys-apps/openrc:     9999
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r2
sys-devel/automake:  1.4_p6, 1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.23-r3
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-Os -march=pentium-m -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-Os -march=pentium-m -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks parallel-fetch preserve-libs sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://gentoo.osuosl.org/ ftp://ftp.ucsb.edu/pub/mirrors/linux/gentoo/ http://ftp.ucsb.edu/pub/mirrors/linux/gentoo/ http://mirror.usu.edu/mirrors/gentoo/ ftp://ftp.wallawalla.edu/pub/mirrors/ftp.gentoo.org "
LANG="C"
LDFLAGS=""
LINGUAS="en"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_EXTRA_OPTS="--exclude-from=/etc/portage/package.exclude"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="nls pam x86" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1   emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m       maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en" USERLAND="GNU" VIDEO_CARDS="vesa vga radeon"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTDIR_OVERLAY

pixel#


nqs
_________________
These opinions are mine, mine I say! Piss off and get your own.

As I see it -- An irregular blog, Improved with new location

To delete French language packs from system use 'sudo rm -fr /'
Back to top
View user's profile Send private message
NotQuiteSane
Guru
Guru


Joined: 30 Jan 2005
Posts: 488
Location: Klamath Falls, Jefferson, USA, North America, Midgarth

PostPosted: Tue Sep 02, 2008 5:27 pm    Post subject: Reply with quote

ok, i fixed it, sort of. problem is it only works with this kernel:

Code:
pixel# ln -s /lib/modules/2.6.26-tuxonice1sep08-2/kernel/drivers/block/compcache.ko compcache.ko



i now see 753 mb ram. close enough to 756 to not matter.

oh, and you can turn off the swap, and format a ramdisk. once i get another GB ram i'll be doing that in conjunction with this trick

NQS
_________________
These opinions are mine, mine I say! Piss off and get your own.

As I see it -- An irregular blog, Improved with new location

To delete French language packs from system use 'sudo rm -fr /'
Back to top
View user's profile Send private message
ConnClark
n00b
n00b


Joined: 15 Aug 2007
Posts: 57

PostPosted: Fri Sep 12, 2008 4:13 pm    Post subject: Reply with quote

When I was playing around with CFD code I tried using video ram as a fast swap file before. I wonder what the possibilities are of using this in conjunction with that trick.

I had a machine with 2 gigs of ram and I was using 124 megs of video ram as a fast swap file. On simulation where I was using 6 gigs of swap the improvement was not measurable. On a simulation that required 4 gigs of swap I could measure a speed up of about 5 to 10%.

I have to wonder if this would increase the effective ratio of the video ram to disk swap space to yield a measurable improvement?
_________________
In formal computer science advances are made by standing on the shoulders of giants. Linux has shown that, if there are enough of you, you can advance just as far by stepping on each others toes.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum