Skip to main content

Uses psutil to observe/log processes during a certain time

Project description

Uses psutil to observe/log processes during a certain time

pip install procobserver

from procobserver import observe_procs

df = observe_procs(

    executables=("Vpn.exe",), # list or tuple of exe files (not the whole path!)

    pids=(5800, 18166), # list or tuple of pids 

    pickle_output_path="f:\\picklefileobj.pkl", # If None, nothing will be saved to your HDD 

    sleeptime=0.2, # sleep between each scan 

	timeout=30, # If timeout is None, you have to press ctrl+c 

)

# Press ctrl+c to stop the observation

Out[2]: '\n^CStopping observation ...

df

Out[3]: 

0 num_handles  ...  aa_localtime

0         484  ...  1.678241e+09

1         604  ...  1.678241e+09

2         870  ...  1.678241e+09

3        1336  ...  1.678241e+09

4         419  ...  1.678241e+09

5         484  ...  1.678241e+09

6         604  ...  1.678241e+09

7         870  ...  1.678241e+09

8        1336  ...  1.678241e+09

9         419  ...  1.678241e+09

[10 rows x 28 columns]

Project details


Release history Release notifications | RSS feed

This version

0.10

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

procobserver-0.10.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

procobserver-0.10-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file procobserver-0.10.tar.gz.

File metadata

  • Download URL: procobserver-0.10.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for procobserver-0.10.tar.gz
Algorithm Hash digest
SHA256 d5992f0cb945a1ad08ac7a6ac9fea3ae6b16ec6d8620e804148de20b78ff6df5
MD5 4dd15c3393caa643060c8d13e2aa11b8
BLAKE2b-256 a88bb7d604a39cfb1497af8557479735902356402da4a431c73f17ae0bd4345e

See more details on using hashes here.

File details

Details for the file procobserver-0.10-py3-none-any.whl.

File metadata

  • Download URL: procobserver-0.10-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for procobserver-0.10-py3-none-any.whl
Algorithm Hash digest
SHA256 768d9a242302404fa79fc0d29f555a1808c2df4ef0e87b8049379272fae93106
MD5 1788b8a7f0c600fb538f78894b52f209
BLAKE2b-256 7a8798e0d44bcacec89a07d0b793cb25046a65b427054ef5f8a218c68dea3e1e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page