diff --git a/Files/oldapp.py b/Files/oldapp.py new file mode 100644 index 0000000..2402c2e --- /dev/null +++ b/Files/oldapp.py @@ -0,0 +1,189 @@ +import rdm6300 +import os, time +import logging +from gpiozero import OutputDevice +from multiprocessing import Process +import requests +import subprocess +import urllib3 +import threading +import urllib.parse +from datetime import datetime, timedelta # Import datetime and timedelta + +urllib3.disable_warnings() +# Configure logging +logging.basicConfig(filename='/home/pi/Desktop/Prezenta/data/log.txt', level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') +def delete_old_logs(): + log_dir = '/home/pi/Desktop/Prezenta/data/' + log_file = 'log.txt' + log_path = os.path.join(log_dir, log_file) + + if os.path.exists(log_path): + file_mod_time = datetime.fromtimestamp(os.path.getmtime(log_path)) + if datetime.now() - file_mod_time > timedelta(days=10): + os.remove(log_path) + logging.info("Deleted old log file: %s", log_file) + else: + logging.info("Log file is not older than 10 days: %s", log_file) + else: + logging.info("Log file does not exist: %s", log_file) + +# Call the function to delete old logs +delete_old_logs() + + +def config(): + import config + +def post_backup_data(): + logging.info("Reading backup data from tag.txt...") + try: + with open("./data/tag.txt", "r") as file: + lines = file.readlines() + + remaining_lines = lines[:] + + for line in lines: + line = line.strip() + if line: + logging.info(f"Posting backup data: {line}") + try: + response = requests.post(line, verify=False, timeout=3) + logging.info("Request sent, awaiting response...") + response.raise_for_status() # Raise an error for bad status codes + logging.info("Data posted successfully: %s", response.text) + remaining_lines.remove(line + "\n") + except requests.exceptions.Timeout: + logging.warning("Request timed out.") + break + except requests.exceptions.RequestException as e: + logging.error("An error occurred: %s", e) + break + + with open("./data/tag.txt", "w") as file: + file.writelines(remaining_lines) + logging.info("Backup data updated.") + + except FileNotFoundError: + logging.warning("No backup file found.") + except Exception as e: + logging.error("An error occurred while reading the backup file: %s", e) + +def check_internet_connection(): + hostname = "10.76.140.17" # "https://google.com" + cmd_block_wifi = 'sudo rfkill block wifi' + cmd_unblock_wifi = 'sudo rfkill unblock wifi' + logging.info('Internet connection check loaded') + delete_old_logs() + + def manage_wifi_connection(): + if var1 == 0: + logging.info("Internet is up! Waiting 45 minutes.") + post_backup_data() + time.sleep(2700) + else: + os.system(cmd_block_wifi) + logging.info('System is rebooting WiFi, please wait until it finishes the job 20 minutes') + time.sleep(1200) # 20 minutes + os.system(cmd_unblock_wifi) + + while True: + response = os.system("ping -c 1 " + hostname) + if response == 0: + var1 = 0 + manage_wifi_connection() + + else: + var1 = 1 + manage_wifi_connection() + +# Start the internet connection check in a separate process +internet_check_process = Process(target=check_internet_connection) +internet_check_process.start() +url = "10.76.140.17/iweb_v2/index.php/traceability/production" # pentru cazul in care raspberiul nu are sistem de prezenta +# Launch Chromium with the specified URLs +subprocess.Popen(["chromium", "--test-type", "--noerrors", "--kiosk", "--start-fullscreen", "--unsafely-treat-insecure-origin-as-secure=http://10.76.140.17", url], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, stdin=subprocess.DEVNULL, start_new_session=True) + +info = "0" + +def post_info(info): + logging.info("Starting to post data...") + info1 = info.strip() # Remove any leading/trailing whitespace, including newlines + try: + response = requests.post(info1, verify=False, timeout=3) + logging.info("Request sent, awaiting response...") + response.raise_for_status() # Raise an error for bad status codes + logging.info("Data posted successfully: %s", response.text) + except requests.exceptions.Timeout: + logging.warning("Request timed out. Saving data to backup file.") + with open("./data/tag.txt", "a") as file: # Open in append mode + file.write(info) + logging.info("Value %s was saved to tag.txt", info) + except requests.exceptions.RequestException as e: + logging.error("An error occurred: %s", e) + with open("./data/tag.txt", "a") as file: # Open in append mode + file.write(info) + logging.info("Value %s was saved to tag.txt", info) + +def post_info_thread(info): + thread = threading.Thread(target=post_info, args=(info,)) + thread.start() + +led1 = OutputDevice(23) +led2 = OutputDevice(24) +name = "idmasa" +logging.info("Variabila Id Masa A fost initializata ") +f = open("./data/idmasa.txt", "r") # deschid fisierul +name = f.readline().strip() # citesc toate liniile +f.close() # inchid fisierul +logging.info(name) + +class Reader(rdm6300.BaseReader): + global info + def card_inserted(self, card): + if card.value == 12886709: + logging.info("Inserting Config Card") + config() + return + + + afisare = time.strftime("%Y-%m-%d&%H:%M:%S") + date = 'https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/' + name + '/' + str(card.value) + "/1/" + afisare + "\n" + info = date + if name == "noconfig": + led1.on() + logging.info(info) + logging.info(f"card inserted {card}") + else: + logging.info(info) + post_info_thread(info) + led1.on() + logging.info(f"card inserted {card}") + logging.info(f"card removed {card}") + + def card_removed(self, card): + if card.value == 12886709: + logging.info("Removing Config card") + return + # config() + afisare=time.strftime("%Y-%m-%d&%H:%M:%S") + date='https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/'+name+'/'+str(card.value)+"/0/"+afisare+"\n" + info = date + if name == "noconfig": + led1.of() + logging.info(info) + logging.info(f"card card removed {card}") + else: + logging.info(info) + post_info_thread(info) + led1.off() + logging.info(f"card removed {card}") + logging.info(f"card removed {card}") + + + +try: + r = Reader('/dev/ttyS0') +except: + r = Reader('/dev/ttyAMA0') +r.start() diff --git a/Files/reposytory/FreeSimpleGUI-5.0.0-py3-none-any.whl b/Files/reposytory/FreeSimpleGUI-5.0.0-py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/Harting/HA_MWG_new_cert.crt b/Files/reposytory/Harting/HA_MWG_new_cert.crt old mode 100755 new mode 100644 diff --git a/Files/reposytory/Harting/HartingIssuingCA1.crt b/Files/reposytory/Harting/HartingIssuingCA1.crt old mode 100755 new mode 100644 diff --git a/Files/reposytory/Harting/HartingRootCA.crt b/Files/reposytory/Harting/HartingRootCA.crt old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/CUPS driver guide V128.pdf b/Files/reposytory/LinuxPOS-Driver/CUPS driver guide V128.pdf old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/Readme_POS-CUPS.txt b/Files/reposytory/LinuxPOS-Driver/Readme_POS-CUPS.txt old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos-cups-1.2.8-0.i586.rpm b/Files/reposytory/LinuxPOS-Driver/ctzpos-cups-1.2.8-0.i586.rpm old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos-cups-1.2.8-0.src.rpm b/Files/reposytory/LinuxPOS-Driver/ctzpos-cups-1.2.8-0.src.rpm old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos-cups-1.2.8-0.x86_64.rpm b/Files/reposytory/LinuxPOS-Driver/ctzpos-cups-1.2.8-0.x86_64.rpm old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos-cups_1.2.8-0_amd64.deb b/Files/reposytory/LinuxPOS-Driver/ctzpos-cups_1.2.8-0_amd64.deb old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos-cups_1.2.8-0_arm64.deb b/Files/reposytory/LinuxPOS-Driver/ctzpos-cups_1.2.8-0_arm64.deb old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos-cups_1.2.8-0_i386.deb b/Files/reposytory/LinuxPOS-Driver/ctzpos-cups_1.2.8-0_i386.deb old mode 100755 new mode 100644 diff --git a/Files/reposytory/LinuxPOS-Driver/ctzpos.deb b/Files/reposytory/LinuxPOS-Driver/ctzpos.deb old mode 100755 new mode 100644 diff --git a/Files/reposytory/PyAutoGUI-0.9.54-py3-none-any.whl b/Files/reposytory/PyAutoGUI-0.9.54-py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/WebPrintClient/wcpp.deb b/Files/reposytory/WebPrintClient/wcpp.deb old mode 100755 new mode 100644 diff --git a/Files/reposytory/aiohappyeyeballs-2.6.1-py3-none-any.whl b/Files/reposytory/aiohappyeyeballs-2.6.1-py3-none-any.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/aiohttp-3.11.18-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl b/Files/reposytory/aiohttp-3.11.18-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/aiosignal-1.3.2-py2.py3-none-any.whl b/Files/reposytory/aiosignal-1.3.2-py2.py3-none-any.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/attrs-25.3.0-py3-none-any.whl b/Files/reposytory/attrs-25.3.0-py3-none-any.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/evdev-1.7.1-cp311-cp311-linux_armv7l.whl b/Files/reposytory/evdev-1.7.1-cp311-cp311-linux_armv7l.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/frozenlist-1.6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl b/Files/reposytory/frozenlist-1.6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/func_timeout-4.3.5-py3-none-any.whl b/Files/reposytory/func_timeout-4.3.5-py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/multidict-6.4.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl b/Files/reposytory/multidict-6.4.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/propcache-0.3.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl b/Files/reposytory/propcache-0.3.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/reposytory/pynput-1.7.6-py2.py3-none-any.whl b/Files/reposytory/pynput-1.7.6-py2.py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/pyserial-3.5-py2.py3-none-any.whl b/Files/reposytory/pyserial-3.5-py2.py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/python3-aiohttp-dbgsym_3.8.4-1_armhf.ddeb b/Files/reposytory/python3-aiohttp-dbgsym_3.8.4-1_armhf.ddeb new file mode 100644 index 0000000..c8562d2 Binary files /dev/null and b/Files/reposytory/python3-aiohttp-dbgsym_3.8.4-1_armhf.ddeb differ diff --git a/Files/reposytory/python3-aiohttp.deb b/Files/reposytory/python3-aiohttp.deb new file mode 100644 index 0000000..59a274b Binary files /dev/null and b/Files/reposytory/python3-aiohttp.deb differ diff --git a/Files/reposytory/python3-aiohttp_3.8.4-1_armhf.deb b/Files/reposytory/python3-aiohttp_3.8.4-1_armhf.deb new file mode 100644 index 0000000..59a274b Binary files /dev/null and b/Files/reposytory/python3-aiohttp_3.8.4-1_armhf.deb differ diff --git a/Files/reposytory/python3_xlib-0.15-py3-none-any.whl b/Files/reposytory/python3_xlib-0.15-py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/python_xlib-0.31-py2.py3-none-any.whl b/Files/reposytory/python_xlib-0.31-py2.py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/rdm6300-0.1.1-py3-none-any.whl b/Files/reposytory/rdm6300-0.1.1-py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/six-1.16.0-py2.py3-none-any.whl b/Files/reposytory/six-1.16.0-py2.py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/typing_extensions-4.11.0-py3-none-any.whl b/Files/reposytory/typing_extensions-4.11.0-py3-none-any.whl old mode 100755 new mode 100644 diff --git a/Files/reposytory/yarl-1.20.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl b/Files/reposytory/yarl-1.20.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl new file mode 100644 index 0000000..e69de29 diff --git a/Files/system_packages/sshpass_1.09-1_armhf.deb b/Files/system_packages/sshpass_1.09-1_armhf.deb new file mode 100644 index 0000000..17d8ca7 Binary files /dev/null and b/Files/system_packages/sshpass_1.09-1_armhf.deb differ diff --git a/README_DEPENDENCIES.md b/README_DEPENDENCIES.md new file mode 100644 index 0000000..d5b12f2 --- /dev/null +++ b/README_DEPENDENCIES.md @@ -0,0 +1,186 @@ +# Prezenta App - Robust Dependency Management System + +## Overview +The app.py has been updated to include a comprehensive, self-contained dependency management system that automatically checks and installs required packages from a local repository. This makes the system completely offline-capable and resilient to network issues. + +## Key Features + +### 🔧 **Automatic Dependency Installation** +- **Self-contained**: No need for separate launcher scripts or shell scripts +- **Offline capability**: Installs packages from local `./Files/reposytory` directory +- **Smart detection**: Checks if packages are already installed before attempting installation +- **Fallback mechanisms**: Multiple installation methods (pip, apt, local wheels) + +### 🛡️ **Robust Error Handling** +- **Network resilience**: Handles socket errors gracefully with file-based fallbacks +- **Import safety**: Safe import functions that don't crash the app +- **Graceful degradation**: App continues to work even if some optional features fail +- **Comprehensive logging**: All operations are logged for debugging + +### 📦 **Supported Packages** +The system automatically manages these packages: +- `rdm6300` - RFID reader library (critical) +- `requests` - HTTP library (critical) +- `aiohttp` - Async HTTP library (optional) +- `flask` - Web server for command interface (optional) +- `gpiozero` - GPIO control (falls back to dummy if not available) +- All required dependencies (urllib3, certifi, charset_normalizer, etc.) + +## How It Works + +### 1. **Startup Dependency Check** +When the app starts, it: +1. Checks each required package using `importlib.util.find_spec()` +2. Identifies missing packages +3. Attempts installation from local wheel files in `./Files/reposytory` +4. Falls back to pip/apt if needed +5. Continues execution even if some packages fail to install + +### 2. **Safe Import System** +```python +def safe_import(module_name, package_name=None): + """Safely import a module with error handling""" +``` +- Imports modules without crashing the app +- Returns None for missing modules +- Allows the app to adapt to available packages + +### 3. **Network Error Resilience** +- Device hostname/IP saved to `./data/device_info.txt` +- Automatically loads from file when socket errors occur +- Never crashes due to network resolution issues + +### 4. **Graceful Feature Degradation** +- **No Flask**: Command server is disabled with warning +- **No gpiozero**: LED functions become print statements +- **No aiohttp**: Falls back to synchronous requests +- **No network**: Uses cached device information + +## Repository Structure + +### Required Files in `./Files/reposytory/`: +``` +├── rdm6300-0.1.1-py3-none-any.whl +├── requests-2.32.3-py3-none-any.whl +├── aiohttp-3.11.18-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl +├── flask-*.whl (optional) +├── urllib3-2.3.0-py3-none-any.whl +├── certifi-2025.1.31-py3-none-any.whl +├── charset_normalizer-3.4.1-py3-none-any.whl +├── idna-3.10-py3-none-any.whl +├── multidict-6.4.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl +├── aiosignal-1.3.2-py2.py3-none-any.whl +├── frozenlist-1.6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl +├── attrs-25.3.0-py3-none-any.whl +├── yarl-1.20.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl +├── aiohappyeyeballs-2.6.1-py3-none-any.whl +└── propcache-0.3.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl +``` + +## Installation Process + +### Automatic (Recommended) +Simply run the app - dependencies will be installed automatically: +```bash +cd /home/pi/Desktop/prezenta +python3 app.py +``` + +### Manual Testing +Test the dependency system: +```bash +cd /home/pi/Desktop/prezenta +python3 test_dependencies.py +``` + +## Folder Structure + +The prezenta folder has been streamlined for maximum simplicity: + +``` +prezenta/ +├── app.py # Main application (self-contained) +├── config.py # Configuration module +├── test_dependencies.py # Testing and validation script +├── README_DEPENDENCIES.md # This documentation +├── data/ # Application data +│ ├── device_info.txt # Network configuration cache (auto-created) +│ ├── idmasa.txt # Device identifier +│ └── tag.txt # Backup data +└── Files/ # Local package repository + └── reposytory/ # Wheel files for offline installation + ├── rdm6300-*.whl + ├── requests-*.whl + ├── aiohttp-*.whl + └── ... (all dependencies) +``` + +### Removed Files (No Longer Needed) +- ~~`launcher.py`~~ - App is now self-launching +- ~~`libraries.sh`~~ - Dependency installation integrated into app.py +- ~~`check_dependencies.py`~~ - Functionality moved to app.py + +## Features Added + +### 1. **Self-Installing Dependencies** +- Checks all required packages on startup +- Installs missing packages from local repository +- No external network dependencies for package installation + +### 2. **Network Error Recovery** +- Handles `socket.gaierror` gracefully +- Saves working network configuration to file +- Loads from file when network issues occur + +### 3. **Modular Feature Set** +- Core RFID functionality always works +- Optional features (web interface, LEDs) degrade gracefully +- Clear status messages for all operations + +### 4. **Enhanced Logging** +- Dependency check results logged +- Installation attempts logged +- Network fallback operations logged + +## Troubleshooting + +### Common Issues + +1. **"Repository not found"** + - Ensure `./Files/reposytory` directory exists + - Check that wheel files are present + +2. **"Permission denied during installation"** + - Script uses `--break-system-packages` flag + - May need to run with appropriate permissions + +3. **"rdm6300 is required"** + - This is critical - app will exit if rdm6300 can't be installed + - Check that `rdm6300-0.1.1-py3-none-any.whl` exists in repository + +4. **"Flask not available - Command server disabled"** + - Non-critical - RFID functionality continues to work + - Install Flask manually if remote command capability is needed + +### Recovery Steps + +1. **Check repository**: Ensure all wheel files are present +2. **Test installation**: Run `python3 test_dependencies.py` +3. **Manual install**: Install missing packages manually with pip +4. **Check logs**: Review console output for specific error messages + +## Benefits + +1. **Zero-configuration deployment**: Just copy files and run +2. **Offline operation**: No internet required after initial setup +3. **Fault tolerance**: Continues working even with partial failures +4. **Easy maintenance**: All dependencies managed automatically +5. **Clear diagnostics**: Detailed status reporting for troubleshooting + +## Version History + +- **v2.4**: Added robust dependency management and network error handling +- **v2.3**: Added remote command execution capabilities +- **v2.2**: Basic RFID and logging functionality + +The system is now production-ready for deployment in environments with limited or no internet connectivity, providing maximum reliability and ease of deployment. diff --git a/__pycache__/config.cpython-311.pyc b/__pycache__/config.cpython-311.pyc new file mode 100644 index 0000000..9144132 Binary files /dev/null and b/__pycache__/config.cpython-311.pyc differ diff --git a/app.py b/app.py index 8993037..2a4c4ad 100644 --- a/app.py +++ b/app.py @@ -1,81 +1,1129 @@ -import rdm6300 -import os, time -import logging -from gpiozero import OutputDevice -from multiprocessing import Process -import requests +#App version 2.7 - Fixed auto-update path detection for case-sensitive file systems +import os +import sys import subprocess -import urllib3 +import importlib +import importlib.util +import stat +import pwd +import grp + +def install_package_from_wheel(wheel_path, package_name): + """ + Install a Python package from a wheel file + """ + try: + print(f"Installing {package_name} from {wheel_path}...") + result = subprocess.run([ + sys.executable, "-m", "pip", "install", wheel_path, + "--no-index", "--no-deps", "--break-system-packages", + "--no-warn-script-location", "--force-reinstall" + ], capture_output=True, text=True, timeout=60) + + if result.returncode == 0: + print(f"✓ {package_name} installed successfully") + return True + else: + print(f"✗ Failed to install {package_name}: {result.stderr}") + return False + except Exception as e: + print(f"✗ Error installing {package_name}: {e}") + return False + +def check_and_install_dependencies(): + """ + Check if required packages are installed and install them from local repository if needed + """ + print("Checking and installing dependencies...") + + # Define required packages and their corresponding wheel files + required_packages = { + 'rdm6300': 'rdm6300-0.1.1-py3-none-any.whl', + 'gpiozero': None, # System package, should be pre-installed + 'requests': 'requests-2.32.3-py3-none-any.whl', + 'aiohttp': 'aiohttp-3.11.18-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl', + 'flask': None, # Will try to install if needed + 'urllib3': 'urllib3-2.3.0-py3-none-any.whl', + 'certifi': 'certifi-2025.1.31-py3-none-any.whl', + 'charset_normalizer': 'charset_normalizer-3.4.1-py3-none-any.whl', + 'idna': 'idna-3.10-py3-none-any.whl', + 'multidict': 'multidict-6.4.3-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl', + 'aiosignal': 'aiosignal-1.3.2-py2.py3-none-any.whl', + 'frozenlist': 'frozenlist-1.6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl', + 'attrs': 'attrs-25.3.0-py3-none-any.whl', + 'yarl': 'yarl-1.20.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl', + 'aiohappyeyeballs': 'aiohappyeyeballs-2.6.1-py3-none-any.whl', + 'propcache': 'propcache-0.3.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl' + } + + repository_path = "./Files/reposytory" + missing_packages = [] + + # Check each required package + for package_name, wheel_file in required_packages.items(): + try: + # Use importlib to check if package exists + spec = importlib.util.find_spec(package_name) + if spec is not None: + print(f"✓ {package_name} is already installed") + else: + raise ImportError(f"Package {package_name} not found") + + except ImportError: + print(f"✗ {package_name} is not installed") + missing_packages.append((package_name, wheel_file)) + except Exception as e: + print(f"✗ Error checking {package_name}: {e}") + missing_packages.append((package_name, wheel_file)) + + # Install missing packages + if missing_packages: + print(f"\nInstalling {len(missing_packages)} missing packages...") + + for package_name, wheel_file in missing_packages: + if wheel_file is None: + # Try to install via pip from internet or system packages + try: + print(f"Attempting to install {package_name} via pip...") + result = subprocess.run([ + sys.executable, "-m", "pip", "install", package_name, + "--break-system-packages", "--no-warn-script-location" + ], capture_output=True, text=True, timeout=120) + + if result.returncode == 0: + print(f"✓ {package_name} installed via pip") + else: + print(f"✗ Could not install {package_name} via pip: {result.stderr}") + # Try system package manager for common packages + if package_name in ['flask', 'gpiozero']: + try: + print(f"Trying to install {package_name} via apt...") + apt_name = f"python3-{package_name.replace('_', '-')}" + apt_result = subprocess.run([ + "sudo", "apt", "install", "-y", apt_name + ], capture_output=True, text=True, timeout=300) + if apt_result.returncode == 0: + print(f"✓ {package_name} installed via apt") + else: + print(f"✗ Could not install {package_name} via apt") + except Exception as apt_e: + print(f"✗ Error installing {package_name} via apt: {apt_e}") + except Exception as e: + print(f"✗ Error installing {package_name} via pip: {e}") + continue + + wheel_path = os.path.join(repository_path, wheel_file) + + if not os.path.exists(wheel_path): + print(f"✗ Wheel file not found: {wheel_path}") + continue + + # Install the package + install_package_from_wheel(wheel_path, package_name) + + print("Dependency check completed.\n") + +# Run dependency check before importing anything else +try: + check_and_install_dependencies() +except Exception as e: + print(f"Warning: Dependency check failed: {e}") + print("Continuing with existing packages...") + +def safe_import(module_name, package_name=None): + """ + Safely import a module with error handling + """ + try: + if package_name: + module = __import__(package_name) + return getattr(module, module_name) + else: + return __import__(module_name) + except ImportError as e: + print(f"Warning: Could not import {module_name}: {e}") + return None + +# Now import required modules with fallbacks +rdm6300 = safe_import('rdm6300') +if rdm6300 is None: + print("ERROR: rdm6300 is required for this application to work!") + print("Please ensure rdm6300 is installed from the repository.") + sys.exit(1) + +# Import other required modules +import time +import logging + +# Try to import GPIO-related modules +try: + from gpiozero import OutputDevice + print("✓ gpiozero imported successfully") +except ImportError as e: + print(f"Warning: Could not import gpiozero: {e}") + print("LED functionality will be disabled") + # Create a dummy OutputDevice class + class OutputDevice: + def __init__(self, pin): + self.pin = pin + def on(self): + print(f"LED {self.pin} would turn ON") + def off(self): + print(f"LED {self.pin} would turn OFF") + +from multiprocessing import Process + +# Import network-related modules +try: + import requests + print("✓ requests imported successfully") +except ImportError as e: + print(f"ERROR: requests is required: {e}") + sys.exit(1) + import threading import urllib.parse -urllib3.disable_warnings() +from datetime import datetime, timedelta +import socket +import signal +# Import async modules +try: + import aiohttp + import asyncio + print("✓ aiohttp and asyncio imported successfully") +except ImportError as e: + print(f"Warning: Could not import aiohttp: {e}") + print("Async functionality may be limited") + import asyncio + +# Import Flask for command server +try: + from flask import Flask, request, jsonify + print("✓ Flask imported successfully") + FLASK_AVAILABLE = True +except ImportError as e: + print(f"Warning: Could not import Flask: {e}") + print("Command server functionality will be disabled") + FLASK_AVAILABLE = False + # Create dummy Flask classes + class Flask: + def __init__(self, name): + pass + def route(self, *args, **kwargs): + def decorator(f): + return f + return decorator + def run(self, *args, **kwargs): + pass + + def request(): + pass + + def jsonify(data): + return data + +import json + +def check_system_requirements(): + """ + Check and set up system requirements for the application + """ + print("Checking system requirements...") + + # 1. Check and install required system packages + system_packages = { + 'sshpass': 'sshpass_1.09-1_armhf.deb' # Required for auto-update functionality + } + + for package, deb_file in system_packages.items(): + try: + result = subprocess.run(['which', package], capture_output=True, text=True) + if result.returncode == 0: + print(f"✓ {package} is installed") + else: + print(f"Installing {package}...") + + # Try online installation first + try: + install_result = subprocess.run(['sudo', 'apt', 'update'], capture_output=True, text=True, timeout=120) + install_result = subprocess.run(['sudo', 'apt', 'install', '-y', package], + capture_output=True, text=True, timeout=300) + if install_result.returncode == 0: + print(f"✓ {package} installed successfully (online)") + continue + else: + print(f"Online installation failed, trying offline...") + except Exception as online_error: + print(f"Online installation failed: {online_error}, trying offline...") + + # Try offline installation from local .deb file + deb_path = f"./Files/system_packages/{deb_file}" + if os.path.exists(deb_path): + try: + print(f"Installing {package} from local package: {deb_path}") + offline_result = subprocess.run(['sudo', 'dpkg', '-i', deb_path], + capture_output=True, text=True, timeout=120) + if offline_result.returncode == 0: + print(f"✓ {package} installed successfully (offline)") + else: + print(f"✗ Offline installation failed: {offline_result.stderr}") + # Try to fix dependencies + print("Attempting to fix dependencies...") + subprocess.run(['sudo', 'apt', '--fix-broken', 'install', '-y'], + capture_output=True, text=True, timeout=300) + except Exception as offline_error: + print(f"✗ Offline installation error: {offline_error}") + else: + print(f"✗ Local package not found: {deb_path}") + print(f" To add offline support, download with: apt download {package}") + + except Exception as e: + print(f"Warning: Could not check/install {package}: {e}") + + # 2. Check and create required directories + required_dirs = ['./data', './Files', './Files/reposytory', './Files/system_packages'] + for dir_path in required_dirs: + try: + os.makedirs(dir_path, exist_ok=True) + print(f"✓ Directory ensured: {dir_path}") + except Exception as e: + print(f"✗ Failed to create directory {dir_path}: {e}") + return False + + # 2. Check required files and create defaults if missing + required_files = { + './data/idmasa.txt': 'noconfig', + './data/log.txt': '', + './data/tag.txt': '', + './data/device_info.txt': 'unknown-device\n127.0.0.1\n' + } + + for file_path, default_content in required_files.items(): + try: + if not os.path.exists(file_path): + with open(file_path, 'w') as f: + f.write(default_content) + print(f"✓ Created default file: {file_path}") + else: + print(f"✓ File exists: {file_path}") + except Exception as e: + print(f"✗ Failed to create file {file_path}: {e}") + + # 3. Check file permissions + try: + for file_path in required_files.keys(): + if os.path.exists(file_path): + # Ensure read/write permissions for the application + os.chmod(file_path, stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP | stat.S_IROTH) + print("✓ File permissions set correctly") + except Exception as e: + print(f"Warning: Could not set file permissions: {e}") + + return True + +def check_port_capabilities(): + """ + Check if the application can bind to port 80 and set up capabilities if needed + """ + print("Checking port 80 capabilities...") + + try: + # Check if we're running as root + if os.geteuid() == 0: + print("✓ Running as root - port 80 access available") + return True + + # Check if capabilities are set + python_path = sys.executable + result = subprocess.run(['getcap', python_path], capture_output=True, text=True) + + if 'cap_net_bind_service=ep' in result.stdout: + print("✓ Port binding capabilities already set") + return True + + # Try to set capabilities + print("Setting up port 80 binding capabilities...") + setup_script = './setup_port_capability.sh' + + if os.path.exists(setup_script): + result = subprocess.run(['sudo', 'bash', setup_script], capture_output=True, text=True) + if result.returncode == 0: + print("✓ Port capabilities set successfully") + return True + else: + print(f"✗ Failed to set capabilities: {result.stderr}") + else: + # Create the setup script if it doesn't exist + script_content = f'''#!/bin/bash +# Set port binding capability for Python to allow port 80 access +echo "Setting port binding capability for Python..." +sudo setcap cap_net_bind_service=ep {python_path} +echo "Capability set successfully" +''' + try: + with open(setup_script, 'w') as f: + f.write(script_content) + os.chmod(setup_script, stat.S_IRWXU | stat.S_IRGRP | stat.S_IROTH) + + result = subprocess.run(['sudo', 'bash', setup_script], capture_output=True, text=True) + if result.returncode == 0: + print("✓ Port capabilities set successfully") + return True + else: + print(f"✗ Failed to set capabilities: {result.stderr}") + except Exception as e: + print(f"✗ Failed to create setup script: {e}") + + except Exception as e: + print(f"Warning: Could not check port capabilities: {e}") + + print("Warning: Port 80 may not be accessible. App will try to run on default port.") + return False + +def check_hardware_interfaces(): + """ + Check hardware interfaces (UART/Serial) required for RFID reader + """ + print("Checking hardware interfaces...") + + # Check for serial devices + serial_devices = ['/dev/ttyS0', '/dev/ttyAMA0', '/dev/ttyUSB0'] + available_devices = [] + + for device in serial_devices: + if os.path.exists(device): + try: + # Check if we can access the device + with open(device, 'r'): + pass + available_devices.append(device) + print(f"✓ Serial device available: {device}") + except PermissionError: + print(f"✗ Permission denied for {device}. Adding user to dialout group...") + try: + # Add current user to dialout group for serial access + username = pwd.getpwuid(os.getuid()).pw_name + subprocess.run(['sudo', 'usermod', '-a', '-G', 'dialout', username], + capture_output=True, text=True) + print(f"✓ User {username} added to dialout group (reboot may be required)") + available_devices.append(device) + except Exception as e: + print(f"✗ Failed to add user to dialout group: {e}") + except Exception as e: + print(f"Warning: Could not test {device}: {e}") + + if not available_devices: + print("✗ No serial devices found. RFID reader may not work.") + # Enable UART if we're on Raspberry Pi + try: + config_file = '/boot/config.txt' + if os.path.exists(config_file): + print("Attempting to enable UART in Raspberry Pi config...") + result = subprocess.run(['sudo', 'raspi-config', 'nonint', 'do_serial', '0'], + capture_output=True, text=True) + if result.returncode == 0: + print("✓ UART enabled in config (reboot required)") + else: + print("Warning: Could not enable UART automatically") + except Exception as e: + print(f"Warning: Could not configure UART: {e}") + return False + + return True + +def check_network_connectivity(): + """ + Check network connectivity and DNS resolution + """ + print("Checking network connectivity...") + + try: + # Test basic connectivity + result = subprocess.run(['ping', '-c', '1', '8.8.8.8'], + capture_output=True, text=True, timeout=5) + if result.returncode == 0: + print("✓ Internet connectivity available") + + # Test DNS resolution + try: + import socket + socket.gethostbyname('google.com') + print("✓ DNS resolution working") + return True + except socket.gaierror: + print("✗ DNS resolution failed") + return False + else: + print("✗ No internet connectivity") + return False + + except subprocess.TimeoutExpired: + print("✗ Network timeout") + return False + except Exception as e: + print(f"Warning: Could not test network: {e}") + return False + +def initialize_gpio_permissions(): + """ + Set up GPIO permissions for LED control + """ + print("Setting up GPIO permissions...") + + try: + # Add user to gpio group if it exists + username = pwd.getpwuid(os.getuid()).pw_name + + # Check if gpio group exists + try: + grp.getgrnam('gpio') + subprocess.run(['sudo', 'usermod', '-a', '-G', 'gpio', username], + capture_output=True, text=True) + print(f"✓ User {username} added to gpio group") + except KeyError: + print("Warning: gpio group not found - GPIO access may be limited") + + # Set up GPIO access via /dev/gpiomem if available + gpio_devices = ['/dev/gpiomem', '/dev/mem'] + for device in gpio_devices: + if os.path.exists(device): + print(f"✓ GPIO device available: {device}") + break + else: + print("Warning: No GPIO devices found") + + except Exception as e: + print(f"Warning: Could not set up GPIO permissions: {e}") + +def perform_system_initialization(): + """ + Perform complete system initialization for first run + """ + print("=" * 60) + print("SYSTEM INITIALIZATION - Preparing for first run") + print("=" * 60) + + initialization_steps = [ + ("System Requirements", check_system_requirements), + ("Port Capabilities", check_port_capabilities), + ("Hardware Interfaces", check_hardware_interfaces), + ("GPIO Permissions", initialize_gpio_permissions), + ("Network Connectivity", check_network_connectivity) + ] + + success_count = 0 + total_steps = len(initialization_steps) + + for step_name, step_function in initialization_steps: + print(f"\n--- {step_name} ---") + try: + if step_function(): + success_count += 1 + print(f"✓ {step_name} completed successfully") + else: + print(f"⚠ {step_name} completed with warnings") + except Exception as e: + print(f"✗ {step_name} failed: {e}") + + print("\n" + "=" * 60) + print(f"INITIALIZATION COMPLETE: {success_count}/{total_steps} steps successful") + print("=" * 60) + + if success_count < total_steps: + print("Warning: Some initialization steps failed. Application may have limited functionality.") + print("Check the messages above for details.") + + return success_count >= (total_steps - 1) # Allow one failure + +#configurare variabile +def get_device_info(): + """ + Get hostname and device IP with file-based fallback to avoid socket errors + """ + config_file = "./data/device_info.txt" + hostname = None + device_ip = None + + # Try to get current hostname and IP + try: + hostname = socket.gethostname() + device_ip = socket.gethostbyname(hostname) + print(f"Successfully resolved - Hostname: {hostname}, IP: {device_ip}") + + # Save the working values to file for future fallback + try: + os.makedirs("./data", exist_ok=True) # Create data directory if it doesn't exist + with open(config_file, "w") as f: + f.write(f"{hostname}\n{device_ip}\n") + print(f"Saved device info to {config_file}") + except Exception as e: + print(f"Warning: Could not save device info to file: {e}") + + return hostname, device_ip + + except socket.gaierror as e: + print(f"Socket error occurred: {e}") + print("Attempting to load device info from file...") + + # Try to load from file + try: + with open(config_file, "r") as f: + lines = f.read().strip().split('\n') + if len(lines) >= 2: + hostname = lines[0].strip() + device_ip = lines[1].strip() + print(f"Loaded from file - Hostname: {hostname}, IP: {device_ip}") + return hostname, device_ip + else: + print("File exists but doesn't contain valid data") + except FileNotFoundError: + print(f"No fallback file found at {config_file}") + except Exception as e: + print(f"Error reading fallback file: {e}") + + except Exception as e: + print(f"Unexpected error getting device info: {e}") + + # Try to load from file as fallback + try: + with open(config_file, "r") as f: + lines = f.read().strip().split('\n') + if len(lines) >= 2: + hostname = lines[0].strip() + device_ip = lines[1].strip() + print(f"Loaded from file after error - Hostname: {hostname}, IP: {device_ip}") + return hostname, device_ip + except Exception as file_error: + print(f"Could not load from file: {file_error}") + + # Final fallback if everything fails + print("All methods failed - Using default values") + hostname = hostname or "unknown-device" + device_ip = "127.0.0.1" + + # Try to save these default values for next time + try: + os.makedirs("./data", exist_ok=True) + with open(config_file, "w") as f: + f.write(f"{hostname}\n{device_ip}\n") + print(f"Saved fallback values to {config_file}") + except Exception as e: + print(f"Could not save fallback values: {e}") + + return hostname, device_ip + +# Perform system initialization (first run setup) +if not perform_system_initialization(): + print("Warning: System initialization completed with errors.") + print("The application will continue but may have limited functionality.") + +# Get device information with error handling +hostname, device_ip = get_device_info() +print(f"Final result - Hostname: {hostname}, Device IP: {device_ip}") # Configure logging logging.basicConfig(filename='./data/log.txt', level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') +# function to delete old logs +def delete_old_logs(): + log_dir = './data/' + log_file = 'log.txt' + log_path = os.path.join(log_dir, log_file) + + if os.path.exists(log_path): + file_mod_time = datetime.fromtimestamp(os.path.getmtime(log_path)) + if datetime.now() - file_mod_time > timedelta(days=10): + os.remove(log_path) + log_info_with_server(f"Deleted old log file: {log_file}") + else: + log_info_with_server(f"Log file is not older than 10 days: {log_file}") + else: + log_info_with_server(f"Log file does not exist: {log_file}") + +# Function to read the name (idmasa) from the file +def read_name_from_file(): + try: + with open("./data/idmasa.txt", "r") as file: + n_masa = file.readline().strip() + return n_masa + except FileNotFoundError: + logging.error("File ./data/idmasa.txt not found.") + return "unknown" + +# Function to send logs to a remote server for the Server_monitorizare APP +def send_log_to_server(log_message, n_masa, hostname, device_ip): + host = hostname + device = device_ip + try: + + log_data = { + "hostname": str(host), + "device_ip": str(device), + "nume_masa": str(n_masa), + "log_message": str(log_message) + } + server_url = "http://rpi-ansible:80/logs" # Replace with your server's URL + print(log_data) # Debugging: Print log_data to verify its contents + response = requests.post(server_url, json=log_data, timeout=5) + response.raise_for_status() + logging.info("Log successfully sent to server: %s", log_message) + except requests.exceptions.RequestException as e: + logging.error("Failed to send log to server: %s", e) +# Wrapper for logging.info to also send logs to the server Monitorizare APP +def log_info_with_server(message): + n_masa = read_name_from_file() # Read name (idmasa) from the file + formatted_message = f"{message} (n_masa: {n_masa})" # Format the message + logging.info(formatted_message) # Log the formatted message + send_log_to_server(message, n_masa, hostname, device_ip) # Send the original message to the server + +# Function to execute system commands with proper security +def execute_system_command(command): + """ + Execute system commands with proper logging and security checks + """ + # Define allowed commands for security + allowed_commands = [ + "sudo apt update", + "sudo apt upgrade -y", + "sudo apt autoremove -y", + "sudo apt autoclean", + "sudo reboot", + "sudo shutdown -h now", + "df -h", + "free -m", + "uptime", + "systemctl status", + "sudo systemctl restart networking", + "sudo systemctl restart ssh" + ] + + try: + # Check if command is allowed + if command not in allowed_commands: + log_info_with_server(f"Command '{command}' is not allowed for security reasons") + return {"status": "error", "message": f"Command '{command}' is not allowed", "output": ""} + + log_info_with_server(f"Executing command: {command}") + + # Execute the command + result = subprocess.run( + command.split(), + capture_output=True, + text=True, + timeout=300 # 5 minute timeout + ) + + output = result.stdout + result.stderr + + if result.returncode == 0: + log_info_with_server(f"Command '{command}' executed successfully") + return {"status": "success", "message": "Command executed successfully", "output": output} + else: + log_info_with_server(f"Command '{command}' failed with return code {result.returncode}") + return {"status": "error", "message": f"Command failed with return code {result.returncode}", "output": output} + + except subprocess.TimeoutExpired: + log_info_with_server(f"Command '{command}' timed out") + return {"status": "error", "message": "Command timed out", "output": ""} + except Exception as e: + log_info_with_server(f"Error executing command '{command}': {str(e)}") + return {"status": "error", "message": f"Error: {str(e)}", "output": ""} + +# Flask app for receiving commands (only if Flask is available) +if FLASK_AVAILABLE: + command_app = Flask(__name__) + + @command_app.route('/execute_command', methods=['POST']) + def handle_command_execution(): + """ + Endpoint to receive and execute system commands + """ + try: + data = request.json + if not data or 'command' not in data: + return jsonify({"error": "Invalid request. 'command' field is required"}), 400 + + command = data.get('command') + + # Execute the command + result = execute_system_command(command) + + return jsonify(result), 200 if result['status'] == 'success' else 400 + + except Exception as e: + log_info_with_server(f"Error handling command execution request: {str(e)}") + return jsonify({"error": f"Server error: {str(e)}"}), 500 + + @command_app.route('/status', methods=['GET']) + def get_device_status(): + """ + Endpoint to get device status information + """ + try: + n_masa = read_name_from_file() + + # Get system information + uptime_result = subprocess.run(['uptime'], capture_output=True, text=True) + df_result = subprocess.run(['df', '-h', '/'], capture_output=True, text=True) + free_result = subprocess.run(['free', '-m'], capture_output=True, text=True) + + status_info = { + "hostname": hostname, + "device_ip": device_ip, + "nume_masa": n_masa, + "timestamp": datetime.now().strftime('%Y-%m-%d %H:%M:%S'), + "uptime": uptime_result.stdout.strip() if uptime_result.returncode == 0 else "N/A", + "disk_usage": df_result.stdout.strip() if df_result.returncode == 0 else "N/A", + "memory_usage": free_result.stdout.strip() if free_result.returncode == 0 else "N/A" + } + + return jsonify(status_info), 200 + + except Exception as e: + log_info_with_server(f"Error getting device status: {str(e)}") + return jsonify({"error": f"Error getting status: {str(e)}"}), 500 + + @command_app.route('/auto_update', methods=['POST']) + def auto_update_app(): + """ + Auto-update the application from the central server + Checks version, downloads newer files if available, and restarts the device + """ + try: + # Configuration + SERVER_HOST = "rpi-ansible" + SERVER_USER = "pi" + SERVER_PASSWORD = "Initial01!" + SERVER_APP_PATH = "/home/pi/Desktop/prezenta/app.py" + SERVER_REPO_PATH = "/home/pi/Desktop/prezenta/Files/reposytory" + + # Dynamically determine local paths based on current script location + current_script_path = os.path.abspath(__file__) + local_base_dir = os.path.dirname(current_script_path) + LOCAL_APP_PATH = current_script_path + LOCAL_REPO_PATH = os.path.join(local_base_dir, "Files", "reposytory") + + log_info_with_server(f"Auto-update process initiated from: {LOCAL_APP_PATH}") + + # Step 1: Get current local version + current_version = None + try: + with open(LOCAL_APP_PATH, 'r') as f: + first_line = f.readline() + if 'version' in first_line.lower(): + # Extract version number (e.g., "2.5" from "#App version 2.5") + import re + version_match = re.search(r'version\s+(\d+\.?\d*)', first_line, re.IGNORECASE) + if version_match: + current_version = float(version_match.group(1)) + log_info_with_server(f"Current local version: {current_version}") + except Exception as e: + log_info_with_server(f"Could not determine local version: {e}") + return jsonify({"error": f"Could not determine local version: {str(e)}"}), 500 + + # Step 2: Get remote version via SCP + temp_dir = "/tmp/app_update" + try: + # Create temporary directory + subprocess.run(['mkdir', '-p', temp_dir], check=True) + + # Download remote app.py to check version + scp_command = [ + 'sshpass', '-p', SERVER_PASSWORD, + 'scp', '-o', 'StrictHostKeyChecking=no', '-o', 'UserKnownHostsFile=/dev/null', + f'{SERVER_USER}@{SERVER_HOST}:{SERVER_APP_PATH}', + f'{temp_dir}/app.py' + ] + + result = subprocess.run(scp_command, capture_output=True, text=True, timeout=30) + if result.returncode != 0: + log_info_with_server(f"Failed to download remote app.py: {result.stderr}") + return jsonify({"error": f"Failed to connect to server: {result.stderr}"}), 500 + + # Check remote version + remote_version = None + with open(f'{temp_dir}/app.py', 'r') as f: + first_line = f.readline() + if 'version' in first_line.lower(): + import re + version_match = re.search(r'version\s+(\d+\.?\d*)', first_line, re.IGNORECASE) + if version_match: + remote_version = float(version_match.group(1)) + + log_info_with_server(f"Remote version: {remote_version}") + + except subprocess.TimeoutExpired: + return jsonify({"error": "Connection to server timed out"}), 500 + except Exception as e: + log_info_with_server(f"Error checking remote version: {e}") + return jsonify({"error": f"Error checking remote version: {str(e)}"}), 500 + + # Step 3: Compare versions + if remote_version is None: + return jsonify({"error": "Could not determine remote version"}), 500 + + if current_version is None or remote_version <= current_version: + log_info_with_server(f"No update needed. Current: {current_version}, Remote: {remote_version}") + return jsonify({ + "status": "no_update_needed", + "current_version": current_version, + "remote_version": remote_version, + "message": "Application is already up to date" + }), 200 + + # Step 4: Download updated files + log_info_with_server(f"Update available! Downloading version {remote_version}") + + try: + # Create backup of current app + backup_path = f"{LOCAL_APP_PATH}.backup.{current_version}" + subprocess.run(['cp', LOCAL_APP_PATH, backup_path], check=True) + log_info_with_server(f"Backup created: {backup_path}") + + # Download new app.py + subprocess.run(['cp', f'{temp_dir}/app.py', LOCAL_APP_PATH], check=True) + log_info_with_server("New app.py downloaded successfully") + + # Download repository folder + repo_scp_command = [ + 'sshpass', '-p', SERVER_PASSWORD, + 'scp', '-r', '-o', 'StrictHostKeyChecking=no', '-o', 'UserKnownHostsFile=/dev/null', + f'{SERVER_USER}@{SERVER_HOST}:{SERVER_REPO_PATH}', + f'{LOCAL_REPO_PATH}_new' + ] + + result = subprocess.run(repo_scp_command, capture_output=True, text=True, timeout=60) + if result.returncode == 0: + # Replace old repository with new one + subprocess.run(['rm', '-rf', LOCAL_REPO_PATH], check=True) + subprocess.run(['mv', f'{LOCAL_REPO_PATH}_new', LOCAL_REPO_PATH], check=True) + log_info_with_server("Repository updated successfully") + else: + log_info_with_server(f"Repository update failed: {result.stderr}") + + # Download system packages folder + local_system_packages_path = os.path.join(local_base_dir, 'Files', 'system_packages') + server_system_packages = f'{SERVER_USER}@{SERVER_HOST}:/home/pi/Desktop/prezenta/Files/system_packages' + + system_scp_command = [ + 'sshpass', '-p', SERVER_PASSWORD, + 'scp', '-r', '-o', 'StrictHostKeyChecking=no', '-o', 'UserKnownHostsFile=/dev/null', + server_system_packages, + f'{local_system_packages_path}_new' + ] + + try: + result = subprocess.run(system_scp_command, capture_output=True, text=True, timeout=60) + if result.returncode == 0: + # Replace old system packages with new ones + if os.path.exists(local_system_packages_path): + subprocess.run(['rm', '-rf', local_system_packages_path], check=True) + subprocess.run(['mv', f'{local_system_packages_path}_new', local_system_packages_path], check=True) + log_info_with_server("System packages updated successfully") + else: + log_info_with_server(f"System packages update failed: {result.stderr}") + except Exception as sys_e: + log_info_with_server(f"System packages update error: {sys_e}") + + except Exception as e: + # Restore backup if something went wrong + try: + subprocess.run(['cp', backup_path, LOCAL_APP_PATH], check=True) + log_info_with_server("Backup restored due to error") + except: + pass + return jsonify({"error": f"Update failed: {str(e)}"}), 500 + + # Step 5: Schedule device restart + log_info_with_server("Update completed successfully. Scheduling restart...") + + # Create a restart script that will run after this response + restart_script = '''#!/bin/bash +sleep 3 +sudo reboot +''' + with open('/tmp/restart_device.sh', 'w') as f: + f.write(restart_script) + subprocess.run(['chmod', '+x', '/tmp/restart_device.sh'], check=True) + + # Schedule the restart in background + subprocess.Popen(['/tmp/restart_device.sh'], + stdout=subprocess.DEVNULL, + stderr=subprocess.DEVNULL) + + return jsonify({ + "status": "success", + "message": f"Updated from version {current_version} to {remote_version}. Device restarting...", + "old_version": current_version, + "new_version": remote_version, + "restart_scheduled": True + }), 200 + + except Exception as e: + log_info_with_server(f"Auto-update error: {str(e)}") + return jsonify({"error": f"Auto-update failed: {str(e)}"}), 500 + finally: + # Cleanup temp directory + try: + subprocess.run(['rm', '-rf', temp_dir], check=True) + except: + pass + + def start_command_server(): + """ + Start the Flask server with enhanced port handling and fallback + """ + # Try different ports in order of preference + preferred_ports = [ + int(os.environ.get('FLASK_PORT', 80)), # Use environment variable or default to 80 + 80, # Standard HTTP port + 5000, # Flask default + 8080, # Alternative HTTP port + 3000 # Development port + ] + + for port in preferred_ports: + try: + print(f"Attempting to start command server on port {port}...") + + # Test if port is available + import socket + test_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM) + test_socket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1) + test_socket.bind(('0.0.0.0', port)) + test_socket.close() + + # Port is available, start Flask server + print(f"Port {port} is available. Starting command server...") + command_app.run(host='0.0.0.0', port=port, debug=False, use_reloader=False) + return # Success, exit function + + except PermissionError: + print(f"✗ Permission denied for port {port}") + if port == 80: + print(" Hint: Port 80 requires root privileges or capabilities") + print(" Try running: sudo setcap cap_net_bind_service=ep $(which python3)") + continue + except OSError as e: + if "Address already in use" in str(e): + print(f"✗ Port {port} is already in use") + else: + print(f"✗ Port {port} error: {e}") + continue + except Exception as e: + print(f"✗ Failed to start on port {port}: {e}") + continue + + # If we get here, all ports failed + log_info_with_server("Error: Could not start command server on any port") + print("✗ Could not start command server on any available port") + + # Start command server in a separate process with enhanced error handling + try: + print("Initializing command server...") + command_server_process = Process(target=start_command_server) + command_server_process.daemon = True # Ensure it dies with main process + command_server_process.start() + + # Give the server a moment to start and check if it's running + import time + time.sleep(2) + + if command_server_process.is_alive(): + port = int(os.environ.get('FLASK_PORT', 80)) + print(f"✓ Command server started successfully on port {port}") + else: + print("Warning: Command server process stopped unexpectedly") + + except Exception as e: + print(f"Warning: Could not start command server: {e}") + log_info_with_server(f"Command server startup error: {str(e)}") +else: + print("Warning: Flask not available - Command server disabled") +# Call the function to delete old logs +delete_old_logs() def config(): import config - +# function for posting data to the harting server def post_backup_data(): - logging.info("Reading backup data from tag.txt...") + try: with open("./data/tag.txt", "r") as file: lines = file.readlines() - remaining_lines = lines[:] for line in lines: line = line.strip() if line: - logging.info(f"Posting backup data: {line}") + try: response = requests.post(line, verify=False, timeout=3) - logging.info("Request sent, awaiting response...") +# response.raise_for_status() # Raise an error for bad status codes - logging.info("Data posted successfully: %s", response.text) + log_info_with_server(f"Data posted successfully:") remaining_lines.remove(line + "\n") except requests.exceptions.Timeout: - logging.warning("Request timed out.") + log_info_with_server("Request timed out.") break except requests.exceptions.RequestException as e: - logging.error("An error occurred: %s", e) + log_info_with_server(f"An error occurred: ") break with open("./data/tag.txt", "w") as file: file.writelines(remaining_lines) - logging.info("Backup data updated.") + #log_info_with_server("Backup data updated.") except FileNotFoundError: - logging.warning("No backup file found.") - except Exception as e: - logging.error("An error occurred while reading the backup file: %s", e) + log_info_with_server("No backup file found.") + +# Function to check internet connection def check_internet_connection(): - hostname = "10.76.140.17" # "https://google.com" + hostname = "10.76.140.17" cmd_block_wifi = 'sudo rfkill block wifi' cmd_unblock_wifi = 'sudo rfkill unblock wifi' - logging.info('Internet connection check loaded') - - def manage_wifi_connection(): - if var1 == 0: - logging.info("Internet is up! Waiting 45 minutes.") - post_backup_data() - time.sleep(2700) - else: - os.system(cmd_block_wifi) - logging.info('System is rebooting WiFi, please wait until it finishes the job 20 minutes') - time.sleep(1200) # 20 minutes - os.system(cmd_unblock_wifi) + log_info_with_server('Internet connection check loaded') + delete_old_logs() + chromium_process_name = "chromium" while True: - response = os.system("ping -c 1 " + hostname) - if response == 0: - var1 = 0 - manage_wifi_connection() - - else: - var1 = 1 - manage_wifi_connection() + try: + # Use subprocess to execute the ping command + response = subprocess.run( + ["ping", "-c", "1", hostname], + stdout=subprocess.DEVNULL, + stderr=subprocess.DEVNULL + ) + if response.returncode == 0: + log_info_with_server("Internet is up! Waiting 45 minutes.") + post_backup_data() + time.sleep(2700) # 45 minutes + else: + log_info_with_server("Internet is down. Rebooting WiFi.") + os.system(cmd_block_wifi) + time.sleep(1200) # 20 minutes + os.system(cmd_unblock_wifi) + + # Refresh Chromium process + log_info_with_server("Refreshing Chromium process.") + try: + # Find and terminate Chromium processes + subprocess.run(["pkill", "-f", chromium_process_name], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL) + time.sleep(5) # Wait for processes to terminate + + # Relaunch Chromium + url = "10.76.140.17/iweb_v2/index.php/traceability/production" + subprocess.Popen( + ["chromium", "--test-type", "--noerrors", "--kiosk", "--start-fullscreen", + "--unsafely-treat-insecure-origin-as-secure=http://10.76.140.17", url], + stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, stdin=subprocess.DEVNULL, start_new_session=True + ) + log_info_with_server("Chromium process restarted successfully.") + except Exception as e: + log_info_with_server(f"Failed to refresh Chromium process: {e}") + except Exception as e: + log_info_with_server(f"An error occurred during internet check: {e}") + time.sleep(60) # Retry after 1 minute in case of an error # Start the internet connection check in a separate process internet_check_process = Process(target=check_internet_connection) @@ -85,70 +1133,201 @@ url = "10.76.140.17/iweb_v2/index.php/traceability/production" # pentru cazul in subprocess.Popen(["chromium", "--test-type", "--noerrors", "--kiosk", "--start-fullscreen", "--unsafely-treat-insecure-origin-as-secure=http://10.76.140.17", url], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL, stdin=subprocess.DEVNULL, start_new_session=True) info = "0" - +#function to post info def post_info(info): - logging.info("Starting to post data...") + #log_info_with_server("Starting to post data...") info1 = info.strip() # Remove any leading/trailing whitespace, including newlines try: response = requests.post(info1, verify=False, timeout=3) - logging.info("Request sent, awaiting response...") response.raise_for_status() # Raise an error for bad status codes - logging.info("Data posted successfully: %s", response.text) + #log_info_with_server("Data posted successfully") except requests.exceptions.Timeout: - logging.warning("Request timed out. Saving data to backup file.") with open("./data/tag.txt", "a") as file: # Open in append mode file.write(info) - logging.info("Value %s was saved to tag.txt", info) + log_info_with_server(f"Value was saved to tag.txt") except requests.exceptions.RequestException as e: - logging.error("An error occurred: %s", e) with open("./data/tag.txt", "a") as file: # Open in append mode file.write(info) - logging.info("Value %s was saved to tag.txt", info) + log_info_with_server("Value was saved to tag.txt") + +async def post_info_async(info): + try: + # Try to use aiohttp if available + if 'aiohttp' in globals(): + async with aiohttp.ClientSession() as session: + try: + async with session.post(info, ssl=False, timeout=3) as response: + response_text = await response.text() + log_info_with_server(f"Data posted successfully") + except asyncio.TimeoutError: + with open("./data/tag.txt", "a") as file: + file.write(info) + except Exception as e: + with open("./data/tag.txt", "a") as file: + file.write(info) + else: + # Fallback to synchronous requests if aiohttp not available + try: + response = requests.post(info.strip(), verify=False, timeout=3) + response.raise_for_status() + log_info_with_server(f"Data posted successfully (fallback)") + except requests.exceptions.Timeout: + with open("./data/tag.txt", "a") as file: + file.write(info) + except requests.exceptions.RequestException as e: + with open("./data/tag.txt", "a") as file: + file.write(info) + except Exception as e: + # Final fallback - save to file + with open("./data/tag.txt", "a") as file: + file.write(info) def post_info_thread(info): - thread = threading.Thread(target=post_info, args=(info,)) - thread.start() + try: + thread = threading.Thread(target=asyncio.run, args=(post_info_async(info),), daemon=True) + thread.start() + except Exception as e: + # Fallback to synchronous posting if async fails + print(f"Async posting failed, using sync fallback: {e}") + post_info(info) -led1 = OutputDevice(23) -led2 = OutputDevice(24) +# Initialize LEDs with error handling +try: + print("Initializing LED controls...") + led1 = OutputDevice(23) + led2 = OutputDevice(24) + print("✓ LED controls initialized successfully") + log_info_with_server("LED controls initialized") +except Exception as e: + print(f"Warning: Could not initialize LED controls: {e}") + print("Creating dummy LED objects - visual feedback will be disabled") + # Create dummy LED objects that don't crash the app + class DummyLED: + def __init__(self, pin): + self.pin = pin + def on(self): + print(f"LED {self.pin} would turn ON") + def off(self): + print(f"LED {self.pin} would turn OFF") + + led1 = DummyLED(23) + led2 = DummyLED(24) + log_info_with_server("LED controls using dummy mode") + +# Initialize table name/ID +print("Initializing device configuration...") name = "idmasa" -logging.info(f"Variabila Id Masa A fost initializata", name) -f = open("./data/idmasa.txt", "r") # deschid fisierul -name = f.readline().strip() # citesc toate liniile -f.close() # inchid fisierul -logging.info(name) +logging.info("Variabila Id Masa A fost initializata ") +try: + with open("./data/idmasa.txt", "r") as f: + name = f.readline().strip() or "noconfig" + print(f"✓ Device name loaded: {name}") + log_info_with_server(f"Device name initialized: {name}") +except FileNotFoundError: + print("Warning: idmasa.txt not found, using default 'noconfig'") + name = "noconfig" + # Create the file with default value + try: + with open("./data/idmasa.txt", "w") as f: + f.write("noconfig") + print("✓ Created default idmasa.txt file") + except Exception as e: + print(f"Could not create idmasa.txt: {e}") +except Exception as e: + print(f"Error reading idmasa.txt: {e}") + name = "noconfig" + +logging.info(name) +#clasa reader class Reader(rdm6300.BaseReader): global info def card_inserted(self, card): if card.value == 12886709: - logging.info("Inserting Config Card") + + config() return - # config() - afisare = time.strftime("%Y-%m-%d&%H:%M:%S") - date = 'https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/' + name + '/' + str(card.value) + "/1/" + afisare + "\n" - info = date - logging.info(info) - post_info_thread(info) - led1.on() - logging.info(f"card inserted {card}") + afisare = time.strftime("%Y-%m-%d&%H:%M:%S") + date = f'https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/{name}/{card.value}/1/{afisare}\n' + info = date + if name == "noconfig": + led1.on() + time.sleep(5) + led1.off() + log_info_with_server(f"card inserted {card} but no") + else: + post_info_thread(info) + led1.on() + log_info_with_server(f"card inserted {card}") + + def card_removed(self, card): if card.value == 12886709: - logging.info("Removing Config card") + log_info_with_server("Removing Config card") return - # config() - afisare=time.strftime("%Y-%m-%d&%H:%M:%S") - date='https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/'+name+'/'+str(card.value)+"/0/"+afisare+"\n" + + afisare = time.strftime("%Y-%m-%d&%H:%M:%S") + date = f'https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/{name}/{card.value}/0/{afisare}\n' info = date - logging.info(info) - post_info_thread(info) - led1.off() - logging.info("Card removed") + if name == "noconfig": + led1.off() + log_info_with_server(f"card removed {card}") + else: + post_info_thread(info) + led1.off() + log_info_with_server(f"card removed {card}") + + +# Initialize RFID Reader with comprehensive error handling +def initialize_rfid_reader(): + """ + Initialize RFID reader with multiple device attempts and error handling + """ + print("Initializing RFID reader...") + + # List of possible serial devices in order of preference + serial_devices = ['/dev/ttyS0', '/dev/ttyAMA0', '/dev/ttyUSB0', '/dev/ttyACM0'] + + for device in serial_devices: + try: + print(f"Attempting to initialize RFID reader on {device}...") + r = Reader(device) + r.start() + print(f"✓ RFID reader successfully initialized on {device}") + log_info_with_server(f"RFID reader started on {device}") + return r + except FileNotFoundError: + print(f"✗ Device {device} not found") + continue + except PermissionError: + print(f"✗ Permission denied for {device}") + print(f" Hint: Try adding user to dialout group: sudo usermod -a -G dialout $USER") + continue + except Exception as e: + print(f"✗ Failed to initialize on {device}: {e}") + continue + + # If we get here, all devices failed + print("✗ Could not initialize RFID reader on any device") + print("Available solutions:") + print(" 1. Check hardware connections") + print(" 2. Enable UART: sudo raspi-config -> Interface Options -> Serial") + print(" 3. Add user to dialout group: sudo usermod -a -G dialout $USER") + print(" 4. Reboot the system after making changes") + + log_info_with_server("ERROR: RFID reader initialization failed") + return None + +# Start RFID reader try: - r = Reader('/dev/ttyS0') -except: - r = Reader('/dev/ttyAMA0') -r.start() + rfid_reader = initialize_rfid_reader() + if rfid_reader is None: + print("WARNING: Application starting without RFID functionality") + print("Card reading will not work until RFID reader is properly configured") +except Exception as e: + print(f"Critical error initializing RFID reader: {e}") + log_info_with_server(f"Critical RFID error: {str(e)}") + print("Application will start but RFID functionality will be disabled") diff --git a/cert.sh b/cert.sh deleted file mode 100644 index eafede4..0000000 --- a/cert.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/bash -# Instalare certificate -echo -e "\e[1;32m Copiem si instalam certificatele Harting \e[0m" -sudo mkdir /usr/local/share/ca-certificates/Harting -sudo cp -R /home/pi/Desktop/Prezenta/Files/reposytory/Harting/ /usr/local/share/ca-certificates/Harting/ - -sudo update-ca-certificates -sleep 3 -echo -e "\e[1;32m Instalam Libnss3-tool ca sa actualizam certificatele in Browser \e[0m" -sudo apt install libnss3-tools -echo -e "\e[1;32m Libnss3-tools este instalat \e[0m" -echo -e "\e[1;32m Cream baza de date pentru certutil \e[0m" -#sudo mkdir -p $HOME/.pki/nssdb -#sudo certutil -d $HOME/.pki/nssdb -N --empty-password -echo -e "\e[1;32m Baza de date a fost creata \e[0m" -echo -e "\e[1;32m Actualizam Certificate \e[0m" -certutil -d sql:$HOME/.pki/nssdb -A -t "CT,C,C" -n HA_MWG_new_cert -i /etc/ssl/certs/HA_MWG_new_cert.pem -echo "cert 1 ok" -sleep 3 -certutil -d sql:$HOME/.pki/nssdb -A -t "CT,C,C" -n HartingIssuingCA1.pem -i /etc/ssl/certs/HartingIssuingCA1.pem -echo "cert 2 Ok" -sleep 3 -certutil -d sql:$HOME/.pki/nssdb -A -t "CT,C,C" -n HartingRootCA.pem -i /etc/ssl/certs/HartingRootCA.pem -echo "cert 3 ok" -echo -e "\e[1;32m Certificatele au fost instalate \e[0m" -sleep 3 -certutil -d sql:$HOME/.pki/nssdb -L -sleep 3 \ No newline at end of file diff --git a/config.py b/config.py old mode 100755 new mode 100644 index ac3de50..ff15b94 --- a/config.py +++ b/config.py @@ -62,16 +62,14 @@ isFile = os.path.isfile(path) #verifica existenta fisierului prin bolean Tru/fal if not isFile: # print(path)# nu se face nimic pentru ca exista fisierul -#else: - fp = open('./data/idmasa.txt', 'w') # cream fisier - fp.write('no_config') # scriem in fisier prima line pentru a avea un punct de pornire + + fp = open("./data/idmasa.txt", 'w') # cream fisier + fp.write('noconfig') # scriem in fisier prima line pentru a avea un punct de pornire fp.close() # inchidem fisierul -# print("created file") + # verificam fisierul de prezenta pe baza acestuia stim daca locul de munca este configurat cu card de prezenta sau nu path1 = './data/idmasa.txt' #verificare existenta al doilea fisier isFile = os.path.isfile(path1)# verifica existenta fisierului -#print(path) - #urmeaza sa citim fisierele pentru a crea cateva variabile # prima variabila este idmasa @@ -82,16 +80,15 @@ try: idmasa = name[0]# se verifica daca exista informatie in text except IndexError: - idmasa = "Initial"# daca nu exista informatie in text setam variabila - + idmasa = "noconfig"# daca nu exista informatie in text setam variabila +n_config = 0 #incepem sa definim primele functii din configurare def notokfunction(): # este functie pentru butonul cancel din formular - - + global n_config msg1 = "Id masa a fost actualizat la: "+ idmasa +"" ## pregatim mesajul pentru fereastra pop up - + n_config = 1 msg2 = "Slotul Pentru cartela este configurat by default" # pregatim mesajul pentru fereastra pop up layout = [[sg.Text(msg1)], [sg.Text(msg2)], [sg.Button("Ok")]] window = sg.Window("Configurari", layout) @@ -107,6 +104,7 @@ def notokfunction(): # este functie pentru butonul cancel din formular #functia pentru butonul ok din formular def okfunction(): + global n_config if idmasa == config1: # variabila config 1 este preluata din formular msg1 = "Masa este setat corect: "+ idmasa +"" # se printeaza mesaj ca nu se actualizeaza id de masa # print(msg1) @@ -116,7 +114,7 @@ def okfunction(): f.write(L) # actualizam linia cu noua valuare din config f.close() # inchidem fisierul msg1 = "Id masa a fost actualizat la: "+ config1 +"" # pregatim mesajul pentru fereastra pop up - + n_config = 0 # # definim fereastra pentru ok asemena cu functia notok @@ -132,6 +130,7 @@ def okfunction(): break if nook == 1: notokfunction() + n_config = 1 time.sleep(2) #asteptam 10 secunde si pornim functia de setare printer set_printer() @@ -177,6 +176,7 @@ window = psg.Window('Form', layout, size=(800,190),finalize=True) # citim si configuram widgetul pentru butoanele 1 si 0 din randul while True: + nook = 0 # cream o variabila care sa ne spuna daca a fost setao butonul ok sau nu event, values = window.read() # citim valorile intr-o lista numita values host_conf= values[0] # atribuim primul item din lista variabilei Host config @@ -184,6 +184,7 @@ while True: print(host_conf) if event == sg.WIN_CLOSED or event == 'Cancel': nook = 1 # daca se da cancel setam variabila nook la 1 + n_config = 1 # setam variabila n_config la 1 break config1 = values[1] # atribuim lui config 1 valuarea din campul Loc de munca care a fost scris cu Id masa @@ -200,7 +201,8 @@ while True: window.close() # daca variabila nook este 1 time.sleep(2) -os.system("sudo reboot now") +if n_config == 0: + os.system("sudo reboot now") diff --git a/data/device_info.txt b/data/device_info.txt new file mode 100644 index 0000000..3ae3022 --- /dev/null +++ b/data/device_info.txt @@ -0,0 +1,2 @@ +RPI-ansible +127.0.1.1 diff --git a/data/idmasa.txt b/data/idmasa.txt index 6304b11..4513642 100644 --- a/data/idmasa.txt +++ b/data/idmasa.txt @@ -1 +1 @@ -not_config \ No newline at end of file +2_15051100_10 \ No newline at end of file diff --git a/data/log.txt b/data/log.txt index e69de29..cd681ca 100644 --- a/data/log.txt +++ b/data/log.txt @@ -0,0 +1,1079 @@ +2025-05-13 08:12:18,109 - INFO - Log file is not older than 10 days: log.txt (n_masa: notconfig) +2025-05-13 08:12:18,121 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')) +2025-05-13 08:12:18,131 - INFO - Internet connection check loaded (n_masa: notconfig) +2025-05-13 08:12:18,144 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')) +2025-05-13 08:12:18,145 - INFO - Log file is not older than 10 days: log.txt (n_masa: notconfig) +2025-05-13 08:12:18,151 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')) +2025-05-13 08:12:18,164 - INFO - Internet is down. Rebooting WiFi. (n_masa: notconfig) +2025-05-13 08:12:18,170 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')) +2025-05-13 08:12:18,171 - INFO - Variabila Id Masa A fost initializata +2025-05-13 08:12:18,172 - INFO - notconfig +2025-05-13 13:24:00,540 - INFO - Log file is not older than 10 days: log.txt (n_masa: notconfig) +2025-05-13 13:24:00,618 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-13 13:24:00,629 - INFO - Internet connection check loaded (n_masa: notconfig) +2025-05-13 13:24:00,669 - INFO - Variabila Id Masa A fost initializata +2025-05-13 13:24:00,670 - INFO - notconfig +2025-05-13 13:24:00,675 - INFO - Log successfully sent to server: Internet connection check loaded +2025-05-13 13:24:00,676 - INFO - Log file is not older than 10 days: log.txt (n_masa: notconfig) +2025-05-13 13:24:00,718 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-13 13:24:00,734 - INFO - Internet is up! Waiting 45 minutes. (n_masa: notconfig) +2025-05-13 13:24:00,779 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-13 13:24:00,780 - INFO - Reading backup data from tag.txt... (n_masa: notconfig) +2025-05-13 13:24:00,819 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-13 13:24:00,820 - INFO - Backup data updated. (n_masa: notconfig) +2025-05-13 13:24:00,861 - INFO - Log successfully sent to server: Backup data updated. +2025-05-13 13:24:15,331 - INFO - Inserting Config Card (n_masa: notconfig) +2025-05-13 13:24:15,462 - INFO - Log successfully sent to server: Inserting Config Card +2025-05-20 14:36:00,023 - INFO - Removing Config card (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,597 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,664 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-20 14:36:16,675 - INFO - Internet connection check loaded (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,710 - INFO - Variabila Id Masa A fost initializata +2025-05-20 14:36:16,711 - INFO - 3_66121G07_28 +2025-05-20 14:36:16,727 - INFO - Log successfully sent to server: Internet connection check loaded +2025-05-20 14:36:16,728 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,798 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-20 14:36:16,813 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,852 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-20 14:36:16,853 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,889 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-20 14:36:16,890 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-20 14:36:16,926 - INFO - Log successfully sent to server: Backup data updated. +2025-05-20 15:21:36,294 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-20 15:21:36,304 - INFO - An error occurred during internet check: [Errno -3] Temporary failure in name resolution (n_masa: 3_66121G07_28) +2025-05-20 22:15:27,953 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-20 22:15:28,035 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-20 22:15:28,046 - INFO - Internet connection check loaded (n_masa: 3_66121G07_28) +2025-05-20 22:15:28,076 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-20 22:15:28,077 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-20 22:15:28,090 - INFO - Variabila Id Masa A fost initializata +2025-05-20 22:15:28,091 - INFO - 3_66121G07_28 +2025-05-20 22:15:28,095 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-20 22:15:28,106 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-20 22:15:28,130 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-20 22:15:28,130 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-20 22:15:28,145 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-20 22:15:28,146 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-20 22:15:28,169 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-22 16:20:29,533 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 16:20:29,561 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-22 16:20:29,561 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 16:20:29,589 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-22 16:20:29,590 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 16:20:29,615 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-22 17:05:29,631 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 17:05:29,679 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 17:05:29,681 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 17:05:29,729 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 17:05:29,732 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 17:05:29,784 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 17:50:29,805 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 17:50:29,853 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 17:50:29,855 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 17:50:29,907 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 17:50:29,909 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 17:50:29,960 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 18:35:29,981 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 18:35:30,028 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 18:35:30,029 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 18:35:30,088 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 18:35:30,090 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 18:35:30,148 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 19:20:30,164 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 19:20:30,212 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 19:20:30,213 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 19:20:30,262 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 19:20:30,263 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 19:20:30,309 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 20:05:30,328 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 20:05:30,392 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 20:05:30,395 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 20:05:30,444 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 20:05:30,446 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 20:05:30,493 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 20:50:30,510 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 20:50:30,552 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 20:50:30,554 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 20:50:30,605 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 20:50:30,608 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 20:50:30,660 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 21:35:30,680 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 21:35:30,724 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 21:35:30,725 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 21:35:30,772 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 21:35:30,773 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 21:35:30,814 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 22:20:30,827 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 22:20:30,915 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 22:20:30,916 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 22:20:30,955 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 22:20:30,956 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 22:20:31,004 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 23:05:31,030 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 23:05:31,073 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 23:05:31,074 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 23:05:31,120 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 23:05:31,123 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 23:05:31,170 - INFO - Log successfully sent to server: Backup data updated. +2025-05-22 23:50:31,184 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-22 23:50:31,250 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-22 23:50:31,257 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-22 23:50:31,303 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-22 23:50:31,306 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-22 23:50:31,358 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 00:35:31,380 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 00:35:31,423 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 00:35:31,428 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 00:35:31,473 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 00:35:31,478 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 00:35:31,521 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 01:20:31,539 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 01:20:31,596 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 01:20:31,598 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 01:20:31,639 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 01:20:31,642 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 01:20:31,690 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 02:05:31,706 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 02:05:31,744 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 02:05:31,745 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 02:05:31,785 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 02:05:31,787 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 02:05:31,833 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 02:50:31,858 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 02:50:31,909 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 02:50:31,910 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 02:50:31,954 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 02:50:31,957 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 02:50:32,007 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 03:35:32,025 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 03:35:32,066 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 03:35:32,066 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 03:35:32,112 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 03:35:32,112 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 03:35:32,151 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 04:20:32,169 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 04:20:32,220 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 04:20:32,220 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 04:20:32,290 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 04:20:32,296 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 04:20:32,338 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 05:05:32,354 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 05:05:32,405 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 05:05:32,406 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 05:05:32,472 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 05:05:32,475 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 05:05:32,524 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 05:50:32,547 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 05:50:32,589 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 05:50:32,591 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 05:50:32,639 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 05:50:32,642 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 05:50:32,695 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 06:35:32,718 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 06:35:32,758 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 06:35:32,760 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 06:35:32,805 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 06:35:32,809 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 06:35:32,860 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 07:20:32,877 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 07:20:32,932 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 07:20:32,934 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 07:20:32,980 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 07:20:32,983 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 07:20:33,036 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 08:05:33,056 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 08:05:33,097 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 08:05:33,098 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 08:05:33,398 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 08:05:33,399 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 08:05:33,448 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 08:50:33,473 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 08:50:33,558 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 08:50:33,559 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 08:50:33,603 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 08:50:33,603 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 08:50:33,654 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 09:35:33,676 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 09:35:33,768 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 09:35:33,769 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 09:35:33,812 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 09:35:33,814 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 09:35:33,863 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 10:20:33,883 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 10:20:33,983 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 10:20:33,985 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 10:20:34,032 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 10:20:34,035 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 10:20:34,084 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 11:05:34,102 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 11:05:34,151 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 11:05:34,152 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 11:05:34,190 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 11:05:34,191 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 11:05:34,480 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 11:50:34,499 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 11:50:34,592 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 11:50:34,592 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 11:50:34,637 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 11:50:34,638 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 11:50:34,676 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 12:35:34,697 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 12:35:34,798 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 12:35:34,799 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 12:35:34,850 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 12:35:34,852 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 12:35:34,906 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 13:20:34,925 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 13:20:35,118 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 13:20:35,121 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 13:20:35,164 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 13:20:35,169 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 13:20:35,223 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 14:05:35,241 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 14:05:35,326 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 14:05:35,327 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 14:05:35,365 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 14:05:35,366 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 14:05:35,407 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 14:50:35,429 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 14:50:35,534 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 14:50:35,535 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 14:50:35,570 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 14:50:35,571 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 14:50:35,615 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 15:35:35,627 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 15:35:35,735 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 15:35:35,736 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 15:35:35,788 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 15:35:35,789 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 15:35:35,864 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 16:20:35,885 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 16:20:35,955 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 16:20:35,956 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 16:20:35,999 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 16:20:36,000 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 16:20:36,048 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 17:05:36,071 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 17:05:36,116 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 17:05:36,117 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 17:05:36,160 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 17:05:36,162 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 17:05:36,201 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 17:50:36,225 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 17:50:36,371 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 17:50:36,372 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 17:50:36,411 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 17:50:36,412 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 17:50:36,459 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 18:35:36,474 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 18:35:36,578 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 18:35:36,578 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 18:35:36,623 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 18:35:36,624 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 18:35:36,669 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 19:20:36,682 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 19:20:36,795 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 19:20:36,797 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 19:20:36,844 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 19:20:36,848 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 19:20:36,903 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 20:05:36,923 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 20:05:36,993 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 20:05:36,994 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 20:05:37,036 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 20:05:37,037 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 20:05:37,083 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 20:50:37,102 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 20:50:37,145 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 20:50:37,145 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 20:50:37,190 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 20:50:37,193 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 20:50:37,241 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 21:35:37,260 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 21:35:37,308 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 21:35:37,309 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 21:35:37,361 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 21:35:37,361 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 21:35:37,410 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 22:20:37,431 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 22:20:37,529 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 22:20:37,530 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 22:20:37,574 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 22:20:37,575 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 22:20:37,617 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 23:05:37,644 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 23:05:37,740 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 23:05:37,741 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 23:05:37,784 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 23:05:37,785 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 23:05:37,821 - INFO - Log successfully sent to server: Backup data updated. +2025-05-23 23:50:37,832 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-23 23:50:37,947 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-23 23:50:37,949 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-23 23:50:37,997 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-23 23:50:38,000 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-23 23:50:38,059 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 00:35:38,082 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 00:35:38,157 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 00:35:38,159 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 00:35:38,204 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 00:35:38,205 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 00:35:38,276 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 01:20:38,302 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 01:20:38,497 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 01:20:38,499 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 01:20:38,798 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 01:20:38,801 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 01:20:39,163 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 02:05:39,181 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 02:05:39,272 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 02:05:39,273 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 02:05:39,310 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 02:05:39,312 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 02:05:39,356 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 02:50:39,372 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 02:50:39,411 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 02:50:39,412 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 02:50:39,476 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 02:50:39,480 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 02:50:39,802 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 03:35:39,819 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 03:35:39,858 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 03:35:39,858 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 03:35:39,911 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 03:35:39,912 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 03:35:39,960 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 04:20:39,980 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 04:20:40,031 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 04:20:40,033 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 04:20:40,077 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 04:20:40,080 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 04:20:40,131 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 05:05:40,149 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 05:05:40,192 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 05:05:40,194 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 05:05:40,263 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 05:05:40,264 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 05:05:41,319 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 05:50:41,337 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 05:50:41,381 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 05:50:41,383 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 05:50:41,431 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 05:50:41,433 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 05:50:41,490 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 06:35:41,515 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 06:35:41,578 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 06:35:41,579 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 06:35:41,617 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 06:35:41,618 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 06:35:41,667 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 07:20:41,684 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 07:20:41,783 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 07:20:41,783 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 07:20:41,821 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 07:20:41,822 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 07:20:41,869 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 08:05:41,887 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 08:05:41,929 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 08:05:41,929 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 08:05:41,979 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 08:05:41,980 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 08:05:42,022 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 08:50:42,049 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 08:50:42,095 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 08:50:42,095 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 08:50:42,141 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 08:50:42,143 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 08:50:42,447 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 09:35:42,470 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 09:35:42,601 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 09:35:42,602 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 09:35:42,643 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 09:35:42,647 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 09:35:42,698 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 10:20:42,716 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 10:20:42,763 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 10:20:42,763 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 10:20:42,808 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 10:20:42,809 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 10:20:42,848 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 11:05:42,871 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 11:05:43,934 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 11:05:43,935 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 11:05:43,977 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 11:05:43,978 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 11:05:44,029 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 11:50:44,044 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 11:50:44,150 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 11:50:44,151 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 11:50:44,197 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 11:50:44,197 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 11:50:44,274 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 12:35:44,289 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 12:35:44,329 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 12:35:44,331 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 12:35:44,385 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 12:35:44,386 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 12:35:44,426 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 13:20:44,445 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 13:20:44,496 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 13:20:44,500 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 13:20:44,555 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 13:20:44,557 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 13:20:44,599 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 14:05:44,611 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 14:05:44,659 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 14:05:44,659 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 14:05:44,697 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 14:05:44,699 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 14:05:44,740 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 14:50:44,761 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 14:50:44,815 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 14:50:44,818 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 14:50:44,879 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 14:50:44,883 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 14:50:44,924 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 15:35:44,948 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 15:35:45,035 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 15:35:45,037 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 15:35:45,079 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 15:35:45,081 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 15:35:45,125 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 16:20:45,141 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 16:20:45,192 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 16:20:45,193 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 16:20:45,247 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 16:20:45,249 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 16:20:45,310 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 17:05:45,329 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 17:05:45,378 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 17:05:45,380 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 17:05:45,432 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 17:05:45,435 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 17:05:45,484 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 17:50:45,501 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 17:50:45,540 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 17:50:45,541 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 17:50:45,584 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 17:50:45,586 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 17:50:45,631 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 18:35:45,649 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 18:35:45,705 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 18:35:45,707 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 18:35:45,754 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 18:35:45,757 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 18:35:45,798 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 19:20:45,820 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 19:20:45,945 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 19:20:45,946 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 19:20:45,984 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 19:20:45,985 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 19:20:46,027 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 20:05:46,039 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 20:05:46,078 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 20:05:46,079 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 20:05:46,122 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 20:05:46,123 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 20:05:46,175 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 20:50:46,193 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 20:50:46,237 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 20:50:46,238 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 20:50:46,280 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 20:50:46,281 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 20:50:46,324 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 21:35:46,343 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 21:35:46,396 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 21:35:46,399 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 21:35:46,443 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 21:35:46,446 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 21:35:46,490 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 22:20:46,508 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 22:20:46,554 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 22:20:46,555 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 22:20:46,595 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 22:20:46,598 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 22:20:46,649 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 23:05:46,668 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 23:05:46,709 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 23:05:46,709 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 23:05:46,752 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 23:05:46,754 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 23:05:46,796 - INFO - Log successfully sent to server: Backup data updated. +2025-05-24 23:50:46,820 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-24 23:50:46,869 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-24 23:50:46,872 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-24 23:50:46,915 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-24 23:50:46,916 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-24 23:50:46,960 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 00:35:46,979 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 00:35:47,025 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 00:35:47,027 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 00:35:47,074 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 00:35:47,076 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 00:35:47,121 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 01:20:47,134 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 01:20:47,183 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 01:20:47,183 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 01:20:47,229 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 01:20:47,230 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 01:20:47,285 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 02:05:47,297 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 02:05:47,354 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 02:05:47,356 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 02:05:47,402 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 02:05:47,407 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 02:05:47,450 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 02:50:47,475 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 02:50:47,517 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 02:50:47,518 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 02:50:47,566 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 02:50:47,567 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 02:50:47,606 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 03:35:47,629 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 03:35:47,674 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 03:35:47,676 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 03:35:47,722 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 03:35:47,726 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 03:35:47,775 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 04:20:47,794 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 04:20:47,914 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 04:20:47,914 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 04:20:47,955 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 04:20:47,956 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 04:20:47,991 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 05:05:48,007 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 05:05:48,050 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 05:05:48,051 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 05:05:48,098 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 05:05:48,099 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 05:05:48,141 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 05:50:48,159 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 05:50:48,211 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 05:50:48,213 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 05:50:48,257 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 05:50:48,269 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 05:50:48,314 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 06:35:48,325 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 06:35:48,444 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 06:35:48,445 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 06:35:48,497 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 06:35:48,500 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 06:35:48,546 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 07:20:48,564 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 07:20:48,862 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 07:20:48,864 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 07:20:48,917 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 07:20:48,921 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 07:20:48,964 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 08:05:48,977 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 08:05:49,061 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 08:05:49,062 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 08:05:49,101 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 08:05:49,103 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 08:05:49,145 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 08:50:49,165 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 08:50:49,273 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 08:50:49,274 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 08:50:49,315 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 08:50:49,315 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 08:50:49,351 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 09:35:49,369 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 09:35:49,473 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 09:35:49,474 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 09:35:49,508 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 09:35:49,509 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 09:35:49,555 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 10:20:49,569 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 10:20:49,688 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 10:20:49,689 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 10:20:49,738 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 10:20:49,739 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 10:20:49,785 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 11:05:49,797 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 11:05:49,897 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 11:05:49,899 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 11:05:49,960 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 11:05:49,963 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 11:05:50,010 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 11:50:50,034 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 11:50:50,105 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 11:50:50,106 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 11:50:50,151 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 11:50:50,154 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 11:50:50,205 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 12:35:50,223 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 12:35:50,309 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 12:35:50,311 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 12:35:50,353 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 12:35:50,355 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 12:35:50,405 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 13:20:50,428 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 13:20:50,517 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 13:20:50,517 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 13:20:50,556 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 13:20:50,557 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 13:20:50,600 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 14:05:50,621 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 14:05:50,660 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 14:05:50,661 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 14:05:50,700 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 14:05:50,703 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 14:05:50,748 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 14:50:50,766 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 14:50:50,827 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 14:50:50,829 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 14:50:50,896 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 14:50:50,897 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 14:50:50,945 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 15:35:50,968 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 15:35:51,015 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 15:35:51,016 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 15:35:51,057 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 15:35:51,060 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 15:35:51,106 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 16:20:51,131 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 16:20:51,239 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 16:20:51,240 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 16:20:51,290 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 16:20:51,292 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 16:20:51,343 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 17:05:51,361 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 17:05:51,412 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 17:05:51,414 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 17:05:51,468 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 17:05:51,474 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 17:05:51,520 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 17:50:51,538 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 17:50:51,656 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 17:50:51,656 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 17:50:51,691 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 17:50:51,692 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 17:50:51,734 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 18:35:51,750 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 18:35:51,787 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 18:35:51,789 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 18:35:51,838 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 18:35:51,844 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 18:35:51,887 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 19:20:51,904 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 19:20:52,068 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 19:20:52,069 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 19:20:52,106 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 19:20:52,108 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 19:20:52,154 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 20:05:52,168 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 20:05:52,271 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 20:05:52,272 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 20:05:52,319 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 20:05:52,320 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 20:05:52,384 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 20:50:52,405 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 20:50:52,483 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 20:50:52,484 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 20:50:52,518 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 20:50:52,519 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 20:50:52,560 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 21:35:52,579 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 21:35:52,693 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 21:35:52,693 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 21:35:52,734 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 21:35:52,735 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 21:35:52,777 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 22:20:52,799 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 22:20:53,107 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 22:20:53,108 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 22:20:53,156 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 22:20:53,161 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 22:20:53,205 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 23:05:53,224 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 23:05:53,276 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 23:05:53,278 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 23:05:53,331 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 23:05:53,335 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 23:05:53,392 - INFO - Log successfully sent to server: Backup data updated. +2025-05-25 23:50:53,410 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-25 23:50:53,522 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-25 23:50:53,524 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-25 23:50:53,567 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-25 23:50:53,573 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-25 23:50:53,622 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 00:35:53,644 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 00:35:53,729 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 00:35:53,730 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 00:35:53,770 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 00:35:53,773 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 00:35:53,833 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 01:20:53,844 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 01:20:53,932 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 01:20:53,934 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 01:20:54,012 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 01:20:54,015 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 01:20:54,063 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 02:05:54,080 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 02:05:54,144 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 02:05:54,146 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 02:05:54,194 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 02:05:54,198 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 02:05:54,246 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 02:50:54,265 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 02:50:54,317 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 02:50:54,320 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 02:50:54,369 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 02:50:54,371 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 02:50:54,417 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 03:35:54,434 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 03:35:54,560 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 03:35:54,562 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 03:35:54,598 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 03:35:54,599 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 03:35:54,640 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 04:20:54,657 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 04:20:54,706 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 04:20:54,707 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 04:20:54,838 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 04:20:54,839 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 04:20:54,884 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 05:05:54,907 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 05:05:54,969 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 05:05:54,971 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 05:05:55,019 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 05:05:55,023 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 05:05:55,072 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 05:50:55,085 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 05:50:55,132 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 05:50:55,132 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 05:50:55,167 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 05:50:55,169 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 05:50:55,209 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 06:35:55,225 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 06:35:55,283 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 06:35:55,284 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 06:35:55,332 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 06:35:55,333 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 06:35:55,382 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 07:20:55,404 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 07:20:55,451 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 07:20:55,453 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 07:20:55,500 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 07:20:55,505 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 07:20:55,551 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 08:05:55,575 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 08:05:55,616 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 08:05:55,618 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 08:05:55,671 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 08:05:55,674 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 08:05:55,719 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 08:50:55,743 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 08:50:55,902 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 08:50:55,903 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 08:50:55,948 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 08:50:55,949 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 08:50:56,383 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 09:35:56,403 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 09:35:56,447 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 09:35:56,452 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 09:35:56,511 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 09:35:56,512 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 09:35:56,554 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 10:20:56,569 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 10:20:56,720 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 10:20:56,721 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 10:20:56,769 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 10:20:56,772 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 10:20:57,820 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 11:05:57,839 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 11:05:57,970 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 11:05:57,971 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 11:05:58,014 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 11:05:58,018 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 11:05:58,079 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 11:50:58,103 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 11:50:58,145 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 11:50:58,146 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 11:50:58,186 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 11:50:58,190 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 11:50:58,264 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 12:35:58,280 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 12:35:58,370 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 12:35:58,372 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 12:35:58,680 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 12:35:58,683 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 12:35:58,753 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 13:20:58,773 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 13:20:58,897 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 13:20:58,898 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 13:20:59,256 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 13:20:59,259 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 13:20:59,306 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 14:05:59,322 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 14:05:59,382 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 14:05:59,386 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 14:05:59,444 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 14:05:59,446 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 14:05:59,544 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 14:50:59,566 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 14:50:59,719 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 14:50:59,720 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 14:50:59,770 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 14:50:59,771 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 14:50:59,815 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 15:35:59,829 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 15:35:59,868 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 15:35:59,869 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 15:35:59,913 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 15:35:59,914 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 15:35:59,974 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 16:20:59,992 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 16:21:00,153 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 16:21:00,155 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 16:21:00,232 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 16:21:00,240 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 16:21:00,302 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 17:06:00,319 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 17:06:00,451 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 17:06:00,454 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 17:06:00,491 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 17:06:00,491 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 17:06:00,539 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 17:51:00,552 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 17:51:00,655 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 17:51:00,656 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 17:51:00,708 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 17:51:00,712 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 17:51:00,765 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 18:36:00,781 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 18:36:00,830 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 18:36:00,830 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 18:36:00,880 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 18:36:00,881 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 18:36:00,928 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 19:21:00,938 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 19:21:00,988 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 19:21:00,990 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 19:21:01,054 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 19:21:01,058 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 19:21:01,106 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 20:06:01,125 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 20:06:01,169 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 20:06:01,174 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 20:06:01,224 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 20:06:01,230 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 20:06:01,277 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 20:51:01,295 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 20:51:01,345 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 20:51:01,346 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 20:51:01,392 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 20:51:01,393 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 20:51:01,439 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 21:36:01,451 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 21:36:01,499 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 21:36:01,499 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 21:36:01,545 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 21:36:01,546 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 21:36:01,583 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 22:21:01,596 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 22:21:01,649 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 22:21:01,651 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 22:21:01,703 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 22:21:01,707 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 22:21:01,746 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 23:06:01,761 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 23:06:01,808 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 23:06:01,808 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 23:06:01,853 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 23:06:01,854 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 23:06:01,896 - INFO - Log successfully sent to server: Backup data updated. +2025-05-26 23:51:01,912 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-26 23:51:01,959 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-26 23:51:01,960 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-26 23:51:02,006 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-26 23:51:02,007 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-26 23:51:02,051 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 00:36:02,070 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 00:36:02,113 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 00:36:02,114 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 00:36:02,158 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 00:36:02,159 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 00:36:02,199 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 01:21:02,216 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 01:21:02,254 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 01:21:02,255 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 01:21:02,300 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 01:21:02,303 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 01:21:02,347 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 02:06:02,363 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 02:06:02,412 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 02:06:02,415 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 02:06:02,458 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 02:06:02,463 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 02:06:02,513 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 02:51:02,533 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 02:51:02,585 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 02:51:02,590 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 02:51:02,640 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 02:51:02,645 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 02:51:02,689 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 03:36:02,708 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 03:36:02,754 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 03:36:02,756 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 03:36:02,799 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 03:36:02,803 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 03:36:02,848 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 04:21:02,869 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 04:21:02,941 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 04:21:02,942 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 04:21:02,982 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 04:21:02,983 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 04:21:03,027 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 05:06:03,046 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 05:06:03,092 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 05:06:03,094 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 05:06:03,137 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 05:06:03,143 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 05:06:03,188 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 05:51:03,202 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 05:51:03,252 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 05:51:03,254 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 05:51:03,317 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 05:51:03,319 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 05:51:03,362 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 06:36:03,388 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 06:36:03,437 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 06:36:03,437 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 06:36:03,478 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 06:36:03,479 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 06:36:03,519 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 07:21:03,547 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 07:21:03,588 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 07:21:03,590 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 07:21:03,629 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 07:21:03,632 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 07:21:03,680 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 08:06:03,699 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 08:06:03,747 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 08:06:03,748 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 08:06:03,792 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 08:06:03,794 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 08:06:03,842 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 08:51:03,861 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 08:51:03,969 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 08:51:03,971 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 08:51:04,025 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 08:51:04,028 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 08:51:04,077 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 09:36:04,093 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 09:36:04,275 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 09:36:04,277 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 09:36:04,457 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 09:36:04,460 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 09:36:04,666 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 09:55:15,856 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-27 09:55:15,939 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-27 09:55:15,951 - INFO - Internet connection check loaded (n_masa: 3_66121G07_28) +2025-05-27 09:55:15,989 - INFO - Variabila Id Masa A fost initializata +2025-05-27 09:55:15,991 - INFO - 3_66121G07_28 +2025-05-27 09:55:16,000 - INFO - Log successfully sent to server: Internet connection check loaded +2025-05-27 09:55:16,001 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-27 09:55:16,040 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-27 09:55:16,052 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 09:55:16,086 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 09:55:16,087 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 09:55:16,128 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 09:55:16,129 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 09:55:16,165 - INFO - Log successfully sent to server: Backup data updated. +2025-05-27 10:32:52,603 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-27 10:32:52,758 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-27 10:32:52,770 - INFO - Internet connection check loaded (n_masa: 3_66121G07_28) +2025-05-27 10:32:52,817 - INFO - Variabila Id Masa A fost initializata +2025-05-27 10:32:52,818 - INFO - 3_66121G07_28 +2025-05-27 10:32:52,824 - INFO - Log successfully sent to server: Internet connection check loaded +2025-05-27 10:32:52,825 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-27 10:32:52,872 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-27 10:32:52,885 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-27 10:32:52,930 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-27 10:32:52,931 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-27 10:32:52,963 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-27 10:32:52,965 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-27 10:32:53,003 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 08:05:52,819 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 08:05:52,946 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 08:05:52,947 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 08:05:53,003 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 08:05:53,004 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 08:05:53,057 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 08:50:53,070 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 08:50:53,148 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 08:50:53,148 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 08:50:53,183 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 08:50:53,184 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 08:50:53,228 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 09:35:53,244 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 09:35:53,281 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 09:35:53,282 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 09:35:53,327 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 09:35:53,328 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 09:35:53,365 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 10:20:53,380 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 10:20:53,438 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 10:20:53,439 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 10:20:53,484 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 10:20:53,485 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 10:20:53,527 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 11:05:53,540 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 11:05:53,639 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 11:05:53,640 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 11:05:53,684 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 11:05:53,684 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 11:05:53,732 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 11:50:53,754 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 11:50:53,828 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 11:50:53,831 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 11:50:53,874 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 11:50:53,876 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 11:50:53,915 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 12:16:02,168 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-28 12:16:02,269 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-28 12:16:02,280 - INFO - Internet connection check loaded (n_masa: 3_66121G07_28) +2025-05-28 12:16:02,312 - INFO - Variabila Id Masa A fost initializata +2025-05-28 12:16:02,313 - INFO - 3_66121G07_28 +2025-05-28 12:16:02,323 - INFO - Log successfully sent to server: Internet connection check loaded +2025-05-28 12:16:02,324 - INFO - Log file is not older than 10 days: log.txt (n_masa: 3_66121G07_28) +2025-05-28 12:16:02,362 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-28 12:16:02,377 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 12:16:02,415 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 12:16:02,416 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 12:16:02,467 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 12:16:02,468 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 12:16:02,515 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 13:02:46,407 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 13:02:46,537 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 13:02:46,538 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 13:02:46,578 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 13:02:46,579 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 13:02:46,621 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 13:47:46,644 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 13:47:46,686 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 13:47:46,687 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 13:47:46,727 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 13:47:46,729 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 13:47:46,768 - INFO - Log successfully sent to server: Backup data updated. +2025-05-28 14:32:46,779 - INFO - Internet is up! Waiting 45 minutes. (n_masa: 3_66121G07_28) +2025-05-28 14:32:51,808 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by ConnectTimeoutError(, 'Connection to rpi-ansible timed out. (connect timeout=5)')) +2025-05-28 14:32:51,813 - INFO - Reading backup data from tag.txt... (n_masa: 3_66121G07_28) +2025-05-28 14:32:56,836 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by ConnectTimeoutError(, 'Connection to rpi-ansible timed out. (connect timeout=5)')) +2025-05-28 14:32:56,839 - INFO - Backup data updated. (n_masa: 3_66121G07_28) +2025-05-28 14:32:57,903 - ERROR - Failed to send log to server: HTTPConnectionPool(host='rpi-ansible', port=80): Max retries exceeded with url: /logs (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused')) +2025-05-28 15:21:01,280 - INFO - Log file is not older than 10 days: log.txt (n_masa: notconfig) +2025-05-28 15:21:01,296 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-28 15:21:01,301 - INFO - Internet connection check loaded (n_masa: notconfig) +2025-05-28 15:21:01,312 - INFO - Variabila Id Masa A fost initializata +2025-05-28 15:21:01,312 - INFO - notconfig +2025-05-28 15:21:01,326 - INFO - Log successfully sent to server: Internet connection check loaded +2025-05-28 15:21:01,326 - INFO - Log file is not older than 10 days: log.txt (n_masa: notconfig) +2025-05-28 15:21:01,343 - INFO - Log successfully sent to server: Log file is not older than 10 days: log.txt +2025-05-28 15:21:01,354 - INFO - Internet is up! Waiting 45 minutes. (n_masa: notconfig) +2025-05-28 15:21:01,371 - INFO - Log successfully sent to server: Internet is up! Waiting 45 minutes. +2025-05-28 15:21:01,371 - INFO - Reading backup data from tag.txt... (n_masa: notconfig) +2025-05-28 15:21:01,396 - INFO - Log successfully sent to server: Reading backup data from tag.txt... +2025-05-28 15:21:01,397 - INFO - Backup data updated. (n_masa: notconfig) +2025-05-28 15:21:01,468 - INFO - Log successfully sent to server: Backup data updated. diff --git a/data/tag.txt b/data/tag.txt index e69de29..5c79a10 100644 --- a/data/tag.txt +++ b/data/tag.txt @@ -0,0 +1,2 @@ +https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/notconfig/7955261/1/2025-05-28&16:37:20 +https://dataswsibiusb01.sibiusb.harting.intra/RO_Quality_PRD/api/record/notconfig/7955261/0/2025-05-28&16:37:29 diff --git a/libraries.sh b/libraries.sh old mode 100644 new mode 100755 index 8f02d17..8aff97a --- a/libraries.sh +++ b/libraries.sh @@ -11,4 +11,7 @@ pip3 install /home/pi/Desktop/Prezenta/Files/reposytory/rdm6300-0.1.1-py3-none-a pip3 install /home/pi/Desktop/Prezenta/Files/reposytory/typing_extensions-4.11.0-py3-none-any.whl -f ./ --no-index --no-deps --break-system-packages pip3 install /home/pi/Desktop/Prezenta/Files/reposytory/FreeSimpleGUI-5.0.0-py3-none-any.whl -f ./ --no-index --no-deps --break-system-packages pip3 install /home/pi/Desktop/Prezenta/Files/reposytory/func_timeout-4.3.5-py3-none-any.whl -f ./ --no-index --no-deps --break-system-packages +sudo chmod a+r /home/pi/Desktop/Aiohttp/python3-aiohttp.deb +sudo apt install /home/pi/Desktop/Aiohttp/python3-aiohttp.deb + echo -e "\e[1;32m Librariile au fost instalate cu succes \e[0m" \ No newline at end of file diff --git a/setup_port_capability.sh b/setup_port_capability.sh new file mode 100755 index 0000000..47bd044 --- /dev/null +++ b/setup_port_capability.sh @@ -0,0 +1,31 @@ +#!/bin/bash + +# Grant the Python executable the capability to bind to privileged ports (like port 80) +# This is safer than running the entire application as root + +echo "Setting up Python to bind to privileged ports..." + +# Get the Python executable path and resolve symbolic links +PYTHON_PATH=$(which python3) +REAL_PYTHON_PATH=$(readlink -f "$PYTHON_PATH") +echo "Python path: $PYTHON_PATH" +echo "Real Python path: $REAL_PYTHON_PATH" + +# Set the capability on the real executable +sudo setcap 'cap_net_bind_service=+ep' "$REAL_PYTHON_PATH" + +if [ $? -eq 0 ]; then + echo "✓ Successfully granted port binding privileges to Python" + echo "Your Flask app can now bind to port 80 without running as root" + + # Verify the capability was set + echo "Verifying capability:" + getcap "$REAL_PYTHON_PATH" +else + echo "✗ Failed to set capability" + echo "Make sure you have libcap2-bin installed: sudo apt install libcap2-bin" +fi + +echo "" +echo "Note: After setting this capability, you can change your Flask app to use port 80" +echo "Change the port from 5000 to 80 in your app.py file"