Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
狂気!AWS CloudShell細胞分裂!
Search
greymd
December 29, 2020
Technology
0
2.3k
狂気!AWS CloudShell細胞分裂!
2020/12/29 AWS CloudShell おもしろ選手権で発表した内容です。
https://connpass.com/event/199259/
greymd
December 29, 2020
Tweet
Share
More Decks by greymd
See All by greymd
Breaking Through Firewalls with Shell-gei
greymd
0
49
シェル芸人に必要なのは「マスキングテープ」だったのでは
greymd
19
11k
毎日叩ける シェル芸を覚えよう!
greymd
4
4.4k
入門Cureutils
greymd
3
2.5k
Other Decks in Technology
See All in Technology
LangfuseでAIエージェントの 可観測性を高めよう!/Enhancing AI Agent Observability with Langfuse!
jnymyk
0
170
SRE NEXT CfP チームが語る 聞きたくなるプロポーザルとは / Proposals by the SRE NEXT CfP Team that are sure to be accepted
chaspy
1
570
MCP Documentation Server @AI Coding Meetup #1
yyoshiki41
2
2.6k
IVRyにおけるNLP活用と NLP2025の関連論文紹介
keisukeosone
0
180
Classmethod AI Talks(CATs) #21 司会進行スライド(2025.04.17) / classmethod-ai-talks-aka-cats_moderator-slides_vol21_2025-04-17
shinyaa31
0
450
AWSのマルチアカウント管理 ベストプラクティス最新版 2025 / Multi-Account management on AWS best practice 2025
ohmura
4
210
AIで進化するソフトウェアテスト:mablの最新生成AI機能でQAを加速!
mfunaki
0
120
NLP2025 参加報告会 / NLP2025
sansan_randd
4
520
アセスメントで紐解く、10Xのデータマネジメントの軌跡
10xinc
1
360
MCPを活用した検索システムの作り方/How to implement search systems with MCP #catalks
quiver
5
1k
Vision Pro X Text to 3D Model ~How Swift and Generative Al Unlock a New Era of Spatial Computing~
igaryo0506
0
260
Micro Frontends: Necessity, Implementation, and Challenges
rainerhahnekamp
2
350
Featured
See All Featured
Building Adaptive Systems
keathley
41
2.5k
4 Signs Your Business is Dying
shpigford
183
22k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
41
2.2k
We Have a Design System, Now What?
morganepeng
52
7.5k
VelocityConf: Rendering Performance Case Studies
addyosmani
328
24k
Making Projects Easy
brettharned
116
6.1k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
160
15k
Stop Working from a Prison Cell
hatefulcrawdad
268
20k
Embracing the Ebb and Flow
colly
85
4.6k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
26k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
Build The Right Thing And Hit Your Dates
maggiecrowley
35
2.6k
Transcript
狂気!AWS CloudShell細胞分裂! grethlen 2020/12/29 AWS CloudShell おもしろ選⼿権
$ whoami ぐれさん Twitter: @grethlen GitHub: @greymd シェル芸⼈ ↓ の作者
tmux 使ってますか? tmux on AWS Cloud9 の Terminal では残念な状態 CloudShellではなんとデフォルトで⼊っている!
分割してもレイアウト崩れず どんどん使えという中の⼈のメッセージと理解
tmux-xpanes tmuxの端末分割を超絶楽にできる xpanes コマンド Bash 3.2〜5.xで動く超ポータブルコマンド 私が作者です(GitHub:greymd/tmux-xpanes) EPEL登録済み、ぜひ御社でも CloudShellでもこの通り $
sudo amazon-linux-extras install epel -y $ sudo yum install xpanes -y ### 必要なら HOME 以下に退避 $ cp /usr/bin/xpanes ~
デモ
何分割できるのか?
制限 tmux 当然、1(⾏ or ⽂字)より低い幅はできない CloudShellの制限はあるか? 端末サイズは上限なさそう ウィンドウを⼤きくすると stty size
も⼤きくなる ulimit の max user processes は無制限( unlimited ) = コンテナのリソースが許す限り分割できそう
何プロセスくらい⾛るのか(1/2) 端末1: $ yes 'sleep 1000 &' | sh 端末2:
$ ps ax | nl 8,600 プロセスくらいまでsleepは動かせた それ以上では動作が重すぎて話にならず( ps すら⽌まる) 数千のオーダーで性能限界が来るっぽい
何プロセスくらい⾛るのか(2/2) 皆さんの関⼼ => ⼀般的なユースケースのコマンドがどれくらい並列で使えるか ssh セッションマネージャ ojichat $ xpanes -sc
ojichat {1..100} => ojichatを 100 分割して実⾏
デモ2
ちなみに セッションマネージャは40分割での利⽤くらいが限度でした
結論 CloudShellは並列作業に便利! tmux と xpanes が使える 端末サイズとコンテナのリソースが許す限り画⾯分割して動かせる ただし……そこそこの処理をするコマンドの動作は分割しすぎると苦しい 数⼗程度の規模が限度 AWS
CLI + セッションマネージャ: 40分割〜あたりからプロセスが落ちる ojichat: 100 を超えると動作が極めて遅い上に精神的にも⾟い
END