airflow-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anthony Joyce <anthony.jo...@omicronmedia.com>
Subject Re: Airflow-Init stuck at initialization
Date Mon, 16 Aug 2021 16:52:37 GMT
Hi Jed,

When I first had this working, I was able too connect to our local database without password.
I set the IP address the docker-airflow was trying to connect with (I believe it was a 172.18.*.*/16)
in pg_hba.conf as trust. However, I will try logging in via username and password and see
if that fixed the issue. It’s worth a shot.

Not sure why it worked last week. Weird.

Anthony

On Aug 16, 2021, at 12:47 PM, Jed Cunningham <jed@astronomer.io<mailto:jed@astronomer.io>>
wrote:

You don't often get email from jed@astronomer.io<mailto:jed@astronomer.io>. Learn why
this is important<http://aka.ms/LearnAboutSenderIdentification>
Your SQL_ALCHEMY_CONN doesn't have a password? Intentional? Did you redact that and forget
to replace it with `{pass}`?

On Mon, Aug 16, 2021 at 9:26 AM Anthony Joyce <anthony.joyce@omicronmedia.com<mailto:anthony.joyce@omicronmedia.com>>
wrote:
Sorry, that was on purpose. I redacted the host name and substituted for {host}.

Sent from my iPhone

On Aug 16, 2021, at 11:23 AM, Jarek Potiuk <jarek@potiuk.com<mailto:jarek@potiuk.com>>
wrote:


I am almost certain that you have the "{host}" things wrong. It looks like you are actually
trying to connect to "{host}" dns name - I presume you want to actually put "real" hostname
there or at use it from a variable of sorts, but it seems that this did not happen.

On Mon, Aug 16, 2021 at 4:33 PM Anthony Joyce <anthony.joyce@omicronmedia.com<mailto:anthony.joyce@omicronmedia.com>>
wrote:
Hi All,

Thank you for the help I have been provided on my last email. I am stuck yet again and do
not have many areas to turn to so I figured I would email the listserv again.

Airflow seems to be stuck initializing using docker-compose up airflow-init.

$ docker-compose up airflow-init
airflow-docker_redis_1 is up-to-date
Recreating airflow-docker_postgres_1 ... done
Recreating airflow-docker_airflow-init_1 ... done
Attaching to airflow-docker_airflow-init_1
airflow-init_1       | BACKEND=postgresql+psycopg2
airflow-init_1       | DB_HOST={host}
airflow-init_1       | DB_PORT=5432

I am using an already existing backend from our current local postgresql database. Weirdly
enough, I had this working last Monday. I made a slight change to my docker-compose.yaml file
(added extra_hosts to the yaml, ran it, got an error than removed it) and tried to reinitialized
the container only for airflow-init to hang.

I stumbled upon this stack overflow page: https://stackoverflow.com/questions/68415456/docker-compose-up-airflow-init-hangs-no-network-connection-between-containers
and looked at every step this user did. Everything checks out OK with me as well.

The container builds using the default settings but does not build anymore with my custom
AIRFLOW__CORE__SQL_ALCHEMY_CONN: postgresql+psycopg2://airflow:@{host}:5432/airflow. Also,
my postgresql db is configured correctly listening on all IP addresses other than localhost.
IP’s added to pg_hba.conf. IPtables looks good with no conflicts in firewall services. We
are just using one from what I can tell.

I’ve uninstalled completely and reinstalled. No change. I even set daemon.json to not use
IPV6…still no change. I feel as if I’ve tried everything with no luck.

If anyone has experienced this behavior before and offer some insight, that would be wonderful.
Otherwise, I’ll continue to troubleshoot.

Thanks all.




--
+48 660 796 129

Mime
View raw message