2016-10-01 168 views
0

我有一個從市場上購買的Wowza實例,大約4小時前我能夠連接它並且正在做一些操作。但是現在當我嘗試連接它時,Permission denied(publickey)錯誤。我使用chmod命令給.77上的權限。這是我想到的真正原因。Ec2市場Linux實例權限被拒絕(publickey)

this solution當我試圖將此實例的根卷附加到同一類型的其他實例時,它給出了相同的錯誤,但是當voulme被分離時,它正在成功連接。市場實例的數量只能附加到相似類型的實例。

現在如何更改該.ssh目錄的權限?你能幫我解決嗎?

這裏是日誌的時候我試圖用實例連接:從AWS市場推出

OpenSSH_6.6.1, OpenSSL 1.0.1f 6 Jan 2014 
debug1: Reading configuration data /etc/ssh/ssh_config 
debug1: /etc/ssh/ssh_config line 19: Applying options for * 
debug1: Connecting to 54.69.133.11 [54.69.133.11] port 22. 
debug1: Connection established. 
debug1: permanently_set_uid: 0/0 
debug1: identity file Desktop/Shivam/mypemfile.pem type -1 
debug1: identity file Desktop/Shivam/mypemfile.pem-cert type -1 
debug1: Enabling compatibility mode for protocol 2.0 
debug1: Local version string SSH-2.0-OpenSSH_6.6.1p1 Ubuntu-2ubuntu2.8 
debug1: Remote protocol version 2.0, remote software version OpenSSH_6.6.1 
debug1: match: OpenSSH_6.6.1 pat OpenSSH_6.6.1* compat 0x04000000 
debug1: SSH2_MSG_KEXINIT sent 
debug1: SSH2_MSG_KEXINIT received 
debug1: kex: server->client aes128-ctr [email protected] none 
debug1: kex: client->server aes128-ctr [email protected] none 
debug1: sending SSH2_MSG_KEX_ECDH_INIT 
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY 
debug1: Server host key: ECDSA 6a:48:f5:14:13:9a:a1:79:e8:44:bb:0d:6b:8d:b7:59 
The authenticity of host '54.69.133.11 (54.69.133.11)' can't be established. 
ECDSA key fingerprint is 6a:48:f5:14:13:9a:a1:79:e8:44:bb:0d:6b:8d:b7:59. 
Are you sure you want to continue connecting (yes/no)? yes 
Warning: Permanently added '54.69.133.11' (ECDSA) to the list of known hosts. 
debug1: ssh_ecdsa_verify: signature correct 
debug1: SSH2_MSG_NEWKEYS sent 
debug1: expecting SSH2_MSG_NEWKEYS 
debug1: SSH2_MSG_NEWKEYS received 
debug1: SSH2_MSG_SERVICE_REQUEST sent 
debug1: SSH2_MSG_SERVICE_ACCEPT received 
debug1: Authentications that can continue: publickey 
debug1: Next authentication method: publickey 
debug1: Trying private key: Desktop/Shivam/mypemfile.pem 
debug1: key_parse_private2: missing begin marker 
debug1: read PEM private key done: type RSA 
debug1: Authentications that can continue: publickey 
debug1: No more authentication methods to try. 
Permission denied (publickey). 

回答

1

產品有非市場的情況下,不必主要實施許可限制。您遇到了其中一個限制。

這裏是關於AWS論壇,可能是有用的,尤其是最後一篇文章的主題相關的thread

如果卷的AWS市場產品代碼:

  • 的卷只能附加到已停止的實例。
  • 您必須訂閱卷上的AWS Marketplace代碼。
  • 實例的配置(實例類型,操作系統)必須支持特定的AWS Marketplace代碼。例如,您的 無法從Windows實例獲取卷並將其附加到Linux實例的 實例。
  • AWS Marketplace產品代碼從卷複製到實例。
+0

謝謝,但我正在尋找解決方案。我已經閱讀了這篇文章以及其他許多類似的帖子。當我嘗試連接到其他實例時出現問題,我更新了我的問題以獲得更多的說明。 – Shivam

0

我沒有檢查,但你可以試試這個技巧。

您可以指定用戶數據以在啓動期間配置實例或運行配置腳本。 http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/user-data.html#user-data-shell-scripts

當您從市場廣場創建一個新的實例

  1. 選擇AMI
  2. 選擇實例類型
  3. 配置實例 - >高級詳細信息 - >使用的數據。

    在這裏放置你的bash腳本來更改權限。

  4. 添加存儲器

    更改根設備或添加從EBS的快照一個新的。

  5. 標記實例
  6. 配置安全組
  7. 審查和@jbird啓動
相關問題