2

is there a way, solution for a Linux server (SLES) to put write (or even read) caching in RAM?

Having big RAM, ex.: 2 TBytes, but limited NFS IOPS and we need a big IOPS for DB files, stored on NFS.

jim7475
  • 51
  • 2
  • 1
    I would suggest that you take a look at Db and state there the original issue. instead using a workaround. if you need to use multiple servers then imho mostly a direct Synchronisation between the instance would reduce the number of Iops – djdomi Sep 01 '22 at 17:29

1 Answers1

4

Reads are automatically cached both client-size and server-side.

Writes can be cached client-side by mounting the NFS share with the async option, at the cost of potentially losing data in case of an unexpected client reboot. Note that important writes, the one done via sync/fsync(), are unaffected by this client option (ie: they are guaranteed to be transferred to the server before returning).

Server-side, exporting the share with the async option means to discard fsync() altogether, which can significantly increase write ops but at the (very real) risk of data corruption if/when an unexpected power loss happens.

shodanshok
  • 47,711
  • 7
  • 111
  • 180