swap space
- This topic has 4 replies, 2 voices, and was last updated 13 years ago by .
Viewing 5 posts - 1 through 5 (of 5 total)
Viewing 5 posts - 1 through 5 (of 5 total)
- You must be logged in to reply to this topic.
Home › Forums › MultiConnect OCG › swap space
Is there any swapping done on the CDP? I don’t have a firm grasp on swapping in general but I know that the programs I am using right now are using a lot of memory and I believe adding some swap space might help. I am receiving a lot of low memory kernel warnings in the sys log. Would it be possible to partition the root disk to provide swapping? or possibly the sdcard? Or is this a dumb question? 🙂
You can technically enable swapping, but I would definitely NOT do this with the root device (NAND flash). It will be very very slow and will wear out the flash part much faster.
You could investigate trying to use the SD card for this purpose. It will be much easier to setup and it should work just fine, but again, it will be slow (it’s no hard drive).
OK, I created a swap partition on the sd card and tried using it but I get:
# swapon /dev/mmcblk0p2
swapon: /dev/mmcblk0p2: Function not implemented
It appears swap functionality is not enabled in the kernel. So I edited openembedded/recipes/linux/linux-2.6.32/mtcdp/defconfig and added:
CONFIG_SWAP=y
I then did ‘bitbake linux’ (after upping the revision number) and the built my image. After flashing I get the same error message though. I think I missed a step somewhere…how do I pick up changes to the kernel config and re-build it?
Hm, sounds like you did the right thing. If you modified defconfig, and then increased “PR” in the linux_2.6.32.bb and ran ‘bitbake linux’, it should have built a new kernel with your updated config.
The image should be at build/tmp/deploy/glibc/images/mtcdp/uImage-mtcdp.bin.
You can verify that your defconfig change took effect by looking in the work directory. Assuming you increased PR to ‘9’, it should be in
build/tmp/work/mtcdp-corecdp-linux-gnueabi/linux-2.6.32-r9
OK, I did get it to work…not sure what happened but my change to the defconfig wasn’t there (in the source defconfig, and in the built version)…went back and added it back in and now it is working
thanks