Where can I store data as a System Service?

84 Views Asked by At

I programmed a system-service and it tries to create a directory to save some data. The dir that I chose was /.myServiceData. When I try to run it I get this error: mkdir /.ethNode: read-only file system.

Where can I store my data in the system-service on android?

-UPDATE: I now tried to getFilesDir() in the system-service, and it also throws an error:

Caused by: java.lang.RuntimeException: No data directory found for package android
0

There are 0 best solutions below