Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using MySQL base image produces errors in task terminals #18491

Closed
JuJup opened this issue Aug 11, 2023 · 8 comments
Closed

Using MySQL base image produces errors in task terminals #18491

JuJup opened this issue Aug 11, 2023 · 8 comments
Labels
meta: stale This issue/PR is stale and will be closed soon team: team-experience type: bug Something isn't working

Comments

@JuJup
Copy link

JuJup commented Aug 11, 2023

Bug description

When using the gitpod/workspace-mysql image, the MySQL Setup produces a couple of errors in each terminal (tested on latest and gitpod/workspace-mysql:2023-02-27-14-39-56)

HISTFILE=/workspace/.gitpod/cmd-1 history -r; {
echo "init test 2"
} && {
echo "command test 2"
}
mysqld: Error on delete of '/workspace/mysql/mysqld_tmp_file_case_insensitive_test.lower-test' (OS errno 2 - No such file or directory)
mysqld: Error on delete of '/workspace/mysql/mysqld_tmp_file_case_insensitive_test.lower-test' (OS errno 2 - No such file or directory)
mysqld will log errors to /var/log/mysql/error.log
2023-08-11T08:35:57.482500Z 0 [ERROR] [MY-011065] [Server] Unable to determine if daemon is running: Invalid argument (rc=0).
2023-08-11T08:35:57.482548Z 0 [ERROR] [MY-010946] [Server] Failed to start mysqld daemon. Check mysqld error log.

The errors are not always the same, depending on how fast the terminal starts it might be more or even no error. However, the database is working fine so far, it's just the error outputs.

I suppose this is somehow caused by the mysql-bashrc-launch.sh script, which is executed via .bashrc.

Steps to reproduce

Creating simple .gitpod.yml and do gp validate or push and create a new workspace.
Then check the already opened terminals in VS Code.

image: gitpod/workspace-mysql

tasks:
  - name: Test 1
    init: echo "init test 1"
    command: echo "command test 1"
  - name: Test 2
    init: echo "init test 2"
    command: echo "command test 2"
  - name: Test 3
    init: echo "init test 3"
    command: echo "command test 3"
  - name: Test 4
    init: echo "init test 4"
    command: echo "command test 4"
  - name: Test 5
    init: echo "init test 5"
    command: echo "command test 5"

Workspace affected

No response

Expected behavior

No Error Messages, if there are no Errors.

Example repository

No response

Anything else?

After all - is there any reason why I should use this image and not simply start a MySQL Dockercontainer? That way I could even control the Version to be equivalent to my prod Database.

@JuJup JuJup added the type: bug Something isn't working label Aug 11, 2023
@JuJup
Copy link
Author

JuJup commented Aug 14, 2023

There seems to be another side effect - at least I think it's somehow connected.
When I use gp validate, the MySQL Server won't start properly, so all my cmd tasks that do a gp ports await 3306 are not executed. This is quite annoying as I can't really test my setup that way.

@axonasif
Copy link
Member

axonasif commented Aug 17, 2023

Hi @JuJup, thanks for reporting.
gitpod-io/workspace-images#1104 has an explanation for why this may be happening.

@akosyakov
Copy link
Member

We want to reconsider our mysql image to remove auto start magic. Curren bash scripts are breaking while several shells are racing. Instead you will add an explicit task to start mysql server it won't be done by sourcing bash scripts each time. It is already scheduled. cc @jeanp413 @laushinka

@JuJup
Copy link
Author

JuJup commented Nov 14, 2023

@akosyakov is there any PR or issue for what you described so I can check the current status?

@akosyakov
Copy link
Member

Sorry, unfortunately it was unscheduled because of other priorities.

Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the meta: stale This issue/PR is stale and will be closed soon label May 23, 2024
@JuJup
Copy link
Author

JuJup commented May 29, 2024

Is there any further development on the mysql base image? From what I see, the problem still occurs and in your documentation the workspace-mysql image is still mentioned as the preferred way to run mysql in Gitpod.

@github-actions github-actions bot removed the meta: stale This issue/PR is stale and will be closed soon label May 30, 2024
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the meta: stale This issue/PR is stale and will be closed soon label Aug 29, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
meta: stale This issue/PR is stale and will be closed soon team: team-experience type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants