Running out of CF disk space - Embedded

This is a discussion on Running out of CF disk space - Embedded ; I 'm working on a CPCI board with Slackware-10.2 linux installed on a 1GB Compact Flash . I tried to use the CF as a hard disk and didn't make any ramdisk file system . I wrote a kernel module ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: Running out of CF disk space

  1. Running out of CF disk space

    I 'm working on a CPCI board with Slackware-10.2 linux installed
    on a 1GB Compact Flash . I tried to use the CF as a hard disk and
    didn't make any ramdisk file system .
    I wrote a kernel module as device driver of an fpga on another board .
    When I insert and run the kernel module to do pci dma for 100 K
    times -each time 80 Kbytes is transferred - then remove the module
    ,the CF diskspace is decreasing about 300Kbytes ?
    Where should I look , actually I'm opening the device and dont ' close
    it but I 'm removing the module ?


  2. Re: Running out of CF disk space

    Hello,

    > I 'm working on a CPCI board with Slackware-10.2 linux installed
    > on a 1GB Compact Flash . I tried to use the CF as a hard disk and
    > didn't make any ramdisk file system .
    > I wrote a kernel module as device driver of an fpga on another board .
    > When I insert and run the kernel module to do pci dma for 100 K
    > times -each time 80 Kbytes is transferred - then remove the module
    > ,the CF diskspace is decreasing about 300Kbytes ?
    > Where should I look , actually I'm opening the device and dont ' close
    > it but I 'm removing the module ?


    If I'm not mistaken, the module will not be removed if there is any
    activity.
    In hope that the activity will stop, the module will be removed for further
    accesses, but the ongoing ones are able to finish (to prevent data loss).
    You should close your device first.

    May be I understood you wrong, but why don't you close the module?

    Regards



  3. Re: Running out of CF disk space

    I found that a file is getting bigger and bigger, /var/logs/syslog
    360Mbytes.
    I have about ten printk lines in kernel module an each line is about
    20 characters .When I run it in loop 100K times 200 *100K =20Mbytes
    message is logged into syslog . This is the explanation of running out
    of CF disk space.

    Sebastian yazdi:
    > Hello,
    >
    > > I 'm working on a CPCI board with Slackware-10.2 linux installed
    > > on a 1GB Compact Flash . I tried to use the CF as a hard disk and
    > > didn't make any ramdisk file system .
    > > I wrote a kernel module as device driver of an fpga on another board .
    > > When I insert and run the kernel module to do pci dma for 100 K
    > > times -each time 80 Kbytes is transferred - then remove the module
    > > ,the CF diskspace is decreasing about 300Kbytes ?
    > > Where should I look , actually I'm opening the device and dont ' close
    > > it but I 'm removing the module ?

    >
    > If I'm not mistaken, the module will not be removed if there is any
    > activity.
    > In hope that the activity will stop, the module will be removed for further
    > accesses, but the ongoing ones are able to finish (to prevent data loss).
    > You should close your device first.
    >
    > May be I understood you wrong, but why don't you close the module?
    >
    > Regards



  4. Re: Running out of CF disk space

    istakoz2000@yahoo.com wrote:

    > I found that a file is getting bigger and bigger, /var/logs/syslog
    > 360Mbytes.
    > I have about ten printk lines in kernel module an each line is about
    > 20 characters .When I run it in loop 100K times 200 *100K =20Mbytes
    > message is logged into syslog . This is the explanation of running out
    > of CF disk space.
    >


    You should on embedded systems start a ramdisk anyway because the system
    will crash after a certain time anyway because of your /tmp directory (too
    many write operations). Although cf disks can have lots of write
    operations, linux can easily reach this number.
    Perhaps a solution for your module /var/log problem: Remove all these printk
    statements and use a fifo device for debugging. In user space you open this
    device and read the strings
    taco

    > Sebastian yazdi:
    >> Hello,
    >>
    >> > I 'm working on a CPCI board with Slackware-10.2 linux installed
    >> > on a 1GB Compact Flash . I tried to use the CF as a hard disk and
    >> > didn't make any ramdisk file system .
    >> > I wrote a kernel module as device driver of an fpga on another board .
    >> > When I insert and run the kernel module to do pci dma for 100 K
    >> > times -each time 80 Kbytes is transferred - then remove the module
    >> > ,the CF diskspace is decreasing about 300Kbytes ?
    >> > Where should I look , actually I'm opening the device and dont ' close
    >> > it but I 'm removing the module ?

    >>
    >> If I'm not mistaken, the module will not be removed if there is any
    >> activity.
    >> In hope that the activity will stop, the module will be removed for
    >> further accesses, but the ongoing ones are able to finish (to prevent
    >> data loss). You should close your device first.
    >>
    >> May be I understood you wrong, but why don't you close the module?
    >>
    >> Regards



+ Reply to Thread