<p>When i issue </p>

<blockquote>
  <p>kubectl logs MY_POD_NAME  --limit-bytes=1</p>
</blockquote>

<p>command, the --limit-bytes option is ignored and i get all the pod's logs.
My kubernetes version is 1.15.3 
Trying to understand why that would be. When i issue the same command in GKE  setup, the --limit-bytes option works as expected. I wonder what might be different in my setup to prevent this option from working correctly. (This is on CentOS).</p>

<p>Update: i tracked down the issue to Docker's --log-driver option.
If the Docker --log-driver is set to 'json-file', then kubectl logs command works fine with --limit-bytes option. However, if the Docker -log-driver is set to 'journald', then kubectl logs command ignores the --limit-bytes option. Seems like a kubectl bug to me. </p>

J.Doe
<p>After executing this command you shoud have seen following error:</p>

<pre><code>error: expected 'logs [-f] [-p] (POD | TYPE/NAME) [-c CONTAINER]'.
POD or TYPE/NAME is a required argument for the logs command
See 'kubectl logs -h' for help and examples.
</code></pre>

<p>Execute:</p>

<pre><code>$ kubectl logs your_pod_name  -c container_name --limit-bytes=1 -n namespace_name
</code></pre>

<p>If you set <strong>--limit-bytes</strong> flag you must know that 
<strong>--limit-bytes=0</strong>: Maximum bytes of logs to return. </p>

<p>Defaults to no limit.=0: Maximum bytes of logs to return. Defaults to no limit.</p>

<p>Documentation of <a href="https://github.com/fabric8io/kansible/blob/master/vendor/k8s.io/kubernetes/docs/user-guide/kubectl/kubectl_logs.md" rel="nofollow noreferrer">kubectl-logs</a>.</p>

<p>Please let me know if it helps.</p>
