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

Mutual influence when different CPU are fullload with experimental destroy #46

Closed
86542822 opened this issue Apr 19, 2019 · 5 comments
Closed
Assignees
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@86542822
Copy link

The server has N CPUs
Mount one of the CPUs fullload
./blade create cpu fullload --numcpu 1
{"code":200,"success":true,"result":"51d50db1faf4fb80"}

Then mount one of the CPUs fullload
./blade create cpu fullload --numcpu 1
{"code":200,"success":true,"result":"96a4b01617f5f2f7"}

Destroy one of the mount experiments
./blade destroy 51d50db1faf4fb80

At this time, both CPU mount experiments will be destroyed.

@xcaspar xcaspar added good first issue Good for newcomers help wanted Extra attention is needed kind/bug labels Apr 19, 2019
@zousheng zousheng assigned zousheng and unassigned zousheng Jan 16, 2020
@Super-long
Copy link
Contributor

I get it!

I figured out the problem after I followed the dlv to debug the entire life cycle of a destroy. This bug appears in chaosblade-exec-os instead of chaosblade, in fact the parameter that blade happens first to chaos_os is completely correct, but chaos_os screwed everything up,

The call stack of the problem is like this main.main -> cpu.(*cpuExecutor).Exec -> cpu.(*cpuExecutor).stop -> exec.Destroy. The uid setting in main.main is already wrong, But the actual problem is in exec.Destroy, Destroy does not consider uid at all when deleting exp, and directly deletes all processes with "chaos_os" and "cpu fullload" strings in Precossname.

I am solving this problem.

@Super-long
Copy link
Contributor

My idea is to divide into two steps, the first step is to correctly parse the uid in main.main, and the second is to add a function to delete the specified uid process in chaosblade-exec-os/exec/exec.go. what do you think of mr xcaspar? @xcaspar

@Super-long
Copy link
Contributor

hello everyone, I put the solution in chaosblade-io/chaosblade-spec-go#44

@Super-long
Copy link
Contributor

Super-long commented May 23, 2022

This is a new solution. chaosblade-io/chaosblade-exec-os#114 @tiny-x @xcaspar

@Icesource
Copy link
Contributor

@Super-long Could you please help me review the PR chaosblade-io/chaosblade-exec-os#118 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

5 participants