mirror of
https://github.com/abraunegg/onedrive
synced 2024-06-29 10:50:30 +02:00
Update maxInotifyWatches location
* Update maxInotifyWatches location
This commit is contained in:
parent
c44ad963a6
commit
c7cc45d95c
|
@ -526,13 +526,13 @@ int main(string[] cliArgs) {
|
||||||
// Max number of open files /proc/sys/fs/file-max
|
// Max number of open files /proc/sys/fs/file-max
|
||||||
string maxOpenFiles = strip(readText("/proc/sys/fs/file-max"));
|
string maxOpenFiles = strip(readText("/proc/sys/fs/file-max"));
|
||||||
// What is the currently configured maximum inotify watches that can be used
|
// What is the currently configured maximum inotify watches that can be used
|
||||||
// /proc/sys/user/max_inotify_watches
|
// /proc/sys/fs/inotify/max_user_watches
|
||||||
string maxInotifyWatches = strip(readText("/proc/sys/user/max_inotify_watches"));
|
string maxInotifyWatches = strip(readText("/proc/sys/fs/inotify/max_user_watches"));
|
||||||
|
|
||||||
// Start the monitor process
|
// Start the monitor process
|
||||||
log.log("OneDrive synchronisation interval (seconds): ", appConfig.getValueLong("monitor_interval"));
|
log.log("OneDrive synchronisation interval (seconds): ", appConfig.getValueLong("monitor_interval"));
|
||||||
log.vlog("Maximum allowed open files: ", maxOpenFiles);
|
log.vlog("Maximum allowed open files: ", maxOpenFiles);
|
||||||
log.vlog("Maximum allowed inotify watches: ", maxInotifyWatches);
|
log.vlog("Maximum allowed inotify user watches: ", maxInotifyWatches);
|
||||||
|
|
||||||
// Configure the monitor class
|
// Configure the monitor class
|
||||||
Monitor filesystemMonitor = new Monitor(appConfig, selectiveSync);
|
Monitor filesystemMonitor = new Monitor(appConfig, selectiveSync);
|
||||||
|
|
|
@ -199,7 +199,7 @@ final class Monitor {
|
||||||
if (wd < 0) {
|
if (wd < 0) {
|
||||||
if (errno() == ENOSPC) {
|
if (errno() == ENOSPC) {
|
||||||
// Get the current value
|
// Get the current value
|
||||||
ulong maxInotifyWatches = to!int(strip(readText("/proc/sys/user/max_inotify_watches")));
|
ulong maxInotifyWatches = to!int(strip(readText("/proc/sys/fs/inotify/max_user_watches")));
|
||||||
log.log("The user limit on the total number of inotify watches has been reached.");
|
log.log("The user limit on the total number of inotify watches has been reached.");
|
||||||
log.log("Your current limit of inotify watches is: ", maxInotifyWatches);
|
log.log("Your current limit of inotify watches is: ", maxInotifyWatches);
|
||||||
log.log("It is recommended that you change the max number of inotify watches to at least double your existing value.");
|
log.log("It is recommended that you change the max number of inotify watches to at least double your existing value.");
|
||||||
|
|
Loading…
Reference in a new issue