{"id":458,"date":"2013-09-19T23:52:09","date_gmt":"2013-09-19T23:52:09","guid":{"rendered":"https:\/\/shan.info\/new\/%e6%80%8e%e4%b9%88%e6%8a%8a%e5%91%bd%e4%bb%a4%e8%be%93%e5%87%ba%e7%bb%93%e6%9e%9c%e8%b5%8b%e5%80%bc%e7%bb%99%e5%8f%98%e9%87%8f-%e5%b7%b2%e8%a7%a3%e5%86%b3\/"},"modified":"2013-09-19T23:52:09","modified_gmt":"2013-09-19T23:52:09","slug":"%e6%80%8e%e4%b9%88%e6%8a%8a%e5%91%bd%e4%bb%a4%e8%be%93%e5%87%ba%e7%bb%93%e6%9e%9c%e8%b5%8b%e5%80%bc%e7%bb%99%e5%8f%98%e9%87%8f-%e5%b7%b2%e8%a7%a3%e5%86%b3","status":"publish","type":"post","link":"https:\/\/shan.info\/new\/%e6%80%8e%e4%b9%88%e6%8a%8a%e5%91%bd%e4%bb%a4%e8%be%93%e5%87%ba%e7%bb%93%e6%9e%9c%e8%b5%8b%e5%80%bc%e7%bb%99%e5%8f%98%e9%87%8f-%e5%b7%b2%e8%a7%a3%e5%86%b3\/","title":{"rendered":"\u600e\u4e48\u628a\u547d\u4ee4\u8f93\u51fa\u7ed3\u679c\u8d4b\u503c\u7ed9\u53d8\u91cf(\u5df2\u89e3\u51b3)"},"content":{"rendered":"<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">\u6211\u8981\u628a<\/span><br style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\" \/><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">awk &#8216;\/eth0\/{print $1 }&#8217; \/proc\/net\/dev |sed &#8216;s\/eth0:\/\/&#8217;<\/span><br style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\" \/><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">\u8f93\u51fa\u7684\u7ed3\u679c\u8d4b\u503c\u7ed9\u53d8\u91cf input<\/span><\/p>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\"><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px;\">\u641e\u5b9a\u4e86<\/span><br style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px;\" \/><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px;\">input=$(awk &#8216;\/eth0\/{print $1 }&#8217; \/proc\/net\/dev |sed &#8216;s\/eth0:\/\/&#8217;<\/span><br style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px;\" \/><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px;\">)<\/span><\/span><\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">awk &#8216;\/eth0\/{print $1 }&#8217; \/proc\/net\/dev |sed &#8216;s\/eth0:\/\/&#8217;<\/span><br style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\" \/><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">\u4e0d\u80fd\u7528\u4e00\u4e2a\u53e5\u5b50\u5199\u51fa\u6765\uff1f<\/span><br style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\" \/><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">awk -F &#8220;[: ]+&#8221; &#8216;\/eth0\/{print $3}&#8217; \/proc\/net\/dev<\/span><\/p>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">&nbsp;<\/span><\/p>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">&nbsp;<\/span><\/p>\n<blockquote style=\"display: inline; margin: 0px; padding: 0px 65px 5px 0px;\"><p>http:\/\/cu.img168.net\/static\/image\/common\/\/icon_quote_e.gif); line-height: 1.6; zoom: 1; background-position: 100% 100%; background-repeat: no-repeat no-repeat;&#8221;&gt;\u5047\u5982\u4e00\u4e2a\u547d\u4ee4ls\u67093\u4e2a\u8f93\u51fa1,2,3;<br \/>\u6211\u5982\u4f55\u628a1,2,3\u5206\u522b\u8d4b\u503c\u7ed9VAR1,VAR2,VAR3\u5462?<\/p><\/blockquote>\n<div class=\"blockcode\" style=\"overflow: hidden; margin: 10px 0px; padding: 10px 0px 5px 10px;\">\n<div id=\"code_9qt\">\n<ol>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">#bash<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">\/home\/lee#ls [0-9]<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">1&nbsp;&nbsp;2&nbsp;&nbsp;3<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">\/home\/lee#while read file;do ((++n));eval var$n=$file;done&lt; &lt;(ls [0-9])<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">\/home\/lee#echo $var1<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em; background-color: #ffffff; color: #336699;\">1<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">\/home\/lee#echo $var2<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">2<\/li>\n<li style=\"margin: 0px 0px 0px 2em; padding: 0px 0px 0px 10px; list-style-type: decimal-leading-zero; font-family: Monaco, Consolas, '&quot;Lucida Console&quot;', '&quot;Courier New&quot;', serif; font-size: 12px; line-height: 1.8em;\">\/home\/lee#echo $var3<\/li>\n<\/ol>\n<\/div>\n<\/div>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">&nbsp;<\/span><\/p>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">&nbsp;<\/span><\/p>\n<p><span style=\"font-family: song, Verdana; font-size: 14.44444465637207px; line-height: 22.39583396911621px; background-color: #f0f3fa;\">&nbsp;<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6211\u8981\u628aawk &#8216;\/eth0\/{print $1 }&#8217; \/proc\/net\/dev |sed &#8216;s\/eth0:\/\/&#8217;\u8f93\u51fa\u7684\u7ed3\u679c\u8d4b\u503c\u7ed9\u53d8\u91cf input \u641e\u5b9a\u4e86input=$(awk &#8216;\/eth0\/{print $1 }&#8217; \/proc\/net\/dev |sed &#8216;s\/eth0:\/\/&#8217;) &nbsp; &nbsp; &nbsp; awk &#8216;\/eth0\/{print $1 }&#8217; \/proc\/net\/dev |sed &#8216;s\/eth0:\/\/&#8217;\u4e0d\u80fd\u7528\u4e00\u4e2a\u53e5\u5b50\u5199\u51fa\u6765\uff1fawk -F &#8220;[: ]+&#8221; &#8216;\/eth0\/{print $3}&#8217; \/proc\/net\/dev &nbsp; &nbsp; http:\/\/cu.img168.net\/static\/image\/common\/\/icon_quote_e.gif); line-height: 1.6; zoom: 1; background-position: 100% 100%; background-repeat: no-repeat no-repeat;&#8221;&gt;\u5047\u5982\u4e00\u4e2a\u547d\u4ee4ls\u67093\u4e2a\u8f93\u51fa1,2,3;\u6211\u5982\u4f55\u628a1,2,3\u5206\u522b\u8d4b\u503c\u7ed9VAR1,VAR2,VAR3\u5462? #bash \/home\/lee#ls [0-9] 1&nbsp;&nbsp;2&nbsp;&nbsp;3 \/home\/lee#while read file;do ((++n));eval var$n=$file;done&lt; &lt;(ls [0-9]) [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[33],"tags":[],"class_list":["post-458","post","type-post","status-publish","format-standard","hentry","category-centos-6"],"_links":{"self":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts\/458","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/comments?post=458"}],"version-history":[{"count":0,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/posts\/458\/revisions"}],"wp:attachment":[{"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/media?parent=458"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/categories?post=458"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/shan.info\/new\/wp-json\/wp\/v2\/tags?post=458"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}