--- title: "Start System Service" slug: "start-system-service" updated: 2024-10-10T09:36:47Z published: 2024-10-10T09:36:47Z canonical: "help.scalefusion.com/start-system-service" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.scalefusion.com/llms.txt > Use this file to discover all available pages before exploring further. # Start System Service Use this script to start the System services on Linux machines. 1. Copy and save the contents below to a **UTF-8** editor like **notepad++** OR **Sublime Text** in Windows or **gedit** in Ubuntu. 1. If you are using **notepad++** then use the bottom right panel to change the type to **Unix (LF)**. 2. Or click [here](https://cdn.document360.io/175c0eac-012f-4410-bdc5-ac60794f82d8/Images/Documentation/System_Service_Status(1).sh) to download the file. ```bash #!/bin/bash # Define the service names to start service_names=("Service1" "Service2") # Function to check if a service is already running check_service_status() {    local service_name="$1"    if systemctl is-active --quiet "$service_name"; then        echo "Service $service_name is already running."        return 0  # Service is already running    else        return 1  # Service is not running    fi } # Start each service for service_name in "${service_names[@]}"; do    # Check if the service is already running    if check_service_status "$service_name"; then        continue  # Skip starting the service if it's already running    fi    # Start the service    sudo systemctl start "$service_name"    # Check if the service started successfully    if [ $? -eq 0 ]; then        echo "Service $service_name started successfully."    else        echo "Failed to start service $service_name."    fi done ``` 3. In the script, replace the following placeholder: 1. Provide the service(s) name in the script. # Define the service names to start service_names=("Service1" "Service2") 2. For example, service_names=("ssh" "NetworkManager" "systemd-journald") ![](https://cdn.document360.io/175c0eac-012f-4410-bdc5-ac60794f82d8/Images/Documentation/image-P3ID4AXW.png) 4. Follow [our guide](/docs/deploy-linux-shell-scripts-using-scalefusion#step-1-upload-and-deploy-the-script) to upload & publish the script using Scalefusion Dashboard. > [!CAUTION] > Note: > > 1. Some of the scripts and their contents are sourced from internet and yes, our new friend ChatGPT. > 2. Please validate the scripts on a test machine before deploying them on all your managed devices. > 3. Scalefusion has tested these scripts, however Scalefusion will not be responsible for any loss of data or system malfunction that may arise due to the usage of these scripts.