ServerHub Setup Guide
Monitor and manage your servers with ease
Getting Started
-
1
Download the ServerHub App
Install the app from the official source to get started with your monitoring setup.
-
2
Create Your Connect Key
Generate your unique Connect Key in the app to link your servers securely.
-
3
Connect to Your Server
Connect to the server you want to monitor via SSH to prepare for agent installation.
-
4
Install the ServerHub Agent
Choose one of the installation methods below to complete your setup.
Interactive Installation (Recommended)This method will prompt you for your User Key during installation.
# Download the scriptcurl -sSL https://raw.githubusercontent.com/7Stockapp/serverhub_dev/main/install.sh -o install.sh# Make it executablechmod +x install.sh# Run it (will prompt for your User Key)sudo ./install.shNote: The installation process may take a few minutes to complete.
Environment Variable MethodProvide your User Key as an environment variable for a streamlined installation.
# Replace "your-key-here" with your actual User KeyUSER_KEY=your-key-here sudo -E bash -c "$(curl -sSL https://raw.githubusercontent.com/7Stockapp/serverhub_dev/main/install.sh)"Note: If this method appears to hang, consider using the manual installation method described in the troubleshooting section.
APT Repository InstallationInstall the agent using our APT repository for easier updates.
# Add the repositoryecho "deb [trusted=yes] https://raw.githubusercontent.com/7Stockapp/serverhub_dev/main stable main" | sudo tee /etc/apt/sources.list.d/serverhub.list# Update and installsudo apt update --allow-insecure-repositoriessudo apt install -y serverhub-agent --allow-unauthenticated# Set your User Keysudo mkdir -p /etc/serverhubecho "USER_KEY=your-key-here" | sudo tee /etc/serverhub/configsudo systemctl restart serverhub.serviceNote: Replace
your-key-herewith your actual User Key generated in step 2.
Configuration Settings
Your agent configuration file is located at:
/etc/serverhub/config
C:\ProgramData\ServerHub\config.ini
Required Configuration
Replace your-key-here with the Connect Key generated in step 2.
Verify Your Installation
Check if ServerHub agent is running properly:
You should see active (running) in the output if everything is working correctly.
Tip
After installation, it may take a few minutes for the first data points to appear in your ServerHub dashboard.
Troubleshooting
Diagnostic Commands
View Service Status
Check Service Logs
Verify Configuration
Common Issues
APT Lock Errors
If you encounter APT lock errors during installation, run these commands:
sudo rm /var/lib/apt/lists/lock
sudo rm /var/lib/dpkg/lock
sudo dpkg --configure -a
Connection Issues
If your server isn't connecting to ServerHub:
- Verify your User Key is correctly entered in the configuration file
- Check for firewalls blocking outgoing connections
- Restart the service after configuration changes
Manual Installation Method
If the standard installation methods fail, try this step-by-step manual approach:
Uninstalling ServerHub
If you need to remove the ServerHub agent from your system, follow these steps:
Note:
Uninstalling the agent will stop all monitoring for this server. Your historical data will remain available in the ServerHub dashboard.
Need Help?
Our support team is ready to assist you with any questions or issues you may encounter.
Contact SupportYou're All Set!
Your server is now connected and ready to be monitored with ServerHub. Start tracking your server's performance metrics and services in real-time.
© 2023 ServerHub. All rights reserved.
For more information, visit our GitHub repository.