Skip to main content

Install Qemu-guest-agent on Debian / Ubuntu

QEMU Guest Agent Installation Script

🇬🇧 English

📌 Overview

This script automates the installation and configuration of the qemu-guest-agent service on Debian/Ubuntu-based systems.

It is designed to be:

    Simple Clean Informative Safe to run multiple times (idempotent behavior)

    ⚙️ What the Script Does

      Clears the terminal for better readability Displays a visual banner Updates package lists (apt update) Upgrades installed packages (apt upgrade -y) Checks if qemu-guest-agent is already installed
        If installed → Skips installation If not → Installs it Checks if the service is running
          If running → Skips If not → Starts the service Checks if the service is enabled at boot
            If enabled → Skips If not → Enables it Verifies the final service status Displays a clear summary of all actions performed

            🎨 Output Features

              🟠 Orange → Processing steps 🟢 Green → Successful actions 🔴 Red → Failed actions

              Each step is verified and reports its real status.


              ▶️ Usage

              Option 1 – One-liner (quick run)

              apt update && apt install -y curl && clear && curl -s https://docs.greenhome.stream/attachments/38 | sudo bash
              

              Option 2 – Manual (safer)

              curl -s -o install.sh https://docs.greenhome.stream/attachments/38
              chmod +x install.sh
              sudo ./install.sh
              

              ⚠️ Requirements

                Debian / Ubuntu-based system Internet connection Root privileges (use sudo)

                🧾 Final Output

                At the end, the script shows a summary like:

                Package Status  : INSTALLED NOW / ALREADY INSTALLED
                Service Status  : STARTED NOW / ALREADY RUNNING
                Enable Status   : ENABLED NOW / ALREADY ENABLED
                Final State     : RUNNING / NOT RUNNING
                


                🇬🇷 Ελληνικά

                📌 Περιγραφή

                Αυτό το script αυτοματοποιεί την εγκατάσταση και ρύθμιση της υπηρεσίας qemu-guest-agent σε συστήματα Debian/Ubuntu.

                Είναι σχεδιασμένο να είναι:

                  Απλό Καθαρό Κατανοητό Ασφαλές για επαναλαμβανόμενη εκτέλεση

                  ⚙️ Τι κάνει το Script

                    Καθαρίζει την οθόνη (clear)

                    Εμφανίζει banner τίτλου

                    Ενημερώνει τα πακέτα (apt update)

                    Αναβαθμίζει το σύστημα (apt upgrade -y)

                    Ελέγχει αν είναι εγκατεστημένο το qemu-guest-agent

                      Αν υπάρχει → Το παραλείπει Αν όχι → Το εγκαθιστά

                      Ελέγχει αν η υπηρεσία τρέχει

                        Αν τρέχει → Το παραλείπει Αν όχι → Την εκκινεί

                        Ελέγχει αν είναι ενεργοποιημένη στο boot

                          Αν είναι → Το παραλείπει Αν όχι → Την ενεργοποιεί

                          Ελέγχει την τελική κατάσταση της υπηρεσίας

                          Εμφανίζει αναλυτική σύνοψη ενεργειών


                          🎨 Εμφάνιση

                            🟠 Πορτοκαλί → Επεξεργασία 🟢 Πράσινο → Επιτυχία 🔴 Κόκκινο → Αποτυχία

                            Κάθε βήμα επαληθεύεται και εμφανίζει πραγματικό αποτέλεσμα.


                            ▶️ Χρήση

                            Επιλογή 1 – Γρήγορη εκτέλεση

                            apt update && apt install -y curl && clear && curl -s https://docs.greenhome.stream/attachments/38 | sudo bash
                            

                            Επιλογή 2 – Χειροκίνητα (πιο ασφαλές)

                            curl -s -o install.sh https://docs.greenhome.stream/attachments/38
                            chmod +x install.sh
                            sudo ./install.sh
                            

                            ⚠️ Απαιτήσεις

                              Σύστημα Debian / Ubuntu Σύνδεση στο internet Δικαιώματα root (sudo)

                              🧾 Τελική Σύνοψη

                              Στο τέλος εμφανίζεται:

                              Package Status  : INSTALLED NOW / ALREADY INSTALLED
                              Service Status  : STARTED NOW / ALREADY RUNNING
                              Enable Status   : ENABLED NOW / ALREADY ENABLED
                              Final State     : RUNNING / NOT RUNNING