ubuntuairflowvirtualenvwindows-subsystem-for-linuxairflow-webserver

No response from gunicorn master within 120 seconds


Need assistance with launching my airflow webserver, the process takes longer than usual and I keep getting the same error.

[2023-11-02T01:46:30.297+0100] {webserver_command.py:225} ERROR - No response from gunicorn master within 120 seconds 
[2023-11-02T01:46:30.298+0100] {webserver_command.py:226} ERROR - Shutting down webserver

What I've done: Reinstalled Ubuntu cd project directory created a virtual environment. Set export AIRFLOW_HOME=pwd to my current directory Uninstalled and re-installed apache-airflow in the environment, migrate db and created admin-user changed both to 0

Here is what my current directory looks like: current directory

I suspect the issues might be in the configured $AIRFLOW_HOME as it impacts the .cfg file, but i'm really not familiar with the installation process. and would appreciate your assistance.

dags_folder = /mnt/c/Users/buasc/PycharmProjects/airflow/dags
sql_alchemy_conn = sqlite:////mnt/c/Users/buasc/PycharmProjects/airflow/airflow.db

Solution

  • Apparently, this issue was from the set-up to installing airflow, solving the problem meant uninstalling and restarting the process from scratch.

    Step 1: Enable linux properties on windows (windows 11)

    Step2: Visit Microsoft Store and download Ubuntu

    Step 3: Set up c directory.

    [automount]
    
    root = /
    options = "metadata"
    
    export AIRFLOW_HOME=/c/Users/<PARENT_DIR>/<PROJECT_DIR>
    

    Step 4: Install Packages.

    Install airflow:

    airflow users create \
       --username admin \
       --firstname Peter \
       --lastname Parker \
       --role Admin \
       --email spiderman@superhero.org
    

    then a prompt asks for you to set a login password

    The issue from the original attempt was having to mount with the /mnt/ prefix and not wanting to use docker. Very thankful for the following tutorials:

    https://towardsdatascience.com/run-apache-airflow-on-windows-10-without-docker-3c5754bb98b4

    https://www.freecodecamp.org/news/install-apache-airflow-on-windows-without-docker/