Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
0030_loopback_device.pdf
Search
Satoru Takeuchi
PRO
August 24, 2021
Technology
120
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
0030_loopback_device.pdf
Satoru Takeuchi
PRO
August 24, 2021
Transcript
5 slides
loop device Jul. 24th, 2021 Satoru Takeuchi twitter: satoru_takeuchi 1
loop deviceとは? • ファイルをブロックデバイスとして認識させるための機能 • loopback deviceとも呼ばれる • 主にファイル上に作ったファイルシステムイメージのmountに使う ◦
ファイルシステムイメージ (とくにisoイメージ)の読み書き ◦ ファイルシステムのテスト 2
使い方 1. ファイル上にファイルシステムを作成 ◦ # dd if=/dev/zero of=test.img bs=1G count=1
◦ # mkfs.ext4 test.img 2. loop deviceを作る ◦ # losetup -f --show test.img 3. mount ◦ # mount /dev/loop0 /mnt 4. 使う 5. umount ◦ # umount /mnt 6. loop deviceを削除 ◦ # losetup -d /dev/loop0 3 ext4ファイルシステム test.img /dev/loop0 ストレートマップ ext4としてマウント可能
実はもっと楽ができる • ファイル上にファイルシステムを作ってあれば以下コマンドでマウント可能 ◦ # mount test.img /mnt • loop
deviceの管理はmountコマンドが勝手にやってくれる 4
まとめ • loop deviceはファイルをブロックデバイスとして扱うための機能 • そのデバイスをファイルシステムとしてmountして使うことが多い ◦ ISOファイルの読み書き ◦ ファイルシステムのテスト
• losetupコマンドで管理するが、直接使わなくて済むことが多い 5
More Decks by Satoru Takeuchi
See All by Satoru Takeuchi
Btrfsのsnapshotとランダム書き込み
sat
PRO
0
51
ファイルシステムのデフラグ
sat
PRO
1
58
コピーオンライト型ファイルシステムと ランダム書き込み
sat
PRO
2
130
119-多機能ファイルシステムBtrfs_のコピー.pdf
sat
PRO
1
90
Linuxカーネルの インタフェースは変わりうる?
sat
PRO
1
120
あなたの知らないバージョン命名規則
sat
PRO
3
940
Rook: Intro and Deep Dive with Ceph
sat
PRO
1
87
Machine Check Exception
sat
PRO
2
78
バイナリダンプの模様を読む
sat
PRO
0
120
Other Decks in Technology
See All in Technology
さようならSSH鍵、こんにちはゼロトラスト ― AIフレンドリーで快適な自宅鯖SSH
atalie2m
14
7.2k
市販IoT機器や自作IoT機器とHomeAssistantを駆使して家の電気代をできる限り見える化する方法の考案
harutiro
0
390
目を覚ませ!僕らの認証情報が何者かに侵略されてるぞ
tkito
2
470
E2E Test というハーネス — AI時代の自動テスト民主化
daishukojima
10
5.9k
常時稼働エージェントの作り方(Claude公式ブログを資料化)
minorun365
PRO
17
28k
PHPで家庭用ゲーム機の専用コントローラーをMIDIデバイスとして扱ってみる
wind111
0
170
信頼性を犠牲にせず、PR マージからデプロイまで人の介入を完全にゼロにするまでの道のり
knwoop
2
1.5k
「個社」ではなく「業界」の課題を解く AI 対話開発 ー 価値を広げる設計と、価値を守るエンジニアリング ー
ivry_presentationmaterials
3
790
AIネイティブ組織の作り方。1人のPOとAIから始める、自社での実験
ama_ch
2
1.2k
WasmをRustにする技術
sansantech
PRO
1
130
AWS Client VPNの設定でハマったポイントとその過程での気づき
amarelo_n24
1
420
現地速報! Microsoft Ignite アップデートレポート
kasada
0
320
Featured
See All Featured
The SEO Collaboration Effect
kristinabergwall1
1
620
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
1
310
Art, The Web, and Tiny UX
lynnandtonic
304
22k
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
2
330
ラッコキーワード サービス紹介資料
rakko
5
6M
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
310
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
480
We Are The Robots
honzajavorek
0
450
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
141
35k
[RailsConf 2023] Rails as a piece of cake
palkan
59
7.2k
Facilitating Awesome Meetings
lara
57
7.2k
Build your cross-platform service in a week with App Engine
jlugia
234
19k