fix: failed to create the systemd experiment #147
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Signed-off-by: Yuaninga 1846225041@qq.com
Describe what this PR does / why we need it
This PR will fix the bug: failed to create the systemd experiment.
Does this pull request fix one issue?
bug report: the systemd stop experiment cannot be created #815
Describe how you did it
The
StopSystemdBin
will be no longer used in the code, butsystemctl stop service
that realized theStopSystemdBin
will be used directly.Describe how to verify it
1.Build a new chaos_os in the chaosblade-exec-os
cd chaosblade-exec-os
make build_linux
(on the Mac operating system)cd target/chaosblade-1.7.0/bin
2.Move the new chaos_os to the chaosblade-1.7.0 from the chaosblade-exec-os
scp chaos_os root@x.x.x.x:/root/chaosblade-1.7.0
3.Replace the old chaos_os
ssh root@x.x.x.x
cd chaosblade-1.7.0/bin
mv chaos_os chaos_os_old
cd ..
mv chaos_os bin/chaos_os
4.Create the systemd experiment
systemctl start test
systemctl status test
cd chaosblade-1.7.0
./blade create systemd stop --service test
Special notes for reviews
Create the test service managed by the systemd:
1.test.go
2.test.service
3.move test.service