Common Commands Reference
This document provides a reference for common commands used with the WeDa Low-Code Platform, including platform management, service control, and troubleshooting operations.
1. Platform Management Commands
1.1 Version Upgrade
Version Compatibility
The following upgrade commands are applicable to v1.0.2-20241210 and later versions
# Default installation and renewal operation
./install.sh
# Upgrade to the latest version
./install.sh --upgrade
# Upgrade to a specific version
./install.sh --upgrade=v1.0.2-20241210
Parameter Description:
- No parameters: Execute default installation and renewal operations
--upgrade: Upgrade to the latest available version--upgrade=<version>: Upgrade to a specific version number
1.2 Service Restart
Choose the appropriate restart command based on your version:
# For versions before 20241230
./upgrade.sh
# For versions 20241230 and later
./restart.sh
Version Differences
Please choose the correct restart command based on your platform version. Using the wrong command may cause service anomalies.
1.3 Service Uninstallation
# Navigate to installation directory
cd /data/tencent/weda
# Stop and remove all service containers
docker-compose --profile all down
1.4 Data Cleanup
Data Loss Warning
The following operations will permanently delete all platform data. Use only when complete reinstallation is required!
# Navigate to installation directory
cd /data/tencent/weda
# Delete configuration and data files
rm -rf configs
rm -rf log
rm -rf storage
rm -f /etc/wedalet/config.yaml
Deleted Content Description:
configs: Platform configuration files directorylog: Log files directorystorage: Storage data directory/etc/wedalet/config.yaml: System configuration file
2. Installer Management Commands
2.1 Log Viewing
Real-time Log Monitoring
# View installer log output in real-time
journalctl -u wedalet -f
Historical Log Queries
# View the last 200 lines of logs
journalctl -u wedalet | tail -n 200
# View all historical logs
journalctl -u wedalet
# View logs for a specific time range
journalctl -u wedalet --since "2024-01-01" --until "2024-01-02"
# View today's logs
journalctl -u wedalet --since today
# View logs from the last hour
journalctl -u wedalet --since "1 hour ago"
2.2 Service Control
# Restart installer service
systemctl restart wedalet
# Check service running status
systemctl status wedalet
# Stop installer service
systemctl stop wedalet
# Start installer service
systemctl start wedalet
# Reload service configuration
systemctl reload wedalet
2.3 Auto-start Management
# Enable auto-start on boot
systemctl enable wedalet
# Disable auto-start on boot
systemctl disable wedalet
# Check auto-start status
systemctl is-enabled wedalet
3. Troubleshooting Commands
3.1 System Status Check
# Check Docker service status
systemctl status docker
# Check container running status
docker ps -a
# Check system resource usage
df -h
free -h
3.2 Network Connection Check
# Check port usage
netstat -tlnp | grep :8080
# Check firewall status
systemctl status firewalld
4. Best Practices
4.1 Pre-operation Preparation
- Permission Check: Ensure you have root or sudo privileges
- Data Backup: Back up critical data and configurations before important operations
- Version Confirmation: Confirm current platform version and choose the correct commands
4.2 Troubleshooting Process
- Check Service Status: Use
systemctl statusto check service status - Review Log Information: Use
journalctlto view detailed error information - Verify System Resources: Check disk space and memory usage
- Network Connectivity: Confirm ports and network configuration are correct
4.3 Security Considerations
- Regularly backup important data and configuration files
- Exercise caution when performing data cleanup operations in production environments
- Record the execution time and results of important operations
- Recommend performing restart and upgrade operations during maintenance windows