mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 19:56:01 +00:00
Merge pull request #12372 from a-robinson/ifup
Replace usage of ifup and ifdown in the reboot test with ifconfig
This commit is contained in:
commit
213e7a8ab6
@ -79,7 +79,7 @@ var _ = Describe("Reboot", func() {
|
|||||||
It("each node by switching off the network interface and ensure they function upon switch on", func() {
|
It("each node by switching off the network interface and ensure they function upon switch on", func() {
|
||||||
// switch the network interface off for a while to simulate a network outage
|
// switch the network interface off for a while to simulate a network outage
|
||||||
// We sleep 10 seconds to give some time for ssh command to cleanly finish before network is down.
|
// We sleep 10 seconds to give some time for ssh command to cleanly finish before network is down.
|
||||||
testReboot(c, "nohup sh -c 'sleep 10 && sudo ifdown eth0 && sleep 120 && sudo ifup eth0' >/dev/null 2>&1 &")
|
testReboot(c, "nohup sh -c 'sleep 10 && sudo ifconfig eth0 down && sleep 120 && sudo ifconfig eth0 up' >/dev/null 2>&1 &")
|
||||||
})
|
})
|
||||||
|
|
||||||
It("each node by dropping all inbound packets for a while and ensure they function afterwards", func() {
|
It("each node by dropping all inbound packets for a while and ensure they function afterwards", func() {
|
||||||
|
@ -1581,7 +1581,7 @@ func waitForNodeToBeNotReady(c *client.Client, name string, timeout time.Duratio
|
|||||||
func isNodeReadySetAsExpected(node *api.Node, wantReady bool) bool {
|
func isNodeReadySetAsExpected(node *api.Node, wantReady bool) bool {
|
||||||
// Check the node readiness condition (logging all).
|
// Check the node readiness condition (logging all).
|
||||||
for i, cond := range node.Status.Conditions {
|
for i, cond := range node.Status.Conditions {
|
||||||
Logf("Node %s condition %d/%d: type: %v, status: %v, reason: %q, message: %q, last transistion time: %v",
|
Logf("Node %s condition %d/%d: type: %v, status: %v, reason: %q, message: %q, last transition time: %v",
|
||||||
node.Name, i+1, len(node.Status.Conditions), cond.Type, cond.Status,
|
node.Name, i+1, len(node.Status.Conditions), cond.Type, cond.Status,
|
||||||
cond.Reason, cond.Message, cond.LastTransitionTime)
|
cond.Reason, cond.Message, cond.LastTransitionTime)
|
||||||
// Ensure that the condition type is readiness and the status
|
// Ensure that the condition type is readiness and the status
|
||||||
|
Loading…
Reference in New Issue
Block a user