Author Topic: Swap load on startup?  (Read 2737 times)

jason123

  • Full Member
  • ***
  • Posts: 170
    • View Profile
Swap load on startup?
« on: March 15, 2004, 05:05:02 am »
Hey all,

I remember seeing someplace a script to load swap files on startup well, i couldn\'t find it so i decided to ask the ZUG.  How do i load the swap on startup?

I have three swaps -- on /mnt/card/swapfile
                                    /mnt/cf/swapfile
and one in intrnal rom wherever the Memorymanager applet puts it


Suggestions/comments?
SL-5500
Hentges 3.5.4.1
Kingmax 1gb SD
Lexar 1gb CF
Belkin IR Keyboard
Socket 56k Modem CF
Linksys 802.11b CF

Stubear

  • Hero Member
  • *****
  • Posts: 1164
    • View Profile
    • http://
Swap load on startup?
« Reply #1 on: March 15, 2004, 05:55:40 am »
Add them to /etc/fstab and moun them all with swapon -a

You can out the swapon -a command in any rc file that is mounted at boot time but rc.local seems best.

Stu
SL-C1000, Hand converted to English with Japanese Input
Running X apps via X/Qt
iRiver USB host cable; Diatec P-Cord usb power cable (extendable); Acro's Reel Cable USB (A to A, B, Mini-B,  & Mini-B 8pin); GreenHouse 1Gb PicoDrive+; 2x256Mb Hagiwara SD cards; 128Mb Transcend CF card; 512Mb PQI CF card; AmbiCom WL1100C-CF 11B WLAN card

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Swap load on startup?
« Reply #2 on: March 15, 2004, 10:41:22 am »
Add the following to /etc/fstab

/mnt/cf/swapfile swap swap defaults

for each of your swap file.

havoc

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
    • http://www.galacticslacker.com/
Swap load on startup?
« Reply #3 on: March 16, 2004, 12:38:56 pm »
You can pick out the deatails you need here:
http://www.galacticslacker.com/perl-bin/re...20card&expand=3

You can also grab a copy of my /etc/initd.d/swap script here:
http://www.galacticslacker.com/perl-bin/re...message=513#513

Let me know if stuff needs clarifying.

havoc

jason123

  • Full Member
  • ***
  • Posts: 170
    • View Profile
Swap load on startup?
« Reply #4 on: March 17, 2004, 01:33:52 pm »
I\'m already lost ...  umm ... yeah I\'ve never turned a swap on from the command line so i don\'t know thee commands for it -- i stuck \"swapon -a /mnt/cf/swapfile\" into my rc.local ...  I stuck \"/mnt/cf/swapfile swap swap defaults\"  into my /etc/fstab as well but umm nothing really happened so i\'m confused.
SL-5500
Hentges 3.5.4.1
Kingmax 1gb SD
Lexar 1gb CF
Belkin IR Keyboard
Socket 56k Modem CF
Linksys 802.11b CF

Stubear

  • Hero Member
  • *****
  • Posts: 1164
    • View Profile
    • http://
Swap load on startup?
« Reply #5 on: March 17, 2004, 09:13:41 pm »
Ahh, looks like you need to uncomment thel ines in rc or rc.init that turn on rc.local - it\'s not used by default (at least not on the C760).

Take a look at the lniks havoc posted they will do what you want.

Stu
SL-C1000, Hand converted to English with Japanese Input
Running X apps via X/Qt
iRiver USB host cable; Diatec P-Cord usb power cable (extendable); Acro's Reel Cable USB (A to A, B, Mini-B,  & Mini-B 8pin); GreenHouse 1Gb PicoDrive+; 2x256Mb Hagiwara SD cards; 128Mb Transcend CF card; 512Mb PQI CF card; AmbiCom WL1100C-CF 11B WLAN card