Quote:
Originally Posted by Nishanth1829
Is my way correct?
|
I don't think we can answer this question, since we know too little of your program. Questions I have:
Are you writing to the storage device directly, or to a filesystem on the storage device?
What do you mean by "busy" and how do you know it is busy?
Are there relevant kernel messages?
Quote:
If not kindly help me with how to copy a folder from internal memory to pendrive without making the volume busy.
|
I would put a filesystem on the pendrive. FAT has the advantage that you can read the drive on other OSs than Linux. ext4 has the advantage of supporting the Linux permissions concept.
Then mount the pendrive to a directory and just copy. To ensure you mount the correct device and avoid confusion between sda and sdb, use the filesystem's UUID for mounting or create a label and use that.