找回密码
 加入我们

扫一扫,访问微社区

QQ登录

只需一步,快速开始

搜索
查看: 1868|回复: 7

[软件及汉化] 为什么不用 FileZilla 连接 Pre?

[复制链接]
发表于 2011-2-28 18:27 | 显示全部楼层 |阅读模式
http://forums.precentral.net/pal ... sing-filezilla.html" ~2 E0 {6 t4 K8 W6 E: ^
0 ]9 I$ \+ ?4 S6 N
这个不仅比[ZT]ROM定制_深度定制版webos2.1.0中的那个安全(安全隐患不言而喻),而且也更加方便,putty 也可以很方便地连接。
0 d) y2 I4 ^/ n4 Z- s" E5 Q- y* D" [, ^1 s
Whew—after two days of forum diving and experimentation, I finally got FTP up and running over SSH. I'd like to share the wealth: all the steps you need, in one place, to gain FTP access to your Pre over Wi-Fi—no more swapping out USB cables!) P9 ?) _% V9 K% c; f
- N6 G2 c* `0 J: d) n
This can be done in just 5 steps, which I'll detail below:
: W8 V9 h5 `- l- g2 j$ ~: vinstall Preware
4 t( z) }! s: m! juse Preware to install SFTP and Terminal: N# a5 T  N$ @1 b- o9 C
use Terminal to generate keys for OpenSSH
" j. Z* Y' S1 x  `6 s  I* itransfer SSH keys to desktop via USB
  A! l2 e: B- i( Nconfigure FileZilla on desktop and connect+ T- m% _" q7 }) m. w" |* k
1. install Preware: g0 O' {) a$ _4 Y3 n# I
Since this has been well documented and you've probably done this much by now, I'm going to cheat and refer you to these excellent install guides:
# a2 W9 e9 X. ~# K8 huse Device Info and the Updates utility to make sure webOS is current (1.4.1.1 as of this writing)8 O5 v$ ?4 Q& f) Q. p# w' B2 k
load webOS Quick install to enable homebrew apps4 H: z: c7 f4 v- @: q: C
use webOS Quick Install to load PreWare) X1 O* z: P" _# R, s# N: W2 Z& X
(for both guides, the Setup section is all you need)1 j( O- n7 d  X* `  _
2. use Preware to install SFTP and Terminal0 C& |: U- J% M2 k- t, R2 ]
With Preware on your system, you can manage most of your system tweaking right on the Pre with this single marvelous utility. Open up Preware to the main screen. It may take a minute or two to check for updates and index available packages.% `* ], o+ K  R4 k
At the main screen, type FTP and hit ↵. Select OpenSSH SFTP Server from the list and install it. You may be prompted to install other dependent services and to restart when the install is complete, do so in both cases./ d0 D5 w' j8 e, F( r4 Z
Back at the main Preware screen, type TERMINAL and hit ↵. Select Terminal from the list and install it. You'll be prompted to install the Terminal Service Plugin and restart; again, do so.; G  Y. w: {( Q2 F6 Z) Z7 a( b
3. use Terminal to generate keys for OpenSSH
. t0 m9 |# P$ X" o* G; cTerminal gives you direct command-line access to to your Pre, which is amazing, but don't have too much fun with it—when they say it's not very stable, they're not kidding. For our purposes here it should work fine. I pulled the following command sequence from the helpful Application: OpenSSH wiki. (Really, everything you need is right there, but the trick is knowing which to apply and the necessary prerequisites.) So, to generate your SSH keys, start the Terminal application and enter the following commands:
: }: S7 B# V% l) V0 |1 {# mcd /$ O3 X" r* d/ I8 X
/opt/bin/ssh-keygen5 N" n1 v" R3 ~) K! t' i
Press ↵ to accept the default filename. When prompted, press ↵ twice for a blank password. Then enter the final commands to transfer your keys to usable locations:, E$ m/ @2 E8 ?
mv /home/root/.ssh/id_rsa.pub /home/root/.ssh/authorized_keys& `% J" k1 v$ u# h
cp /home/root/.ssh/id_rsa /media/internal/id_rsa
. d, z- r9 }, A, M5 i8 YYou're done with Terminal and can close it.
  ?' u$ r% `: C3 G* P7 D; F: L4 ]
