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
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
greymd
December 29, 2020
Technology
2.6k
0
Share
狂気!AWS CloudShell細胞分裂!
2020/12/29 AWS CloudShell おもしろ選手権で発表した内容です。
https://connpass.com/event/199259/
greymd
December 29, 2020
More Decks by greymd
See All by greymd
Breaking Through Firewalls with Shell-gei
greymd
0
130
シェル芸人に必要なのは「マスキングテープ」だったのでは
greymd
19
11k
毎日叩ける シェル芸を覚えよう!
greymd
4
4.5k
入門Cureutils
greymd
3
2.6k
Other Decks in Technology
See All in Technology
Java正規表現エンジン(NFA)の仕組みと パフォーマンスを維持するための最適化手法
takeuchi_132917
0
160
大学生が本気でDatabricksを活用してDiscordサークルをデータ駆動させてみた
phantomjuju
1
310
Datadog 認定試験の概要と対策
uechishingo
0
210
Terraformモジュールは、なぜ「魔境」化するのか
hayama17
1
130
最低限これだけ押さえれ大丈夫_Claude Enterprise/Team企業展開ガバナンス入門
tkikuchi
1
590
新規ゲーム開発におけるAI駆動開発のリアル
202409e2
0
320
Mastering Ruby Box
tagomoris
3
110
個人AIからチームAIへ:開発における品質と生産性の再設計
moongift
PRO
0
340
管理アカウント単一運用からAWS Organizationsに移行するの大変で滅
hiramax
0
370
電子辞書Brainをネットに繋げてみた(自力編)
raspython3
0
390
Platform engineering for developers, architects & the rest of us (AI agents)
danielbryantuk
0
160
サプライチェーンセキュリティの空白地帯 - 信頼できる”依存性”の未来を考える
rung
PRO
2
580
Featured
See All Featured
How to make the Groovebox
asonas
2
2.2k
My Coaching Mixtape
mlcsv
0
140
Leo the Paperboy
mayatellez
7
1.8k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.5k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
1.1k
First, design no harm
axbom
PRO
2
1.2k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
180
Design in an AI World
tapps
1
220
Designing for Timeless Needs
cassininazir
1
240
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.4k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
Chasing Engaging Ingredients in Design
codingconduct
0
200
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