Skip to content

LORDLYAMIGO/RemProcMon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Remote Process Monitor

Real-time distributed process monitoring system for Windows with centralized data collection and visualization.

Table of Contents


Overview

Monitor process-level metrics (CPU, Memory, PID) across multiple Windows computers in real-time. Data is collected by PowerShell clients, stored in PostgreSQL, and visualized in a React dashboard.

Key Features:

  • Real-time process monitoring across multiple machines
  • Dual database system (live + historical data)
  • Web dashboard with statistics and live feed
  • API key authentication

Architecture

Components:

  • PowerShell Clients: Collect process data every 2 seconds from Windows machines
  • Node.js Server: REST API + WebSocket server, manages data and broadcasts updates
  • PostgreSQL: Two databases (live: 5-min retention, logs: permanent storage)
  • React Dashboard: View statistics and live process feed

Data Flow:

Client → Server (HTTP POST) → PostgreSQL (Live + Logs) → Dashboard (WebSocket)

Quick Start

Prerequisites:

  • Node.js 18+
  • PostgreSQL 14+
  • PowerShell 7+ (for clients)

Setup:

# 1. Setup databases
.\setup-databases.ps1

# 2. Configure and start server
cd server
cp .env.example .env
# Edit .env (set database password and API key)
npm install
npm start

# 3. Configure and start dashboard
cd dashboard
cp .env.example .env
# Edit .env (set API URL and key)
npm install
npm start

# 4. Run client on monitored machines
cd client
# Edit config.json (set server URL and API key)
.\monitor.ps1

Dashboard: http://localhost:3000


Installation

1. Database Setup

Run as Administrator:

.\setup-databases.ps1

Or manually:

psql -U postgres -d proc_monitor_live -f database/migrations/001_create_live_db.sql
psql -U postgres -d proc_monitor_logs -f database/migrations/002_create_log_db.sql

2. Server Setup

cd server
npm install
cp .env.example .env
# Edit .env: set API_KEY and LIVE_DB_PASSWORD, LOG_DB_PASSWORD
npm start

3. Dashboard Setup

cd dashboard
npm install
cp .env.example .env
# Edit .env: set REACT_APP_API_URL and REACT_APP_API_KEY
npm start

4. Client Setup

cd client
# Edit config.json: set serverUrl and apiKey
.\monitor.ps1

Configuration

Server (server/.env)

API_KEY=your_secret_api_key_here
LIVE_DB_PASSWORD=your_postgres_password
LOG_DB_PASSWORD=your_postgres_password
PORT=3001

Dashboard (dashboard/.env)

REACT_APP_API_URL=http://localhost:3001
REACT_APP_WS_URL=http://localhost:3001
REACT_APP_API_KEY=your_secret_api_key_here

Client (client/config.json)

{
  "serverUrl": "http://your-server-ip:3001",
  "apiKey": "your_secret_api_key_here",
  "pollIntervalSeconds": 2
}

Usage

Start Server:

cd server && npm start

Start Dashboard:

cd dashboard && npm start
# Access at http://localhost:3000

Run Client (on monitored machines):

cd client
.\monitor.ps1

# Options:
.\monitor.ps1 -TestConnection  # Test server connection
.\monitor.ps1 -Debug           # Show detailed logs

Dashboard:

  • Overview Tab: Statistics, pie charts, top users
  • Live Feed Tab: Real-time process table with search/filter

License

MIT License - see LICENSE file for details.

Author: Srijan
Version: 1.0.0

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published