executing

> sudo echo 512 > /proc/sys/fs/inotify/max_user_instances

does not work because it won't open the file as root but as your current user. 
This is because "> /proc/sys/fs/inotify/max_user_instances" is not part of what 
sudo executes. The command is interpreted by your shell as follows: open the 
file "/proc/sys/fs/inotify/max_user_instances
" for writing and execute the programm "sudo" with the following arguments 
["echo", "512"] and replace the output(stdout) of the program with said file 
for starting it. Since your shell is not running as root, it cannot open 
"/proc/sys/fs/inotify/max_user_instances" for writing.

You can either get a shell running as root (with "sudo -i" for example),
or do "echo 512 | sudo tee /proc/sys/fs/inotify/max_user_instances". The
2nd way works by passing the output of echo to sudo with in turn will
pass it on to tee which then will open the file, which it can do because
sudo invoked tee as root.

-- 
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to gnome-system-monitor in Ubuntu.
https://bugs.launchpad.net/bugs/1430068

Title:
  Unable to launch gnome-system-monitor

Status in gnome-system-monitor package in Ubuntu:
  Confirmed

Bug description:
  When you have too many open files, you can't launch gnome-system-
  monitor:

   $ gnome-system-monitor

  (gnome-system-monitor:23720): glibmm-CRITICAL **: 
  unhandled exception (type Glib::Error) in signal handler:
  domain: g-io-error-quark
  code  : 0
  what  : Unable to find default local directory monitor type

  
  (gnome-system-monitor:23720): Gtk-CRITICAL **: gtk_window_present_with_time: 
assertion 'GTK_IS_WINDOW (window)' failed

  ProblemType: Bug
  DistroRelease: Ubuntu 14.10
  Package: gnome-system-monitor 3.8.2.1-2ubuntu4
  ProcVersionSignature: Ubuntu 3.16.0-31.41-generic 3.16.7-ckt5
  Uname: Linux 3.16.0-31-generic x86_64
  ApportVersion: 2.14.7-0ubuntu8.2
  Architecture: amd64
  CurrentDesktop: Unity
  Date: Tue Mar 10 09:32:12 2015
  InstallationDate: Installed on 2014-06-26 (255 days ago)
  InstallationMedia: Ubuntu 14.04 LTS "Trusty Tahr" - Release amd64 (20140417)
  SourcePackage: gnome-system-monitor
  UpgradeStatus: Upgraded to utopic on 2014-10-27 (133 days ago)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnome-system-monitor/+bug/1430068/+subscriptions


-- 
Mailing list: https://launchpad.net/~desktop-packages
Post to     : desktop-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~desktop-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to