Issue 1:
Writing this https://github.com/kubernetes/kubernetes/blob/master/pkg/kubelet/network/kubenet/kubenet_linux.go#L158 to filesystem allows us to share a single kubelet generated CNI config for all runtimes (eg rkt). Potential downside is that we'd end up with 2 type=bridge cni confs that conflict.

@freehan @dcbw @yifan-gu

Issue 2:
Is this a request for help? (If yes, you should use our troubleshooting guide and community support channels, see http://kubernetes.io/docs/troubleshooting/.):

No

What keywords did you search in Kubernetes issues before filing this one? (If you have found any duplicates, you should instead reply there.):

scheduledjob, cron, active

Is this a BUG REPORT or FEATURE REQUEST? (choose one):

BUG REPORT

Kubernetes version (use kubectl version):

Server Version: version.Info{Major:"1", Minor:"4", GitVersion:"v1.4.6+coreos.0", GitCommit:"ec2b52fabadf824a42b66b6729fe4cff2c62af8c", GitTreeState:"clean", BuildDate:"2016-11-14T19:42:00Z", GoVersion:"go1.6.3", Compiler:"gc", Platform:"linux/amd64"}

Environment:

Cloud provider or hardware configuration: bare metal

OS (e.g. from /etc/os-release): Debian GNU/Linux 8 (jessie)

Kernel (e.g. uname -a): 4.4.0-36-generic #55-Ubuntu SMP Thu Aug 11 18:01:55 UTC 2016 x86_64 GNU/Linux

Install tools: quay.io/coreos/hyperkube:v1.4.6_coreos.0, deployed with kargo

Others:

What happened:

I had a job corresponding to a scheduledjob running, and I deleted the job manually.

The scheduledjob still shows as ACTIVE: 1. describe shows the job name under active jobs even though the job was deleted.

The scheduledjob stays like this indefinitely, and never re-schedules a new job according to the cron description.

What you expected to happen:

I expect the scheduledjob to pick up that the job was deleted, get into ACTIVE: 0 again, and do not reference a deleted job under active jobs.

In https://github.com/kubernetes/kubernetes/blob/release-1.4/pkg/controller/scheduledjob/controller.go#L127, there is no check that all the jobs for a scheduledjob still exist.

Instead, we could go through the active list for each scheduledjob, and remove any job that does not exist anymore along with a warning event.

How to reproduce it (as minimally and precisely as possible):

Create:

apiVersion: batch/v2alpha1
kind: ScheduledJob
metadata:
name: my-cron-job
labels:
app: my-cron-job
spec:
schedule: 0/1 * * * ?
concurrencyPolicy: Forbid
jobTemplate:
spec:
template:
spec:
containers:
- name: my-cron-job
image: busybox:1.25
command: ["sleep", "120"]
restartPolicy: Never

Use kubectl get jobs --watch | grep my-cron-job to wait for the job to be created, and delete it using kubectl delete job <xxxx>.

Check that scheduledjob is still active:

kubectl describe scheduledjob my-cron-job
Name:	my-cron-job
Namespace:	default
Schedule:	0/1 * * * ?
Concurrency Policy:	Forbid
Suspend:	False
Starting Deadline Seconds:	<unset>
Image(s):	busybox:1.25
Selector:	<unset>
Parallelism:	<unset>
Completions:	<unset>
No volumes.
Labels:	app=my-cron-job
Last Schedule Time:	Fri, 02 Dec 2016 11:22:00 -0500
Active Jobs:	my-cron-job-1782155079
Events:
FirstSeen	LastSeen	Count	From	SubobjectPath	Type	Reason	Message
---------	--------	-----	----	-------------	--------	------	-------
3m	3m	1	{scheduled-job-controller }	Normal	SuccessfulCreate	Created job my-cron-job-1782155079

Wait as long as you like and repeat check -- it will stay active indefinitely.

Anything else do we need to know: