scp 文件到 ec2 失败,我只想设置好 fever,求帮忙

2014-04-20 02:31:16 +08:00
 qian
真心电脑小白一个...又不是cs,哪懂那么多...在 stackoverflow 问了,不想再译回中文了= =。谢谢帮忙...


I'm a newbie and all I want is to set up an ec2 instance for fever rss.
Here is my info: os x 10.9.2, aws with ami of ubuntu 12.04 lts. I set up lamp on ec2 following this guide: http://www.robotmedia.net/2011/04/how-to-create-an-amazon-ec2-instance-with-apache-php-and-mysql-lamp/

Now I can ssh to my server public IP using terminal. After connected the server, I typed

scp -i /path/to/keypair.pem /path/to/test.txt ubuntu@theServerPublicIP:~/

and got the error as follows:

Warning: Identity file keypair.pem not accessible: No such file or directory.

I have tried to resolve the problem by:
1. change permission of .pem file to 600 on my os x.

chmod 600 keypair.pem

and ssh again, scp again, and got same error. Then I change its permission to 400 on my os x,

chmod 600 keypair.pem

and redid ssh and scp, and got same error.

2. rewrite file path using ~/path/to/file for both of keypair.pem and test.txt, and then redid ssh and scp, got same error.
Next rewrite file path using /Users/myUserName/path/to/file for both files and redid ssh and scp, got same error.
Next cd to the folder of keypair.pem and test.txt (I put them in the same folder), and tried the above two naming and got same error for each.

3. change path on the server. I have tried "~","~/","/","/var/www/", for all I still got the same error.

4. I also tried forklift because I saw the developer of Fever using it in the demo video. I tried all options for connection: sftp... but couldn't connect to the server.

Please help to get the test.txt uploaded... then I will be able to upload the fever folder.

Thanks!
3686 次点击
所在节点    问与答
22 条回复
ritksm
2014-04-20 05:02:01 +08:00
LZ并没有把完整的scp日志贴出来吧?如何判断啥错误
qian
2014-04-20 05:12:43 +08:00
@ritksm 我 mykeypair.pem 权限是 600。

感谢楼上所有的帮忙。。。
Fever 比较啃爹,ec2 的 elasric IP (就那个 public IP)是不被 Fever 认可的。Fever 要求必须有域名。搜了一下,有人说,IP 可以是本地的,与 Fever 要求是服务器的相违。

我于是马上买了域名(GoDaddy2年6镑)。运气好,几分钟之内,DNS 就 OK 了。现在已经能用了。谢谢 @sNullp 回复,和谢谢 @blacktulip 支招(wget)

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/109263

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX