{"id":6575,"date":"2017-03-27T09:15:58","date_gmt":"2017-03-27T01:15:58","guid":{"rendered":"http:\/\/rmohan.com\/?p=6575"},"modified":"2017-03-27T09:15:58","modified_gmt":"2017-03-27T01:15:58","slug":"sshd-debug","status":"publish","type":"post","link":"https:\/\/mohan.sg\/?p=6575","title":{"rendered":"sshd debug"},"content":{"rendered":"<div class=\"code-raw\">\n<pre><code>1. To run sshd in debug mode as a one time instance without affecting other users:\r\n\r\n    # \/usr\/sbin\/sshd -ddd -D -p (port) 2&gt;&amp;1 | awk '{ print strftime(\"%T: \"), $0; fflush(); }' | tee sshd.log\r\n\r\n2. On the client end run add -p (port) to the ssh command line\r\n\r\n    # ssh -p (port)\r\n<\/code><\/pre>\n<\/div>\n<p>OR<\/p>\n<div class=\"code-raw\">\n<div class=\"code-raw-toolbar\"><a class=\"code-raw-btn\" href=\"https:\/\/access.redhat.com\/solutions\/295863#\">Raw<\/a><\/div>\n<pre><code>1. Open the `\/etc\/ssh\/sshd_config` file in a text editor\r\n\r\n    # vim \/etc\/ssh\/sshd_config\r\n\r\n2. Add the following line and save the file\r\n\r\n    LogLevel DEBUG3\r\n\r\n3. Restart SSHD\r\n\r\n    # service sshd restar<\/code><\/pre>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p> 1. To run sshd in debug mode as a one time instance without affecting other users: # \/usr\/sbin\/sshd -ddd -D -p (port) 2&gt;&amp;1 | awk &#8216;{ print strftime(&#8220;%T: &#8220;), $0; fflush(); }&#8217; | tee sshd.log 2. On the client end run add -p (port) to the ssh command line # ssh -p (port) <\/p>\n<p>OR<\/p>\n<p> [&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,73],"tags":[],"_links":{"self":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/6575"}],"collection":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6575"}],"version-history":[{"count":1,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/6575\/revisions"}],"predecessor-version":[{"id":6576,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/6575\/revisions\/6576"}],"wp:attachment":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6575"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=6575"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=6575"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}