Tiny Core Linux

Tiny Core Base => TCB Tips & Tricks => Topic started by: sam.vanratt on March 20, 2012, 02:51:15 PM

Title: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 20, 2012, 02:51:15 PM
Hello
I'm currently on my way to get TC4.4 running on my Libretto 100CT (8GB SSD, 64MB RAM, 1,5MB VGA RAM, P166MMX).
Two issues:
a) as OnBoot (as OnDemand works only partly via ssh or busybox) consumes a lot of ram just to be installed (after gcc, alsa, mplayer, my RAM is full) is the boot switch "local=sda2" my way into a traditional installation (meaning, files loaded from disk, no loopback, no reset, no backup)? And is it possible to say local=sda2/whatever ?
b) under NT4 I get the disk running in MWDMA2 mode (the max what the Libretto controller support), in FreeBSD the kernel choses PIO4 and only after atacontrol is initialized it choses MWDMA2, in TC (I guess Linux in generell) I get only PIO1 working which is a bit slow on a 95MB/s SSD; 16 would be nice... When using hdparm I get an error while applying -d=1 saying it's not supported by the device and -p=4 (afair) says the same to my /dev/sda. Any hints?
Cheers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: gerald_clark on March 20, 2012, 03:43:44 PM
http://wiki.tinycorelinux.net/wiki:backup_hd

Running root from hard drive is not supported.
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: AbNoRMiS on March 20, 2012, 08:19:29 PM
a) maybe better try oss instead alsa to reduce memory usage and move gcc to ondemand?
b) can try booting with libata.force=1.00:mwdma2 kernel parameter (see here (http://lkml.indiana.edu/hypermail/linux/kernel/0904.2/03739.html) and kernel params (http://kernel.org/doc/Documentation/kernel-parameters.txt))
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: V.Krishn on March 20, 2012, 09:44:26 PM
Just wondering if having this feature http://forum.tinycorelinux.net/index.php/topic,12856.msg70508.html could solve onboot issue?
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: curaga on March 21, 2012, 06:48:12 AM
Unionfs is not a magic bullet for ram use, IIRC it did not differ much from symlinks.
Even worse, when unionfs runs out of ram, you don't get an "out of ram" message, you get an oops...
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: hiro on March 21, 2012, 07:20:45 AM
Well, the symlinks don't take *that* much space anyway. Could it be the overhead of squashfs caches?
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: AbNoRMiS on March 21, 2012, 08:21:58 AM
i also think that need to allocate some ssd space for swap
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 21, 2012, 01:57:59 PM
Just wondering if having this feature http://forum.tinycorelinux.net/index.php/topic,12856.msg70508.html could solve onboot issue?


Hi
maybe; I'm quite used (and forced) to a traditional /usr folder and unpacked drivers/bins/...
I'm not into onionFS, so I'd not been able to integrate it into my system.
Cheers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 21, 2012, 01:59:59 PM
http://wiki.tinycorelinux.net/wiki:backup_hd

Running root from hard drive is not supported.

Hi
I'm aware of it, but a /usr would suffice for most of my needs. I'm willing to install about 20-30 Apps, sizing from 1MB-50MB; loopbacks cost lots of my dear RAM...
Cheers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 21, 2012, 02:06:06 PM
i also think that need to allocate some ssd space for swap

Hi
I already have 160MB on a special Swap Partion, just to be able to start; when ALSA is installed "onboot" I'm nearly out of memory (I'll going to OSS as I did in my FreeBSD Disk); X would take the rest. Even when I'm willing to sacrifice X or ALSA, or Browser: it would be fine to have a stationary folder for emacs, mplayer, mpg123, gcc, ddrescue, openssh, which do not need real performance (for MP3/OGG/FLAC decompression) but do not consume too much RAM.
Cheers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: gerald_clark on March 21, 2012, 02:17:36 PM
Make sure you don't have the copy2fs.flg file in your tce directory.
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 26, 2012, 06:32:41 AM
http://wiki.tinycorelinux.net/wiki:backup_hd

Running root from hard drive is not supported.

Hi Gerald
is it possible to inject files to the /usr/.... folders, including 'em into the filelist and then having user apps like mplayer, ... ready after a reboot? I'm not  so far into the mechanismn of TCL and it's filehandling (Ondemand); I want to get rid of alsa's (File=RAM) size (and others). What are the drawbacks of inflicting into the clear way of TCL's App Handling?
CHeers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 26, 2012, 06:37:44 AM
a) maybe better try oss instead alsa to reduce memory usage and move gcc to ondemand?
b) can try booting with libata.force=1.00:mwdma2 kernel parameter (see here (http://lkml.indiana.edu/hypermail/linux/kernel/0904.2/03739.html) and kernel params (http://kernel.org/doc/Documentation/kernel-parameters.txt))

That worked well; I was amiss with the exact syntax as the bootlist is quite generic.
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: hiro on March 26, 2012, 06:39:02 AM
He's not saying it's not possible, just that it is not supported. The same applies to your current question.
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: AbNoRMiS on March 26, 2012, 07:02:57 AM
i don't quite understand so libata.force kernel parameter is works or not?
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on March 26, 2012, 08:40:34 AM
Hi AbNoRMiS
yes the parameter (=libata.force=1.00:mwdma2) worked as promised. Now it's running in MWDMA2 and not PIO4 as before.
Cheers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: AbNoRMiS on March 26, 2012, 08:45:06 AM
make onboot.lst like this
Code: [Select]
Xvesa.tcz
Xprogs.tcz
jwm.tcz
wbar.tcz
OSS.tcz
immediately after system boot with these configuration will employ about 20mb memory
all further extensions such as mplayer, browser etc can install as ondemand
and they will not take time during boot and not take memory until start them
and you do not have to include usr folder to backup
all current data of these extensions are written in home folder
and will be backed up during reboot and will be ready after reboot
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on April 03, 2012, 11:14:28 AM
Hello Abnormis
my list is quite small bu I need samba at startup to connect my CIFS shares via fstab and ALSA; a few OnDeamnd I tested only works when installed Onboot as well. I'm still on a workaround to install statically usually used programms.
Currently I'm out of time
Cheers
Sam
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: Rich on April 03, 2012, 11:24:09 AM
Hi sam.vanratt
Are you looking to share files or access files on another machine? If you just want to access files on another
machine,  cifs-utils.tcz  will do that.
Title: Re: TC4.4 in low RAM Mode and hdparm DMA
Post by: sam.vanratt on April 04, 2012, 12:52:45 PM
Hi Rich
if I can use mount.cifs (via fstab) that's enough and should significantly lower the RAM usage. I'll try it in about a week or so and report back
Cheers
Sam