Search code examples
linuxgrapevine

What's missing from our custom Linux OS that causes "Function not implemented" when building the Grapevine web server?


We are seeing the following trace when attempting to run Grapevine on a custom Linux OS (we don't see this running on Ubuntu 20.04 or Raspberry Pi):

WARNING: System.IO.IOException: Function not implemented
at System.IO.FileSystemWatcher.StartRaisingEvents()
at System.IO.FileSystemWatcher.StartRaisingEventsIfNotDisposed()
at System.IO.FileSystemWatcher.set_EnableRaisingEvents(Boolean value)
at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.TryEnableFileSystemWatcher()
at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.CreateFileChangeToken(String filter)
at Microsoft.Extensions.FileProviders.PhysicalFileProvider.Watch(String filter)
at Microsoft.Extensions.Configuration.FileConfigurationProvider.<.ctor>b__1_0()
at Microsoft.Extensions.Primitives.ChangeToken.ChangeTokenRegistration`1..ctor(Func`1 changeTokenProducer, Action`1 changeTokenConsumer, TState state)
at Microsoft.Extensions.Primitives.ChangeToken.OnChange(Func`1 changeTokenProducer, Action changeTokenConsumer)
at Microsoft.Extensions.Configuration.FileConfigurationProvider..ctor(FileConfigurationSource source)
at Microsoft.Extensions.Configuration.Json.JsonConfigurationProvider..ctor(JsonConfigurationSource source)
at Microsoft.Extensions.Configuration.Json.JsonConfigurationSource.Build(IConfigurationBuilder builder)
at Microsoft.Extensions.Configuration.ConfigurationBuilder.Build()

Clearly we're missing something in our custom OS that dotnet (and Grapevine) depends upon. Can anyone provide a clue on what that might be?

We tried turning off 'Reload on change' per this link:

(Turn `ReloadOnChange` off in config source for WebApplicationFactory)

That didn't do anything for us. By the way, turning off the file system watcher so this exception isn't raised would be an acceptable work-around.


Solution

  • We've found what's missing in our custom Linux! In case you're encountering this issue, make sure you've built "inotify" functionality into your kernel. Inotify Man Page