# Read and write a text folder from an app

**URL:** <https://mangoh.discourse.group/t/read-and-write-a-text-folder-from-an-app/6040>\
**Category:** Uncategorized\
**Created:** [January 20, 2021, 2:20pm UTC](https://mangoh.discourse.group/t/read-and-write-a-text-folder-from-an-app/6040 "2021-01-20T14:20:10Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pierrecloury](https://avatars.discourse-cdn.com/v4/letter/p/43a26b/32.png) [@pierrecloury](https://mangoh.discourse.group/u/pierrecloury)\
**Post date:** [January 20, 2021, 2:20pm UTC](https://mangoh.discourse.group/t/read-and-write-a-text-folder-from-an-app/6040/1 "2021-01-20T14:20:10Z")

</div>

Hi,  
We are currently trying to read and write a text folder from an app but each time we try to read ( or write), we have this error :

Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | PROCESS: 6184 ,TID 6184  
Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | SIGNAL: 11, ADDR (nil), AT 0xb6cfd804 SI\_CODE 0x00000001  
Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | ILLEGAL ADDRESS (nil)  
Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | LEGATO VERSION  
Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | PROCESS COMMAND LINE  
Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | PROCESS MAP  
Jan 20 14:24:58 swi-mdm9x28-wp user.err Legato: =ERR= | smsReceiver[6184] | BACKTRACE

here is what i add on the adef folder to be able to modify the text folder i created with vi :

sandboxed: false  
requires:  
{  
file:  
{  
[rw] /home/coordinates/coordinates.txt  
}  
}

Can you describe in details the procedure to be able to modify a text folder from an app ?  
Thx in advance,  
Pierre

---

<div class="post-metadata">

**Author:** ![jyijyi](https://sea2.discourse-cdn.com/flex016/user_avatar/mangoh.discourse.group/jyijyi/32/997_2.png) [@jyijyi](https://mangoh.discourse.group/u/jyijyi)\
**Post date:** [January 20, 2021, 2:25pm UTC](https://mangoh.discourse.group/t/read-and-write-a-text-folder-from-an-app/6040/2 "2021-01-20T14:25:32Z")

</div>

You can see here

> **[How to write data to a file outside sandbox](https://forum.legato.io/t/how-to-write-data-to-a-file-outside-sandbox/246/12)**
>
> Hi Alegato, Could you please elaborate your answer a bit more? I’ve tried to create file outside sandbox and give app access to it in adef file, but it still says that my file is read only

Also you can see this

> **[App access to /tmp](https://forum.legato.io/t/app-access-to-tmp/3480)**
>
> Hiya, Is it possible for an app to get read and write access to the /tmp directory to store intermediate and volatile data files? I’ve tried require:'ing the /tmp directory into my app in the adef file - both as sandboxed and unsandboxed. I’ve...
