Вторник (12/18/18)

/dev/pts/0
14:22:38
$ssh ec2-52-48-225-79.eu-west-1.compute.amazonaws.com
The authenticity of host 'ec2-52-48-225-79.eu-west-1.compute.amazonaws.com (52.48.225.79)' can't be established.
ECDSA key fingerprint is SHA256:b+0iVZyiDkP9WG0SAC8eIgAen4vuU1Y31XzM0XlzBAI.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'ec2-52-48-225-79.eu-west-1.compute.amazonaws.com,52.48.225.79' (ECDSA) to the list of known hosts.
       __|  __|_  )
       _|  (     /   Amazon Linux 2 AMI
      ___|\___|___|
https://aws.amazon.com/amazon-linux-2/
1 package(s) needed for security, out of 5 available
Run "sudo yum update" to apply all updates.
[ec2-user@ip-10-1-1-175 ~]$ curl http://169.254.169.254/1.0/ meta-data; echo
meta-datacurl: (6) Could not resolve host: meta-data
[ec2-user@ip-10-1-1-175 ~]$ curl http://169.254.169.254/
1.0
2007-01-19
2007-03-01
2007-08-29
2007-10-10
2007-12-15
2008-02-01
2008-09-01
2009-04-04
2011-01-01
2011-05-01
2012-01-12
2014-02-25
2014-11-05
2015-10-20
2016-04-19
2016-06-30
2016-09-02
2018-03-28
2018-08-17
2018-09-24
latest[ec2-user@ip-10-1-1-175 ~]$ curl http://169.254.169.254/latest
dynamic
meta-data[ec2-user@ip-10-1-1-175 ~]$ curl http://169.254.169.254/latest/meta-data/; echo
ami-id
ami-launch-index
ami-manifest-path
block-device-mapping/
events/
hostname
instance-action
instance-id
instance-type
local-hostname
local-ipv4
mac
metrics/
network/
placement/
profile
public-hostname
public-ipv4
public-keys/
reservation-id
security-groups
services/
[ec2-user@ip-10-1-1-175 ~]$ find /sys -name nvme2
find: ‘/sys/kernel/debug’: Permission denied
find: ‘/sys/fs/pstore’: Permission denied
[ec2-user@ip-10-1-1-175 ~]$ su-
-bash: su-: command not found
[ec2-user@ip-10-1-1-175 ~]$ su -l
Password:
su: Authentication failure
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$ su -
Password:
su: Authentication failure
[ec2-user@ip-10-1-1-175 ~]$ find /sys -name nvme1
find: ‘/sys/kernel/debug’: Permission denied
/sys/class/nvme/nvme1
/sys/devices/pci0000:00/0000:00:1f.0/nvme/nvme1
find: ‘/sys/fs/pstore’: Permission denied
[ec2-user@ip-10-1-1-175 ~]$ sudo find /sys -name nvme1
/sys/class/nvme/nvme1
/sys/devices/pci0000:00/000000:1f.0/nvme/nvme1                                                                                                                                                                                                                                                                                                                      /sys/devices/pci0000:00/0000:00:1f.0/nvme/m
[ec2-user@ip-10-1-1-175 ~]$ cat /sys/devices/pci0000:00/0000:00:1f.0/nvme/nvme1/model
Amazon EC2 NVMe Instance Storage        0/nvme/nvme1: Is a directory                                           cat /sys/devices/pci0000:00/0000:00:1f.0/nvme/nvme1
cat: /sys/devices/pci0000:00/000cat /sys/devices/pci0000:00/0000:00:1f.0/nvme/nvme1
[ec2-user@ip-10-1-1-175 ~]$ ifcofig a
[ec2-user@ip-10-1-1-175 ~]$ sudo /sys/devices/pci0000:00/0000:00:1f.0/nvme/nvme1
-bash: ifcofig: command not found
[ec2-user@ip-10-1-1-175 ~]$ ifconfig a
a: error fetching interface information: Device not found
[ec2-user@ip-10-1-1-175 ~]$ ifconfig -a
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 9001
        inet 10.1.1.175  netmask 255.255.255.0  broadcast 10.1.1.255
        inet6 fe80::866:8aff:feb7:1a54  prefixlen 64  scopeid 0x20<link>
        ether 0a:66:8a:b7:1a:54  txqueuelen 1000  (Ethernet)
        RX packets 19020  bytes 26124077 (24.9 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 4926  bytes 329368 (321.6 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 8  bytes 648 (648.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 8  bytes 648 (648.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
[ec2-user@ip-10-1-1-175 ~]$ ping 10.1.1.221
PING 10.1.1.221 (10.1.1.221) 56(84) bytes of data.
exit
~
64 bytes from 10.1.1.221: icmp_seq=327 ttl=255 time=0.413 ms
64 bytes from 10.1.1.221: icmp_seq=328 ttl=255 time=0.296 ms
64 bytes from 10.1.1.221: icmp_seq=329 ttl=255 time=0.303 ms
64 bytes from 10.1.1.221: icmp_seq=330 ttl=255 time=0.288 ms
64 bytes from 10.1.1.221: icmp_seq=331 ttl=255 time=0.378 ms
64 bytes from 10.1.1.221: icmp_seq=332 ttl=255 time=0.295 ms
64 bytes from 10.1.1.221: icmp_seq=333 ttl=255 time=0.258 ms
64 bytes from 10.1.1.221: icmp_seq=334 ttl=255 time=0.303 ms
64 bytes from 10.1.1.221: icmp_seq=335 ttl=255 time=0.300 ms
64 bytes from 10.1.1.221: icmp_seq=336 ttl=255 time=0.302 ms
64 bytes from 10.1.1.221: icmp_seq=337 ttl=255 time=0.364 ms
64 bytes from 10.1.1.221: icmp_seq=338 ttl=255 time=0.367 ms
64 bytes from 10.1.1.221: icmp_seq=339 ttl=255 time=2.10 ms
64 bytes from 10.1.1.221: icmp_seq=340 ttl=255 time=0.374 ms
64 bytes from 10.1.1.221: icmp_seq=341 ttl=255 time=0.341 ms
64 bytes from 10.1.1.221: icmp_seq=342 ttl=255 time=0.269 ms
64 bytes from 10.1.1.221: icmp_seq=343 ttl=255 time=0.459 ms
64 bytes from 10.1.1.221: icmp_seq=344 ttl=255 time=0.508 ms
64 bytes from 10.1.1.221: icmp_seq=345 ttl=255 time=0.309 ms
64 bytes from 10.1.1.221: icmp_seq=346 ttl=255 time=0.323 ms
64 bytes from 10.1.1.221: icmp_seq=347 ttl=255 time=0.343 ms
64 bytes from 10.1.1.221: icmp_seq=348 ttl=255 time=0.321 ms
^C
--- 10.1.1.221 ping statistics ---
348 packets transmitted, 22 received, 93% packet loss, time 355284ms
rtt min/avg/max/mdev = 0.258/0.418/2.100/0.372 ms
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$ sudo yum ipef
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
No such command: ipef. Please use /bin/yum --help
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$
[ec2-user@ip-10-1-1-175 ~]$ sudo yum install iperf
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
amzn2-core                                                          | 2.4 kB  00:00:00
No package iperf available.
Error: Nothing to do
[ec2-user@ip-10-1-1-175 ~]$ sudo yum install iperf*
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
Resolving Dependencies
--> Running transaction check
---> Package iperf3.x86_64 0:3.1.7-2.amzn2.0.2 will be installed
---> Package iperf3-devel.x86_64 0:3.1.7-2.amzn2.0.2 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
===========================================================================================
 Package              Arch           Version                      Repository          Size
===========================================================================================
Installing:
 iperf3               x86_64         3.1.7-2.amzn2.0.2            amzn2-core          79 k
 iperf3-devel         x86_64         3.1.7-2.amzn2.0.2            amzn2-core         8.4 k
Transaction Summary
===========================================================================================
Install  2 Packages
Total download size: 87 k
Installed size: 212 k
Is this ok [y/d/N]: n
Exiting on user command
Your transaction was saved, rerun it with:
 yum load-transaction /tmp/yum_save_tx.2018-12-18.13-52.eO2gAF.yumtx
[ec2-user@ip-10-1-1-175 ~]$ sudo yum install iperf3
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
Resolving Dependencies
--> Running transaction check
---> Package iperf3.x86_64 0:3.1.7-2.amzn2.0.2 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
===========================================================================================
 Package          Arch             Version                      Repository            Size
===========================================================================================
Installing:
 iperf3           x86_64           3.1.7-2.amzn2.0.2            amzn2-core            79 k
Transaction Summary
===========================================================================================
Install  1 Package
Total download size: 79 k
Installed size: 196 k
Is this ok [y/d/N]: y
Downloading packages:
iperf3-3.1.7-2.amzn2.0.2.x86_64.rpm                                 |  79 kB  00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : iperf3-3.1.7-2.amzn2.0.2.x86_64                                         1/1
  Verifying  : iperf3-3.1.7-2.amzn2.0.2.x86_64                                         1/1
Installed:
  iperf3.x86_64 0:3.1.7-2.amzn2.0.2
Complete!
[ec2-user@ip-10-1-1-175 ~]$ sudo iperf3 -c 10.1.1.22
Connecting to host 10.1.1.22, port 5201
[  4] local 10.1.1.175 port 47920 connected to 10.1.1.22 port 5201
[ ID] Interval           Transfer     Bandwidth       Retr  Cwnd
[  4]   0.00-1.00   sec   595 MBytes  4.99 Gbits/sec   31    350 KBytes
[  4]   1.00-2.00   sec   595 MBytes  4.99 Gbits/sec    3    638 KBytes
[  4]   2.00-3.00   sec   593 MBytes  4.97 Gbits/sec    0    655 KBytes
[  4]   3.00-4.00   sec   590 MBytes  4.95 Gbits/sec   31    288 KBytes
[  4]   4.00-5.00   sec   593 MBytes  4.97 Gbits/sec    6    612 KBytes
[  4]   5.00-6.00   sec   592 MBytes  4.97 Gbits/sec   23    306 KBytes
[  4]   6.00-7.00   sec   592 MBytes  4.97 Gbits/sec   27    332 KBytes
[  4]   7.00-8.00   sec   593 MBytes  4.98 Gbits/sec   10    533 KBytes
[  4]   8.00-9.00   sec   592 MBytes  4.97 Gbits/sec   62    288 KBytes
[  4]   9.00-10.00  sec   593 MBytes  4.97 Gbits/sec   21    743 KBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth       Retr
[  4]   0.00-10.00  sec  5.79 GBytes  4.97 Gbits/sec  214             sender
[  4]   0.00-10.00  sec  5.79 GBytes  4.97 Gbits/sec                  receiver
iperf Done.
[ec2-user@ip-10-1-1-175 ~]$ ifconfig -a
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 9001
        inet 10.1.1.175  netmask 255.255.255.0  broadcast 10.1.1.255
        inet6 fe80::866:8aff:feb7:1a54  prefixlen 64  scopeid 0x20<link>
        ether 0a:66:8a:b7:1a:54  txqueuelen 1000  (Ethernet)
        RX packets 358465  bytes 48706128 (46.4 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 700404  bytes 6261680319 (5.8 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 8  bytes 648 (648.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 8  bytes 648 (648.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
[ec2-user@ip-10-1-1-175 ~]$ sudo iperf3 -s 10.1.1.175
-----------------------------------------------------------
Server listening on 5201
-----------------------------------------------------------
Accepted connection from 10.1.1.22, port 35444
[  5] local 10.1.1.175 port 5201 connected to 10.1.1.22 port 35446
[ ID] Interval           Transfer     Bandwidth
[  5]   0.00-1.00   sec   568 MBytes  4.77 Gbits/sec
[  5]   1.00-2.00   sec   593 MBytes  4.97 Gbits/sec
[  5]   2.00-3.00   sec   583 MBytes  4.89 Gbits/sec
[  5]   3.00-4.00   sec   593 MBytes  4.97 Gbits/sec
[  5]   4.00-5.00   sec   593 MBytes  4.97 Gbits/sec
[  5]   5.00-6.00   sec   593 MBytes  4.97 Gbits/sec
[  5]   6.00-7.00   sec   592 MBytes  4.97 Gbits/sec
[  5]   7.00-8.00   sec   571 MBytes  4.79 Gbits/sec
[  5]   8.00-9.00   sec   593 MBytes  4.97 Gbits/sec
[  5]   9.00-10.00  sec   593 MBytes  4.97 Gbits/sec
[  5]  10.00-10.04  sec  25.0 MBytes  4.97 Gbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth
[  5]   0.00-10.04  sec  0.00 Bytes  0.00 bits/sec                  sender
[  5]   0.00-10.04  sec  5.76 GBytes  4.93 Gbits/sec                  receiver
-----------------------------------------------------------
Server listening on 5201
-----------------------------------------------------------
Accepted connection from 10.1.1.35, port 35040
[  5] local 10.1.1.175 port 5201 connected to 10.1.1.35 port 35042
[ ID] Interval           Transfer     Bandwidth
[  5]   0.00-1.00   sec   116 MBytes   972 Mbits/sec
[  5]   1.00-2.00   sec   121 MBytes  1.01 Gbits/sec
[  5]   2.00-3.00   sec   121 MBytes  1.01 Gbits/sec
[  5]   3.00-4.00   sec   120 MBytes  1.01 Gbits/sec
[  5]   4.00-5.00   sec   120 MBytes  1.01 Gbits/sec
[  5]   5.00-6.00   sec   120 MBytes  1.00 Gbits/sec
[  5]   6.00-7.00   sec   118 MBytes   988 Mbits/sec
[  5]   7.00-8.00   sec   118 MBytes   988 Mbits/sec
[  5]   8.00-9.00   sec   119 MBytes   996 Mbits/sec
[  5]   9.00-10.00  sec   118 MBytes   992 Mbits/sec
[  5]  10.00-10.05  sec  5.50 MBytes   998 Mbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth
[  5]   0.00-10.05  sec  0.00 Bytes  0.00 bits/sec                  sender
[  5]   0.00-10.05  sec  1.17 GBytes   998 Mbits/sec                  receiver
-----------------------------------------------------------
Server listening on 5201
-----------------------------------------------------------
^Ciperf3: interrupt - the server has terminated
[ec2-user@ip-10-1-1-175 ~]$ exit
logout
Connection to ec2-52-48-225-79.eu-west-1.compute.amazonaws.com closed.