Score:0

Very slow experience with Students + NFS + Development tools

ua flag

I teach programming to students in a school where they can all login to any computer; their session files being carried by a common NFS server. We experience very slow execution times when we use demanding tools (namely VSCode, Android Studio or other frameworks like Symfony or React). Asking the students to work in local directory like /tmp is a good workaround but kind of sad as well.

I am not sysadmin but I would love some insights about what could go wrong here:

  1. Are there common pitfalls that we need to check when it comes to sharing session files on NFS?
  2. Consider we have about 100 students working simultaneously, my understanding is that the performance of the upstream SSD will be highly divided anyway, so do you consider this kind of architecture viable?
  3. For many other reasons, I suggest we switch them to laptops, if you take the cost aspects appart, is it more reasonable choice?
ng flag
One thing that may bite you, is that NFS doesn't do inotity, so watching for changes in files has to use a slower method. I don't know how vscode deals with that.
Juan avatar
in flag
Have you considered having them checkout out their files to a local machine using a distributed revision control system, like git? Then they can check their files into the central server as necessary. I think a local mounted disk like `/tmp` would be reasonable in this situation.
Score:0
ca flag

Giving answers to your questions requires a deeper understanding of your workload and bottleneck. So as a first step you should profile your NFS server to understand which kind of load it faces and why it slow down.

Without such information, I can provide only general advice:

  • the applications you described (eg: Android Studio) use many tiny files. This access pattern can be very sensitive to metadata overhead, so you should explore the various data and metadata caching facility of NFS client (ie: ac). Anyway, be sure to read and understand how caching and other optimizations can affect data coherency by reading the nfs man page
  • to more easily absorb random writes you can explore the async NFS server option, at least for some testing. Be aware that this can lead to data loss, so be sure to understand its implications. Again, please read the relevant man page
  • during high load, use iostat -x to check your server disks utilization and latency. Maybe you are "just" short of hardware resources

Anyway, high-performance NFS is not a simple setup by any means. You probably need a skilled sysadmin if you want such a setup to perform well.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.