C4W4 - Capstone Project Part 1 - Terraform Apply Error : Database Already Exists

I am getting this error:

Error: creating Glue Catalog Database (de_c4w4a1_silver_db): operation error Glue: CreateDatabase, https response error StatusCode: 400, RequestID: e0ae3d83-27d5-4148-bfe1-b4463194b6ed, AlreadyExistsException: Database already exists.



  with module.transform_job.aws_glue_catalog_database.transform_db,

  on modules/transform_job/glue.tf line 2, in resource "aws_glue_catalog_database" "transform_db":

   2: resource "aws_glue_catalog_database" "transform_db" {

Question: Why Terraform is not understanding that the DB already exists and it doesn’t need to do anything about it? What are the next steps?

I don’t see any Glue databases that I can delete.

This is happening after lab refresh

Hello @hawraa.salami,

It seems that after the lab refresh there is still an issue with @tanmayb lab. Could you check it please if he submits a new form. Sorry for the inconvenience and it seems you need to submit again for a lab refresh to fix that issue. Thank you

form filled

Week4 labs are the biggest bane of my existence at the moment its been 1 month now That I am stuck in the part1 lab with already 2 lab refresh already done. Its either that the terraform apply keeps failing for one reason or the other and when it did succeed the jobs keep failing. Once I fix the issue with the jobs the lab expires and then terraform fails again. its like a viscious cycle. Its getting frustrating and costing me a lot of money

Hello @AritraDasRay,

Yeah I understand you can tell that since most of the issues are from week 4 labs. However I am also waiting for a lab refresh on 1st capstone after my lab exceeded 1800 minutes or so. I could get back even tomorrow if things go well so I won’t have to wait for the weekend to end.

I can’t imagine being stuck over a month. The advice on this lab is to update the api endpoint for api ingestion jobs and use the bloody Pacific dates on transformation ones. Most of tha last part is optional if you get those outputs right. I am happy more than help if there is something you don’t already know, thank you

Hello @tanmayb,

Just checking, it seems I had my lab refreshed today as well. Could you check if you get the same issue. Thank you

Hello @tanmayb ! Please let me know if you need any help completing the capstone part 1.

1 Like

Thank you @hawraa.salami and @Georgios . I am good with Part 1.

1 Like

I am running into this problem too, any solution?