aws pem file permission

main
Yik Teng Hie 5 years ago
parent 134f1e6ffb
commit a2ce49fa7c

@ -0,0 +1,9 @@
# Alibaba Cloud Academy: Database
* AsparaDB Disk size max
* 2TB : local disc
* 32TB : Cloud disc (ESSD)
* Migration : Data Transmission Service (DTS)
* Data Lake Analysis (DLA)
* Elastic Compute Service (ECS)

@ -123,4 +123,34 @@ $ aws ec2 describe-instances help
* ss * PEM (Windows) file permission change
```sh
# display file permission
$ icacls <<pem file path>>
# Remove the permissions inheritance
$ icacls <<pem file path>> /inheritance:r /T
# Grant read permission to the current user
$ icacls <<pem file path>> /grant <<user name>>:R
# updated permission display
PS C:\dev\doc\ec2> icacls .\RPD-API.pem
.\RPD-API.pem RAZER\tenghie.yik:(R)
###
# ssh to aws ec2 using update pem file permission
$ ssh -i "netyth-ec2-test.pem" ubuntu@ec2-54-169-180-189.ap-southeast-1.compute.amazonaws.com
```
* PEM (ubuntu) file permission change
```sh
# change file permission
$ chmod 400 <<pem file>>
# ssh to aws ec2
$ ssh -i "netyth-ec2-test.pem" ubuntu@ec2-54-169-180-189.ap-southeast-1.compute.amazonaws.com
```
Loading…
Cancel
Save