{"id":509,"date":"2017-05-22T15:22:57","date_gmt":"2017-05-22T07:22:57","guid":{"rendered":"https:\/\/blog.freesilo.com\/?p=509"},"modified":"2017-05-22T15:22:57","modified_gmt":"2017-05-22T07:22:57","slug":"%e4%bd%bf%e7%94%a8putty%e5%9c%a8linux%e4%b8%bb%e6%9c%ba%e5%92%8cwindows%e4%b8%bb%e6%9c%ba%e4%b9%8b%e9%97%b4%e6%8b%b7%e8%b4%9d%e6%96%87%e4%bb%b6","status":"publish","type":"post","link":"https:\/\/freesilo.com\/?p=509","title":{"rendered":"\u4f7f\u7528putty\u5728linux\u4e3b\u673a\u548cwindows\u4e3b\u673a\u4e4b\u95f4\u62f7\u8d1d\u6587\u4ef6"},"content":{"rendered":"<p>\u9996\u5148\u4e0b\u8f7dpytty\uff0c\u89e3\u538b\u5f00\u53d1\u73b0\u91cc\u9762\u6709plink.exe pscp.exe psftp.exe putty.exe puttygen.exe puttytel.exe\u7b49\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u5982\u679c\u53ea\u662f\u60f3\u8981\u94fe\u63a5\u4e3b\u673a\u505a\u4e00\u4e9b\u64cd\u4f5c\u90a3\u4e48\u4f7f\u7528putty.exe\u5c31\u53ef\u4e00\uff0c\u5177\u4f53\u4f7f\u7528\u53ef\u4ee5\u53c2\u89c1\u4e0a\u9762\u7ed9\u51fa\u7684\u94fe\u63a5\uff0c<span style=\"color: #800000;\">\u8981\u60f3\u8981\u4e0a\u4f20 \u4e0b\u8f7d\u6587\u4ef6\uff0c\u90a3\u4e48\u9700\u8981\u4f7f\u7528pscp.exe\u8fd9\u4e2a\u6587\u4ef6\u3002<\/span><\/p>\n<p>\u4e3b\u8981\u7684\u5c31\u662f\u8bf4pscp\u547d\u4ee4\u3002<\/p>\n<p>\u901a\u8fc7\u547d\u4ee4\u884c\u8fdb\u5165pscp.exe\u6240\u5728\u7684\u6587\u4ef6\u5939\uff08\u6211\u7684\u662f\u5728c:\\Users\\\u4f60\u81ea\u5df1\u7684\u7528\u6237\u540d\\putty\uff09\uff08\u6216\u8005\u914d\u7f6e\u4e00\u4e0b\u73af\u5883\u53d8\u91cf\uff0c\u61d2\u5f97\u5f04\uff09\uff0c\u76f4\u63a5\u8f93\u5165pscp\u4f1a\u770b\u770b\u5230\u5982\u4e0b\u63d0\u793a\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-510\" src=\"https:\/\/blog.freesilo.com\/wp-content\/uploads\/2017\/03\/1343803473_8048.png\" alt=\"\" width=\"614\" height=\"460\" srcset=\"https:\/\/freesilo.com\/wp-content\/uploads\/2017\/03\/1343803473_8048.png 614w, https:\/\/freesilo.com\/wp-content\/uploads\/2017\/03\/1343803473_8048-300x225.png 300w\" sizes=\"auto, (max-width: 614px) 100vw, 614px\" \/><\/p>\n<p>\u547d\u4ee4\u5982\u4e0b\uff1a<\/p>\n<p>&nbsp;<\/p>\n<p>\u53ef\u4ee5\u770b\u51fa\u00a0PSCP\u00a0\u7684\u4f7f\u7528\u662f\u5f88\u7b80\u5355\u7684\uff0c\u628a\u5e38\u7528\u7684\u51e0\u4e2a\u9009\u9879\u8bf4\u4e00\u4e0b\uff1a<\/p>\n<p>-q\u00a0\u5b89\u9759\u6a21\u5f0f\uff0c\u4f20\u8f93\u6587\u4ef6\u65f6\u4ec0\u4e48\u4e5f\u4e0d\u663e\u793a\uff0c\u5426\u5219\u4f1a\u663e\u793a\u51fa\u6587\u4ef6\u7684\u4f20\u8f93\u8fdb\u5ea6<\/p>\n<p>-P\u00a0port\u00a0\u6307\u5b9a\u670d\u52a1\u5668\u7684\u00a0SSH\u00a0\u7aef\u53e3\uff0c\u6ce8\u610f\u8fd9\u4e2a\u662f\u5927\u5199\u5b57\u6bcd\u00a0P\uff0c\u9ed8\u8ba4\u662f\u00a0-P\u00a022\uff0c\u5982\u679c\u4e3b\u673a\u7684\u00a0SSH\u00a0\u7aef\u53e3\u5c31\u662f\u00a022\uff0c\u5c31\u4e0d\u7528\u6307\u5b9a\u4e86<\/p>\n<p>-l\u00a0user\u00a0\u6307\u5b9a\u4ee5\u54ea\u4e2a\u7528\u6237\u7684\u8eab\u4efd\u767b\u5f55\u4e3b\u673a\uff0c\u7528\u6237\u540d\u79f0\u4e5f\u53ef\u4ee5\u548c\u4e3b\u673a\u540d\u79f0\u5199\u5728\u4e00\u8d77\uff0c\u7528@\u5206\u5272\u5f00\uff0c\u6bd4\u5982\uff1ausername@server<\/p>\n<p>-pw\u00a0passwd\u00a0\u6307\u5b9a\u767b\u5f55\u65f6\u6240\u7528\u7684\u53e3\u4ee4\u4e3a\uff1apasswd<\/p>\n<p>-C \u8868\u793a\u5141\u8bb8\u538b\u7f29\u4f20\u8f93\uff0c\u63d0\u9ad8\u4f20\u8f93\u901f\u5ea6<\/p>\n<p>PSCP\u00a0\u57fa\u672c\u7528\u6cd5\u662f\uff1a<\/p>\n<p>pscp\u00a0-P\u00a022\u00a0-C c:\\a.txt username@server:\/path\/<\/p>\n<p>\u4f8b\u5b50\uff1a<\/p>\n<p>1\u3001c:\\&gt;pscp -C c:\\a.bat\u00a0username@server:upload\/<\/p>\n<p>\u5c31\u662f\u628a\u672c\u5730\u7684c:\\a.bat\u590d\u5236\u5230\u4e86\u4e3b\u673aserver\u4e0a\u7684\u7528\u6237username\u6240\u5728\u7684\u4e3b\u76ee\u5f55\u4e0b\u7684upload\u5b50\u76ee\u5f55\u4e2d\uff08\u8fd9\u4e2a\u8def\u5f84\u53ef\u80fd\u662f\u00a0\/home\/username\/upload\uff09<\/p>\n<p>2\u3001c:\\&gt;pscp -C c:\\a.txt username@server:.<\/p>\n<p>\u628a\u672c\u5730\u7684\u00a0C:\\a.txt\u00a0\u590d\u5236\u5230\u4e3b\u673aserver\u7684\u7528\u6237username\u7684\u4e3b\u76ee\u5f55\u4e0b<\/p>\n<p>3\u3001c:\\&gt;pscp -C username@server:*.tgz\u00a0c:\\download<\/p>\n<p>\u628a\u8fdc\u7a0b\u4e3b\u673aserver\u4e0a\u7684\u7528\u6237username\u4e3b\u76ee\u5f55\u4e0b\u7684\u6240\u6709\u00a0*.tgz\u00a0\u6587\u4ef6\u62f7\u8d1d\u5230\u672c\u5730\u7684\u00a0c:\\download\u76ee\u5f55\u4e2d\uff0c\u5982\u679c\u00a0SSH\u00a0\u7248\u672c\u662f\u00a0SSH\u00a0v1\uff0c\u90a3\u8fd9\u4e2a\u547d\u4ee4\u5c31\u4f1a\u51fa\u9519\u3002<\/p>\n<p>\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014<\/p>\n<p><b><span style=\"color: #ff0000; font-size: large;\">\u6211\u7684\u6d4b\u8bd5\uff1a<\/span><\/b><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">Windows\u4e0b\u7684dos\u8fdb\u5165D\u76d8F\u76d8\u76f4\u63a5\u8f93\u5165D:\u5373\u53ef<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u7528pscp\u8fdc\u7a0b\u4e0b\u8f7d\u7684\u8bdd\uff0c\u5c31\u8981\u5148\u8fdb\u5165PUTTY\u8fd9\u4e2a\u76ee\u5f55<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u7136\u540epscp.exe xgame@10.12.16.143:\u6587\u4ef6\u540d E:\\\u6587\u4ef6\u540d<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">pscp dev@192.168.68.248:\/home\/dev\/gren.sql d:\\gren.sql;\u8f93\u5165\u5bc6\u7801<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u5176\u4e2d\uff1adev\u4e3alinux\u7684\u7528\u6237\u540d\uff0c192.168.68.248\u4e3a\u8fdc\u7a0bLinux\u4e3b\u673aip\u5730\u5740\uff0c<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\/home\/dev\/gren.sql\u4e3alinux\u4e0b\u7684\u6587\u4ef6 \uff0cd:\\gren.sql\u4e3a\u4fdd\u5b58\u5728\u672c\u5730\u7684\u6587\u4ef6<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">C:\\Users\\rickenli&gt;D:<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">D:\\&gt;cd MyFiles<\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">D:\\MyFiles&gt;cd PUTTY<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\"><span style=\"color: #333333;\">\u6709\u7684\u65f6\u5019\u9700\u8981\u6307\u5b9a\u7aef\u53e3\u5982\u4e0b\uff1a<\/span><span style=\"color: #ff0000;\"><b>P\u5fc5\u987b\u5927\u5199<\/b><\/span><\/span><\/p>\n<p><span style=\"color: #333333; font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u4eceLinux\u4e0b\u8f7d\u5230\u672c\u5730Windows\u673a\u5668\u4e0a\uff1a<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">D:\\MyFiles\\PUTTY&gt;PSCP.EXE <span style=\"color: #ff0000;\">-P 36000<\/span><span style=\"color: #333333;\"> username(xgame)@IP:\/data\/home\/xgame\/TenVFS_V2<\/span><\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">.09.016.7z E:\\MyLearning\\\u5b66\u4e60\u8d44\u6599\\<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u7136\u540e\u8f93\u5165\u5bc6\u7801\u5373\u53ef\u3002<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u4eceWindows\u4e0a\u4f20\u9001\u5230Linux\u673a\u5668\u4e0a\uff1a<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\"><span style=\"color: #333333;\">D:\\MyFiles\\PUTTY&gt;PSCP.EXE <\/span><span style=\"color: #ff0000;\">-P 36000<\/span><span style=\"color: #333333;\"> \u00a0E:\\MyLearning\\\u5b66\u4e60\u8d44\u6599\\menagerie-db\\load_pet<\/span><\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">_tbl.sql xgame@IP:\/data\/home\/xgame<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\">\u7136\u540e\u8f93\u5165\u5bc6\u7801\u5373\u53ef\u3002<\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\"><b>\u6307\u5b9a\u7aef\u53e3\u548c\u5bc6\u7801\uff0c\u5c31\u4e0d\u9700\u8981\u5728\u4e0b\u9762\u8f93\u5165\u5bc6\u7801\u4e86<\/b><\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\"><span style=\"color: #333333;\">D:\\MyFiles\\PUTTY&gt;PSCP.EXE <\/span><span style=\"color: #ff0000;\">-P 36000 -pw password<\/span><span style=\"color: #333333;\"> xgame@IP:\/data\/home\/x<\/span><\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\"><span style=\"color: #333333;\">game\/TenVFS_V2.09.016.7z E:\\MyLearning\\\u5b66\u4e60\u8d44\u6599\\<\/span><\/span><\/p>\n<p><span style=\"font-family: 'Lucida Grande', Verdana, Arial, sans-serif; font-size: small;\"><span style=\"color: #333333;\">TenVFS_V2.09.016.7z \u00a0 \u00a0 \u00a0 | 1784 kB | 1784.5 kB\/s | ETA: 00:00:00 | 100%<\/span><\/span><\/p>\n<p><span style=\"color: #ff0000; font-size: medium;\"><b>\u5982\u679c\u8981\u4f20\u9001\u5230\u673a\u5668\u4e0a\u7684\u5176\u4ed6\u6587\u4ef6\u5939\u4e0b\uff0c\u4e3a\u4e86\u907f\u514d\u6ca1\u6709\u6743\u9650\u64cd\u4f5c\uff0c\u53ef\u4ee5\u9009\u62e9root\u7528\u6237\uff1a<\/b><\/span><b><\/b><\/p>\n<div>D:\\MyFiles\\PUTTY&gt;PSCP.EXE -P 36000 -pw password \u00a0E:\\MyLearning\\\u5b66\u4e60\u8d44\u6599\\menageri<\/div>\n<div>e-db\\load_pet_tbl.sql root@IP:\/usr\/local\/mysql<\/div>\n<div>load_pet_tbl.sql \u00a0 \u00a0 \u00a0 \u00a0 \u00a0| 0 kB | \u00a0 0.1 kB\/s | ETA: 00:00:00 | 100%<\/div>\n<p>&nbsp;<\/p>\n<p>\u4e0b\u9762\u8bf4\u4e00\u4e0b\u8981\u6ce8\u610f\u7684\u95ee\u9898\uff1a<\/p>\n<p>a\uff1a\u4fdd\u8bc1linux\u5b89\u88c5\u4e86server\uff0c\u5982\u679c\u6ca1\u6709\uff0c\u5b89\u88c5\u4e00\u4e0b\uff0c\u4e00\u822c\u90fd\u4f1a\u542f\u52a8\u4e86\uff0c\u5982\u679c\u6ca1\u6709\u542f\u52a8\uff0c<\/p>\n<pre id=\"best-answer-content\">\/etc\/init.d\/ssh start<\/pre>\n<p>\u6216\u8005\u91cd\u542fssh\u670d\u52a1<\/p>\n<pre id=\"best-answer-content\">sudo \/etc\/init.d\/ssh resar<\/pre>\n<p><span style=\"color: #800000;\">\u00a0 <strong>b\uff1a\u4e0d\u8981\u901a\u8fc7putty.exe\u6267\u884cpscp\u547d\u4ee4\uff0c\u56e0\u4e3aputty.exe\u4f1a\u8ba9\u4f60\u94fe\u63a5\u4e0a\u4e3b\u673a\u4e86\uff0c\u518d\u7528pscp\u547d\u4ee4\u538b\u6839\u8fd8\u662f\u5728\u4e3b\u673a\u81ea\u5df1\u7684\u6587\u4ef6\u5939\u91cc\u9762\u590d\u5236\uff0c\u538b\u6839\u4e0b\u8f7d\u4e0d\u5230windows\u673a\u5668\u4e0a\u9762\u3002<\/strong><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u9996\u5148\u4e0b\u8f7dpytty\uff0c\u89e3\u538b\u5f00\u53d1\u73b0\u91cc\u9762\u6709plink.exe pscp.exe psf&#8230;<br \/><a class=\"read-more-button\" href=\"https:\/\/freesilo.com\/?p=509\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13],"tags":[],"class_list":["post-509","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/freesilo.com\/index.php?rest_route=\/wp\/v2\/posts\/509","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/freesilo.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/freesilo.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/freesilo.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/freesilo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=509"}],"version-history":[{"count":1,"href":"https:\/\/freesilo.com\/index.php?rest_route=\/wp\/v2\/posts\/509\/revisions"}],"predecessor-version":[{"id":511,"href":"https:\/\/freesilo.com\/index.php?rest_route=\/wp\/v2\/posts\/509\/revisions\/511"}],"wp:attachment":[{"href":"https:\/\/freesilo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=509"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/freesilo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=509"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/freesilo.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=509"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}