code: def update(self):
          
          try:
              p = Popen(['/bin/ps', '-p%s' % self.pid, '-o', 'rss,vsz'],
                        stdout=PIPE, stderr=PIPE)
          except OSError: # pragma: no cover
              pass
          else:
              s = p.communicate()[0].split()
              if p.returncode == 0 and len(s) >= 2: # pragma: no branch
                  self.vsz = int(s[-1]) * 1024
                  self.rss = int(s[-2]) * 1024
                  return True
          return False
docs: Get virtual and resident size of current process via 'ps'.
          This should work for MacOS X, Solaris, Linux. Returns true if it was
          successful.