4. transfer SSH keys to desktop via USB* i. ~/ c# u& U
Connect the Pre to your computer via USB and put it in Drive mode (possibly for the last time!) Copy the id_rsa file from the Pre to your computer's hard drive and remember where you saved it. That's it! You can "safely disconnect" or "eject" the Pre's drive and unplug the USB cable.
& u: x6 Q  k  ~8 u! ?, l9 R* U8 c. H4 p5 N6 q& N
5. configure FileZilla on desktop and connect) |0 @1 R' n+ `7 w& A9 T" ]0 ~: e
If you don't already have it, download and install the FileZilla client on your computer. This is a great general-purpose FTP client, but it's particularly suited to our purposes because of its native ability to handle the OpenSSH private key and convert it into a format it can use without any additional software.
  X6 E2 U1 f. B: Y% S3 s
0 T" x: \+ v% u! {" YTo add your SSH private key (again, per the Application: OpenSSH wiki):
# U, v% Q5 L) v) a* B5 f& Xstart FileZilla
$ Z+ `& I9 }6 l: tunder Edit > Settings > SFTP, click "Add keyfile..." and locate the id_rsa file you saved earlier( M1 f0 W. K- ~% Y0 w& F$ A
click "Yes" to convert it to a .ppk file FileZilla can use  @4 ?+ _$ L; L+ f- {
give it any name you like and save it to a permanent location where it will be available whenever you need to connect
. w% `4 `4 K( _% W! L) c# I2 fNow you just need to connect! Go to File > Site Manager and create a new site with the following settings:
/ d1 J- C& `/ N+ RHost: your Pre's local IP address over Wi-Fi
1 H* s) e1 d5 c1 [(tap the name of your Wi-Fi connection for its current IP)/ Z7 G% K. O9 [( o' ~$ D1 Q$ g
Servertype: SFTP - SSH File Transfer Protocol
- g0 E" z2 Q4 @! fLogontype: Normal$ x- M4 ?2 w( z5 N- _3 h' t5 v/ ~# |
User: root
, q1 y8 \  V1 U5 B" M6 Ebe sure to leave the password blank- \* V6 r0 m) n4 O. j! W
optionally, on the Advanced tab: set your preferred local directory, and set the default remote directory to/media/internal
% u+ A1 t. O9 V/ K! G8 I1 GClick Connect and hold your breath for a couple of seconds while you see if your hard work has paid off... if one of us didn't screw up, you should now have full wireless access to your Pre!
5 ~% Z3 {: S0 A3 g& b; p3 G9 r* ]. o7 h! b! V4 K5 b
By the way, the FileZilla application folder is easily portable on a USB drive if you wish to access the Pre from other machines.
回复

使用道具 举报

发表于 2011-2-28 21:25 | 显示全部楼层

filezilla是个好东西

居然没人顶
回复 支持 反对

使用道具 举报

 楼主| 发表于 2011-2-28 21:38 | 显示全部楼层
原帖由 挣扎行走 于 2011-2-28 21:25 发表
& i- ~6 i4 B  L: j居然没人顶
8 n+ ]4 q4 v) @, F  ]- \: x

4 h% h0 T+ F$ u$ k目前为止这个方法是最方便的。
回复 支持 反对

使用道具 举报

发表于 2011-2-28 23:04 | 显示全部楼层
因为不会。。。。这几天正在搞着呢。。。
回复 支持 反对

使用道具 举报

发表于 2011-2-28 23:49 | 显示全部楼层
试了下,没成功,期待详细教程!winscp速度太慢了!
回复 支持 反对

使用道具 举报

发表于 2011-2-28 23:54 | 显示全部楼层
很详细的步骤。学习了
回复 支持 反对

使用道具 举报

发表于 2011-3-1 08:59 | 显示全部楼层
不懂,飘过
回复 支持 反对

使用道具 举报

发表于 2011-3-2 23:46 | 显示全部楼层
连不上,不知道为什么
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 加入我们

本版积分规则

QQ|Archiver|手机版|小黑屋|吹友吧 ( 京ICP备05078561号 )

GMT+8, 2024-3-29 03:39 , Processed in 0.224249 second(s), 18 queries , Gzip On.

Powered by Discuz! X3.5 Licensed

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表