Fact-checked by Grok 2 weeks ago

Loop device

A loop device is a pseudo-device that makes a accessible as a block device. In , a loop device is a block device that maps its data blocks not to a physical device such as a hard disk or optical disk drive, but to the blocks of a regular file in a filesystem or to another block device. This mechanism enables users to treat ordinary files—such as disk images or ISO files—as virtual block devices, allowing standard filesystem operations like mounting and reading without requiring dedicated hardware. Loop devices are integral to various workflows in Linux systems, including mounting ISO images for software installation, creating and accessing temporary filesystems for testing, and managing encrypted containers or virtual disk images. For instance, a command like mount -o loop image.iso /mnt associates the file with a loop device and mounts its contents directly. They are configured and controlled primarily through the losetup utility, which attaches a file to a loop device node (e.g., /dev/loop0), sets parameters like offsets or size limits, and detaches devices when no longer needed. Key features of loop devices include support for and decryption using configurable transfer functions (such as XOR-based schemes), read-only mounting, direct I/O operations (available since 4.10), and automatic scanning (since kernel 3.2). Since version 3.1, the /dev/loop-control special file facilitates dynamic allocation and deallocation of loop devices, improving flexibility beyond the traditional fixed limit of eight devices (e.g., /dev/loop0 to /dev/loop7). This limit can be increased via kernel parameters like max_loop if more devices are required, though doing so demands sufficient system resources to avoid instability.

Definition and Fundamentals

Core Concept

In , a loop device is a pseudo-device that translates operations on a virtual block device to operations on a regular file, effectively allowing the file to be accessed and managed as if it were a physical block device. Analogous mechanisms exist in other systems under different names, such as vnd in or md in . This mapping enables the kernel to treat ordinary files—such as files—as addressable storage media without requiring dedicated hardware. To understand the role of loop devices, it is essential to distinguish between devices and character devices, the two primary categories of device files in these systems. devices process data in fixed-size blocks (typically 512 bytes or larger) and support , buffering, and seeking to arbitrary positions, making them suitable for storage media where filesystems operate at the block level. In contrast, character devices handle data as an unstructured of bytes without inherent block structure or , commonly used for devices like terminals or serial ports that require sequential or I/O. Filesystems in systems fundamentally require block-level access for efficient organization and retrieval of data, which is why loop devices bridge the gap by presenting files in this structured manner. The primary purpose of a loop device is to facilitate the mounting and manipulation of file-based images, such as ISO files or virtual disk images, as though they were physical disks or partitions. This allows users to access the contents of these images directly within the filesystem hierarchy, supporting both read-only and read-write operations based on the underlying file permissions and configuration. By enabling such virtual mounting, loop devices support a range of emulation needs, including the simulation of like optical discs or legacy formats, without physical hardware.

Historical Development

The concept of loop devices originated in early Unix variants, where the vnode interface in 4.0 (around 1988) and its refinements in 4.1 (1990) supported layered file systems and virtual device abstractions. A similar mechanism, the vnd (vnode disk), was introduced in 2.0 ( 5.0) in 1992, providing a way to treat files as block devices for tasks such as handling disk images. In , the loop device was formalized by Theodore Ts'o in 1993 as a pseudo-device driver allowing regular files to be mapped to block devices, enabling operations like mounting floppy or ISO images without dedicated hardware. Key milestones in included the addition of modular support for the loop driver in version 2.1.18 in 1997, which allowed without recompiling the . Enhancements arrived in 2.6 (2003), integrating encryption capabilities via the cryptoloop module and the losetup utility with CryptoAPI support, facilitating secure file-based containers. Cryptoloop was later deprecated in favor of the more performant starting around 2.6.25 (2008). Modern updates in 5.x series (starting 2019) improved performance through tighter integration with for encrypted devices, optimizing I/O handling and reducing overhead in virtualized environments, with further enhancements like workqueue bypass flags in 5.9 (2020). BSD variants evolved similar functionality in the through their own vnode interfaces, but dedicated memory disk (md) devices for file-backed block access were introduced in FreeBSD 4.0 in 2000 as a replacement for earlier memory file system (MFS) tools, providing configurable disks via mdconfig. In macOS, handling via hdiutil emerged with OS X 10.0 in 2001, evolving from Disk Copy utilities to a command-line for creating and mounting images as volumes, with full integration by OS X 10.3 in 2003. Efforts toward standardization appeared in specifications for portable operating system interfaces, which outlined basic device abstractions like /dev/null and /dev/tty but left virtual block devices such as loop mechanisms implementation-specific across systems, without a unified for file-to-block mapping.

Technical Mechanics

Implementation Details

The loop device is implemented as a device driver within the , residing in the source file drivers/block/loop.c and typically provided by the loop . This dynamically creates device nodes such as /dev/loop0, /dev/loop1, and so on, up to a configurable maximum, using the add_disk() function and an IDR (integer ID range) allocator for indexing. These devices act as pseudo- devices that intercept standard I/O requests—such as reads and writes from the layer—and redirect them to an underlying backing rather than a physical medium, leveraging the (VFS) layer for operations. Device setup begins with binding a backing to a , typically via the LOOP_SET_FD , which associates a and configures parameters like the starting (lo_offset) and maximum (lo_sizelimit) in the struct loop_device. Once bound, the state transitions from unbound to bound, enabling I/O translation: incoming requests are queued through loop_queue_rq(), processed by loop_handle_cmd(), and fulfilled by do_req_filebacked(), which maps sector addresses to file offsets and performs seeks using VFS interfaces like vfs_read() or vfs_write() (via read_iter and write_iter for iterators). The driver supports configurable (powers of two from 512 bytes up to the page ) since kernel version 4.14 and direct I/O modes since 4.10 to optimize performance by bypassing the when specified. Resizing is handled via the LOOP_SET_CAPACITY , recalculating the device's geometry with lo_calculate_size(). For , the built-in mechanisms (e.g., LO_CRYPT_NONE or deprecated LO_CRYPT_CRYPTOAPI) are largely obsolete; instead, loop devices integrate with the () subsystem, where a loop-backed serves as the target for transformations, enabling stacked setups like LUKS through tools that automatically allocate and map loop devices to files before applying targets. The backing store for a loop device can be any seekable regular file or even another block device, allowing flexible usage without requiring dedicated hardware. The VFS layer manages fragmentation by handling non-contiguous file extents transparently during seeks, while caching occurs through the kernel's unless direct I/O is enabled to reduce overhead for large, sequential accesses. Error handling includes periodic validation of the backing file via loop_validate_file() during configuration changes (e.g., via LOOP_CHANGE_FD ) to detect alterations like or permission shifts, returning errors such as EBUSY if the device is in use or EINVAL for invalid parameters. For read-only configurations, the driver enforces restrictions if the backing file lacks write permissions, and external modifications to the file during read-write mounts can lead to data inconsistencies, though the kernel does not inherently lock the file; read-only mounts mitigate this by treating the device as immutable, compatible with filesystems like for compressed, append-only images.

Configuration Parameters

The primary tool for configuring loop devices in Linux is the losetup command from the util-linux package, which associates regular files or block devices with loop device nodes such as /dev/loopN. This command allows users to specify a backing file and bind it to an available loop device, with automatic allocation of the first unused device via the -f or --find option when no specific device is provided. Modern Linux kernels support up to 256 loop devices (limited by minor device numbers), with a default of 8, numbered from /dev/loop0 to /dev/loop255, managed through the /dev/loop-control interface for dynamic allocation. The default can be increased via the max_loop kernel module parameter. Key configuration parameters include the --offset option, which skips a specified number of bytes from the beginning of the backing file to access a subsection (e.g., --offset=1M for a 1 skip), and --sizelimit, which caps the apparent size of the loop device regardless of the backing file's actual size (e.g., --sizelimit=10G). Read-only mode can be enabled with the -r or --read-only to prevent writes to the underlying file. Direct I/O, which bypasses the for better performance with large files, is configurable via --direct-io=on (enabled since 4.10). For encryption, while older versions of losetup supported a deprecated -e or --encryption option via the cryptoloop module, current practice uses device-mapper (dm-crypt) tools like cryptsetup on top of a plain loop device for secure setups. Loop devices can also be configured directly during mounting using the mount command with the -o loop option, which automatically handles association if no device is specified; additional parameters like offset=, sizelimit=, and ro (read-only) can be appended (e.g., mount -o loop,offset=1024k,ro file.iso /mnt). To detach or unbind a loop device, use losetup -d /dev/loopN for a specific device or losetup -D for all attached devices. Active loop devices are managed and queried using losetup -a or losetup -l to list all associations, including backing files, offsets, and sizes. Alternatively, the /proc/partitions provides a kernel-level view of all devices, including devices, showing their major/minor numbers and block counts. In -based systems, persistent configuration occurs via /etc/[fstab](/page/Fstab) entries that incorporate options, such as /file.iso /mnt auto [loop](/page/Loop),offset=1024k 0 2, which .mount processes during boot. Other parameters like --sector-size (for logical size, since 4.14) and -P or --partscan (to detect partitions on the backing , since 3.2) further refine setup for specific use cases.

Applications and Use Cases

Primary Uses

Loop devices are primarily employed to mount disk images as if they were physical block devices, enabling access to filesystem contents within files such as ISO images for software installers, floppy disk images for legacy software , or virtual disk files in and testing environments. For instance, ISO files containing contents can be directly mounted using a loop device, allowing users to extract or install software without burning to physical media. Similarly, floppy images, often in formats like .img, are mounted via loop devices to simulate for running or analyzing old applications. Another standard application involves creating temporary filesystems by associating regular files with loop devices, which can mimic ramfs-like setups when the backing file resides on a (in-memory filesystem) or facilitate read-only distributions through loop-mounted images. This approach allows for lightweight, on-demand block devices without dedicated hardware, useful for short-lived storage needs or portable system images. , a compressed read-only filesystem, is particularly common here, as loop mounting enables efficient handling of such archives. Loop devices also support data isolation by providing virtual block access to files, which is integral to environments or previews of container images without invoking overhead. This isolation ensures that filesystem operations remain contained within the loop-backed file, aiding in secure testing or sandboxed executions. A key example is their essential role in live CDs, such as Ubuntu's ISO, where the root filesystem is mounted via a loop device to boot the system from the image. In modern kernels, loop devices are created on demand through /dev/loop-control, with typically 8 pre-allocated by default, though this can be configured higher via the max_loop . Basic mounting is achieved using tools like losetup from the package.

Advanced Scenarios

Loop devices can be integrated with encryption tools like cryptsetup to create portable LUKS-encrypted volumes stored as regular files. This approach allows users to format a file as a LUKS , attach it to a loop device, and map it to a device for mounting, providing encrypted that can be transported across systems without dedicated . For instance, cryptsetup's luksFormat command initializes the on the backing file, followed by losetup to associate the loop device, and luksOpen to unlock it into /dev/mapper. This method is particularly useful for secure data exchange, as the encrypted file remains self-contained and accessible on any system supporting LUKS. Nested loop devices enable mounting a file-based within another loop-mounted filesystem, creating multi-layer structures such as a virtual hard disk (VHD) embedded in an . This is achieved by first attaching the outer to a loop device (e.g., /dev/loop0), mounting it, then creating an inner file within that mount point and attaching it to another loop device (e.g., /dev/loop1). However, this configuration incurs significant performance penalties due to multiple layers of I/O translation and filesystem overhead, often resulting in reduced throughput compared to single-layer mounts. Such setups are viable for or testing complex disk images but are not recommended for production due to the compounded . In and , loop devices facilitate read-only mounting of disk images to preserve evidence integrity. By using the mount option -o loop,ro on an image file created with tools like , investigators can access the contents without risking modifications to the original data. For example, recovers data from failing drives into an image file, which is then looped and mounted read-only for analysis using forensic tools such as The Sleuth Kit or . This method ensures chain-of-custody compliance, as the image remains unaltered during examination. Despite their versatility, loop devices exhibit notable limitations and potential pitfalls in advanced usage. They impose resource overhead, particularly memory usage for caching large backing files, and can consume significant CPU for I/O operations on high-capacity images. A critical arises if the backing file is modified externally while the loop device is mounted, leading to data inconsistencies or corruption in the mounted view, as the does not automatically synchronize changes. Additionally, loop devices are unsuitable for high-I/O workloads, where performance can degrade to 50% or less of native disk speeds due to the additional translation layer. In embedded systems, loop devices support overlay filesystems by backing temporary root filesystems during boot, such as in initramfs environments. Here, a compressed root image (e.g., ) is attached via loop device and overlaid with a writable layer to enable runtime modifications without altering the base image. This technique is common in resource-constrained devices, allowing updates via overlays while preserving the integrity of the read-only core filesystem. For example, initramfs scripts can losetup the image, mount it as root, and apply an overlay for persistent changes across reboots. Since Linux kernel 6.10 (released April 2025), the zoned loop block device driver (zloop) extends loop device functionality to emulate zoned block devices. This allows creating a zoned block device using one regular file per zone as backing storage, facilitating testing and development of zoned storage applications, such as those for shingled magnetic recording (SMR) drives, without requiring specialized hardware.

Platform Support and Alternatives

Operating System Availability

Loop devices are natively supported in operating systems through the loop module, which has been included since version 2.2. This functionality is standard across all major distributions, including and , allowing files to be treated as block devices for mounting and other operations. In recent , such as those in version 6.x series, the number of loop devices can be configured up to 1024 or more, depending on system resources and parameters, with dynamic allocation enabling efficient use beyond the traditional fixed limits. In Unix-like systems derived from BSD and macOS, equivalent mechanisms provide similar loopback capabilities, though implementations differ from . FreeBSD utilizes the mdconfig utility to manage memory disks, which function analogously to loop devices by associating files or memory with block device nodes for mounting ISO images or creating virtual disks. and employ the vnd(4) driver for file-backed block devices, enabling disk-like access to regular files through kernel-level configuration and tools like vndconfig, supporting tasks such as ramdisk creation and image mounting. macOS, based on , lacks a direct /dev/loop equivalent but supports loop-like operations via the hdiutil command and , where hdiutil attach maps disk image files to mountable volumes, handling formats like DMG and ISO without native kernel loop nodes. Microsoft Windows does not provide native loop device support in its kernel, requiring third-party drivers to emulate this functionality. Tools such as , available since , allow users to mount image files as virtual block devices using a kernel-mode driver that integrates with the Windows storage stack. Similarly, offers comparable features, mounting disk images or creating RAM disks as drive letters, with support extending from through modern versions like , often used in forensic and virtualization workflows. Other platforms exhibit varied levels of loopback support. includes the lofi (loopback file interface) driver since Solaris 8, released in 2000, which exports regular files as block devices via the lofiadm utility for mounting and filesystem operations. Embedded real-time operating systems like provide native support for loop devices, including devb-ram for memory disks and devb-loopback for file-backed block devices, as standardized kernel features. POSIX compliance for loop devices varies across implementations, as the POSIX standard does not define a unified for file-to-block-device mapping, resulting in platform-specific tools and behaviors, such as losetup in versus mdconfig in BSD variants. This lack of standardization ensures portability challenges, where applications must adapt to differing node conventions and methods.

Comparable Technologies

Loop devices provide a lightweight mechanism in the for associating regular files with block devices, enabling the mounting of file-based images as if they were physical disks. In contrast, the (dm) subsystem offers a more versatile, stacked framework for creating virtual block devices by mapping physical or other virtual devices onto higher-level abstractions, supporting advanced features like snapshots, , and (LVM). While loop devices are simple and direct for file-to-block mappings, is heavier due to its modular targets (e.g., for encryption or dm-thin for ), making it suitable for complex storage configurations but overkill for basic file mounting. User-space alternatives based on (Filesystem in Userspace) emulate block device functionality without requiring kernel modules like , providing greater portability across systems where kernel access is restricted. For instance, tools such as fuseiso allow mounting of ISO images directly in user space, bypassing traditional devices and enabling non-root users to access file images, though with potential performance overhead from context switching between user and kernel space. Similarly, the Library (LKL) integrates kernel code into user-space applications for block device simulation, offering flexibility for embedded or containerized environments but typically slower than kernel-native devices due to the lack of direct hardware access. Virtual disk formats and their mounting tools represent another class of comparables, often tied to platforms and emphasizing over simple file mapping. QEMU's NBD () tool, for example, exports disk images (e.g., qcow2 or ) over a or locally via user-space daemon, allowing access to formatted virtual disks that may include snapshots or compression—features not natively supported by loop devices without additional layering. This contrasts with loop devices' focus on local, unformatted file mounting, as NBD introduces or overhead suitable for remote or VM-specific scenarios. On Windows, Hyper-V's VHD/VHDX mounting via Disk Management or cmdlets (e.g., Mount-VHD) provides a platform-native way to attach virtual hard disks as local volumes, integrating seamlessly with the host OS for inspection or extension but requiring Windows-specific tools unlike the cross-platform simplicity of loop. In cloud environments, services like (EBS) deliver managed virtual block storage volumes attached to instances, persisting data independently of instance lifecycle and supporting features such as , snapshots, and multi-attach for . Google Cloud Persistent Disk functions similarly, offering zonal or regional block devices with configurable and throughput, but both are remote, network-attached resources billed by usage, differing fundamentally from loop devices' local, file-based, zero-cost attachment on a host machine. What distinguishes loop devices is their minimalism: they perform direct, kernel-level file-to-block translation without the stacking complexity of , user-space indirection of , virtualization emulation in tools like qemu-nbd or VDI handling, or managed remoteness of blocks, making them ideal for lightweight, local access.

Practical Examples

Basic Mounting Example

To mount a basic , such as an ISO , as a loop device, root access is required, and the loop kernel module must be loaded (typically via modprobe loop if not already built-in). Consider a scenario where an ISO file named example.iso needs to be mounted to access its contents without burning it to . First, identify and a free loop device with the file using the losetup command with the -f option to find an unused device and -P to scan for partitions if applicable:
sudo losetup -fP /path/to/example.iso
This command outputs the assigned device, such as /dev/loop5, indicating successful association. Next, create a mount point if it does not exist (e.g., sudo mkdir /mnt/iso) and the loop device, specifying the ISO9660 filesystem type for proper detection:
[sudo](/page/Sudo) [mount](/page/Mount) -t iso9660 /dev/loop5 /mnt/iso
The ISO9660 filesystem is the standard for images like ISOs, enabling read-only access to the file structure. To verify, list the contents:
[ls](/page/Ls) /mnt/iso
This displays the ISO's directory and files, confirming the . For cleanup, unmount the filesystem and detach the loop device:
sudo umount /mnt/iso && sudo losetup -d /dev/loop5
This ensures the device is freed for reuse. If the image is corrupted or the filesystem type mismatches, the mount may fail with an error like "wrong fs type, bad option, bad superblock," requiring verification of the file integrity or explicit -t iso9660 specification. The -fP options in losetup handle basic setup, with further details in the configuration parameters section.

Scripted Automation Example

Scripted automation of loop device management is particularly valuable for repeatable tasks, such as mounting encrypted disk images in deployment environments or workflows. A common scenario involves using a script to securely mount a LUKS-encrypted image file, execute operations on the mounted filesystem, and then cleanly unmount and detach the device, ensuring and resource cleanup. This approach leverages the losetup utility to associate the image with a loop device and cryptsetup to handle the encryption layer, providing a robust method for handling encrypted storage without manual intervention each time. The following script exemplifies this automation for an encrypted image file named /path/to/encrypted.img, assuming it has been previously formatted as a LUKS container with an filesystem. The script finds a free loop device, attaches the image, opens the LUKS mapping with a prompt, mounts it to /mnt/secure, performs placeholder operations (e.g., file backups), unmounts, closes the mapping, and detaches the loop device. Error checking is incorporated using verification to handle failures gracefully.
bash
#!/bin/[bash](/page/Bash)

# Define paths and variables
IMAGE="/path/to/encrypted.img"
MOUNT_POINT="/mnt/secure"
LOOP_DEVICE=$(losetup -f)  # Find the first available loop device
MAPPER_NAME="secure_loop"

# Ensure mount point exists
mkdir -p "$MOUNT_POINT"

# Attach the image to a loop device
if losetup "$LOOP_DEVICE" "$IMAGE"; then
    echo "Loop device attached: $LOOP_DEVICE"
else
    echo "Failed to attach loop device"
    exit 1
fi

# Open the LUKS mapping (prompts for passphrase)
if cryptsetup luksOpen "$LOOP_DEVICE" "$MAPPER_NAME"; then
    echo "LUKS mapping opened: /dev/mapper/$MAPPER_NAME"
else
    echo "Failed to open LUKS mapping"
    losetup -d "$LOOP_DEVICE"
    exit 1
fi

# Mount the decrypted device
if mount "/dev/mapper/$MAPPER_NAME" "$MOUNT_POINT"; then
    echo "Mounted at $MOUNT_POINT"
    
    # Perform operations here, e.g., backup files
    # rsync -a /source/ "$MOUNT_POINT/"
    echo "Operations completed"
    
    # Unmount
    umount "$MOUNT_POINT"
    echo "Unmounted successfully"
else
    echo "Failed to mount"
    cryptsetup luksClose "$MAPPER_NAME"
    losetup -d "$LOOP_DEVICE"
    exit 1
fi

# Close LUKS mapping and detach loop device
if cryptsetup luksClose "$MAPPER_NAME"; then
    echo "LUKS mapping closed"
else
    echo "Warning: Failed to close LUKS mapping"
fi

if losetup -d "$LOOP_DEVICE"; then
    echo "Loop device detached"
else
    echo "Warning: Failed to detach loop device"
fi
In this script, the variable LOOP_DEVICE is assigned using losetup -f to dynamically select an available loop device, avoiding hardcoding that could lead to conflicts in multi-user or automated environments. Error checking employs conditional statements with $? -ne 0 implicitly through if failure branches, halting execution and cleaning up resources if any step fails, such as attachment or mounting. Integration with cryptsetup for passphrase handling occurs via luksOpen, which securely prompts for input without exposing it in process lists, supporting scripted use in secure contexts like keyfiles for non-interactive runs. For more complex automation, the script can be extended to loop over multiple encrypted image files in a directory, processing each sequentially with a for loop, or scheduled via cron for periodic mounts, such as nightly data synchronization tasks. This scripted approach is especially useful in deployment scripts for container images, where loop devices facilitate mounting of portable, encrypted root filesystems in CI/CD pipelines, enabling secure, reproducible builds without persistent storage dependencies.

References

  1. [1]
    loop(4) - Linux manual page - man7.org
    The loop device is a block device that maps its data blocks not to a physical device such as a hard disk or optical disk drive, but to the blocks of a regular ...
  2. [2]
    What are loopback devices, how can I ... - Red Hat Customer Portal
    Aug 7, 2024 · Issue. What are loopback devices? How can I more loopback devices be made available? How can loopback devices be used?
  3. [3]
    losetup(8) - Linux manual page - man7.org
    losetup is used to associate loop devices with regular files or block devices, to detach loop devices, and to query the status of a loop device.
  4. [4]
  5. [5]
    6. Related Work - USENIX
    Vnode stacking was first implemented by Rosenthal (in SunOS 4.1) around 1990[15]. A few other works followed Rosenthal, such as further prototypes for ...
  6. [6]
  7. [7]
    md(4) - DragonFly On-Line Manual Pages
    HISTORY. The md driver first appeared in FreeBSD 4.0 as a cleaner replacement for the MFS functionality previously used in PicoBSD and in the FreeBSD ...
  8. [8]
    Create a disk image using Disk Utility on Mac - Apple Support
    You can use Disk Utility to create a disk image, which is a file that contains other files and folders.Missing: 2001 | Show results with:2001
  9. [9]
    cryptsetup(8) - Linux manual page
    ### Summary: Cryptsetup Integration with Loop Devices for LUKS Encryption
  10. [10]
    2.22 - The Linux Kernel Archives
    The cryptoloop support in the commands mount(8) and losetup(8) is DEPRECATED. This is the last release where encryption= mount option and -e,-E,--encryption ...
  11. [11]
    mount(8) - Linux manual page - man7.org
    ... floppy or hard disk formatted with VFAT, or systems that are not normally ... A commonly used option for removable media is context="system_u:object_r:removable_t ...
  12. [12]
    fstab(5) - Linux manual page - man7.org
    This field describes the block special device, remote filesystem or filesystem image for loop device to be mounted or swap file or swap device to be enabled.
  13. [13]
    systemd.mount - Freedesktop.org
    Mount units may either be configured via unit files, or via /etc/fstab (see fstab(5) for details). Mounts listed in /etc/fstab will be converted into native ...Missing: loop | Show results with:loop
  14. [14]
    Linux allocated devices (4.x+ version)
    This list is the Linux Device List, the official registry of allocated device numbers and /dev directory nodes for the Linux operating system.
  15. [15]
    How to mount an ISO image/file under Linux - nixCraft
    Mar 20, 2025 · You can mount an ISO file or images via the loop device under Linux. It is possible to specify transfer functions (for encryption/decryption or other purposes) ...
  16. [16]
    9.8. Mounting a disk image using the loop device - Bochs
    Mounting a disk image using the loop device. This section describes how to access a floppy or hard disk image within Linux using the loop device.
  17. [17]
    MakeALiveCD/DVD/BootableFlashFromHarddiskInstall
    Jul 12, 2015 · Squashfs is read only compressed filesystem that allow us to squeeze our system into a single CD. Note that your system has to be about 2GB ( ...The Live Cd/dvd Structure · Chroot Into The New System... · Prepare The Cd Directory...
  18. [18]
    The kernel's command-line parameters
    The following is a consolidated list of the kernel parameters as implemented by the __setup(), early_param(), core_param() and module_param() macros and sorted ...
  19. [19]
    Linux Hard Disk Encryption With LUKS [cryptsetup command ]
    Sep 12, 2025 · In this tutorial, I will explain how to encrypt your partitions using Linux Unified Key Setup-on-disk-format (LUKS) on your Linux based computer or laptop.
  20. [20]
    how to mount a luks-encrypted file? - Server Fault
    Jun 11, 2013 · Use `losetup /dev/loop/0 /path/file`, then `cryptsetup luksOpen /dev/loop/0 crypt_fun`, and finally `mount /dev/mapper/crypt_fun /crypt`. Or, ...Creating a grow-on-demand encrypted volume with LUKSUsing fsck to check and repair LUKS encrypted disk? - Server FaultMore results from serverfault.comMissing: portable | Show results with:portable
  21. [21]
    Overhead of using loop-mounted images under Linux
    Apr 23, 2016 · On Linux <4.4, there is significant overhead when using loop devices on Linux: data accessed through the loop device has to go through two filesystem layers.Loop mounting files vs mounting directories [duplicate]loop-device performance issue - Unix & Linux Stack ExchangeMore results from unix.stackexchange.comMissing: nested | Show results with:nested
  22. [22]
    Performance of Loopback Filesystems - Server Fault
    Aug 3, 2010 · Here's the conclusion: If you sync after every write, then a loopback device performs significantly worse (almost twice as slow). If you allow ...Bad performance on multiple loop devices used as file containersHow fast is 127.0.0.1? - Server FaultMore results from serverfault.comMissing: overhead | Show results with:overhead
  23. [23]
    How to mount .img file created from ddrescue from failing hard drive
    Jan 10, 2019 · The command to execute would be: sudo mount -t btrfs -o loop,ro partition.img mountpoint. Make sure to unmount the btrfs partition in case it's still mounted.How do you mount an hd image made from ddrescue? - Ask UbuntuMounting ddrescue image after recovery (in over my head)More results from askubuntu.com
  24. [24]
    Can I mount read-only a partition image that is being written into by ...
    Oct 27, 2015 · Mounting the image read-only (ro) should at least prevent your mounting & browsing from changing the image, and as long as gddrescue is ...Mounting a complete disk image rescued by ddrescue - Super UserHow I mount an image on linux in fake read-only mode? - Super UserMore results from superuser.com
  25. [25]
    Guide to Using DDRescue to Recover Data - Technibble
    Nov 14, 2013 · This will temporarily mount the image file in the “mountpoint” directory that we created. Note: The “ro” switch mounts the image as read only.
  26. [26]
    How to sync a loop device when the backing file is changed
    Dec 22, 2020 · The data being displayed on a loop device mount is incorrect when the data in the underlying file is changed. Example:Data loss when loop-mounting a file on removable USB storageBtrfs read-only file system and corruption errorsMore results from unix.stackexchange.com
  27. [27]
    Difference between ramdisk (e.g. initramfs) and loopback device ...
    Mar 17, 2023 · The loopback filesystem associates a file on another filesystem as a complete device. For Ramdisks, the device does not refer to any physical ...Missing: overlay | Show results with:overlay<|control11|><|separator|>
  28. [28]
    How can I overlayfs the root filesystem on linux? - Stack Overflow
    Dec 13, 2016 · If you can run 'init' from an initramfs, mount your read-only "real" root partition and your writable partition some where in the initramfs file ...Create a loop in a Linux filesystem - Stack OverflowHow to make loadable file system over the read only rootfs?More results from stackoverflow.com
  29. [29]
    3. Adding Support for More Loop Devices
    Newer Linux kernels (2.4) allow you to add more loop devices easily by editing /etc/modules.conf or through the use of a boot parameter.
  30. [30]
    Expanding the Limit of Loop Devices in Linux - Virtualizor
    Sep 9, 2024 · Modern kernels provide the flexibility to adjust the number of supported loop devices without requiring a kernel recompilation.<|control11|><|separator|>
  31. [31]
    what is maximum loop devices for linux kernel?
    Nov 27, 2019 · The limit is the maximum number of minor devices for a single major device (since loop has a single major, block 7), which is limited by MINORBITS (so 2 20 , ...How do I setup more then 10 loopback device?Grub change loopback amount? - Unix & Linux Stack ExchangeMore results from unix.stackexchange.com
  32. [32]
    Chapter 20. Storage | FreeBSD Documentation Portal
    This chapter covers the use of disks and storage media in FreeBSD. This includes SCSI and IDE disks, CD and DVD media, memory-backed disks, and USB storage ...Resizing and Growing Disks · Creating and Using CD Media · Memory DisksMissing: loop | Show results with:loop
  33. [33]
    md(4) - NetBSD Manual Pages
    Memory for the disk must be allocated within the kernel or with mdconfig(8) before the md device may be used as a disk. Its behaviour is configured by the ...Missing: OpenBSD loop
  34. [34]
    OSFMount - Mount Disk Images & Create RAM Drives - OSForensics
    OSFMount mounts disk images as physical or logical drives, and creates RAM disks for high-speed access, useful for applications needing fast disk access.
  35. [35]
    [PDF] man pages section 7: Device and Network Interfaces
    man pages section 7: Device and Network Interfaces • Last Revised 7 May 1997. Page 317. lofi – Loopback file driver. The lofi file driver exports a file as a ...
  36. [36]
    Device Mapper - The Linux Kernel documentation
    The Linux Kernel · Device Mapper¶. Guidance for writing policies · Cache · dm-delay · dm-clone · dm-crypt · dm-dust · dm-ebs · dm-flakey · dm ...
  37. [37]
    Device-mapper Resource Page - Sourceware
    The Device-mapper is a component of the linux kernel (since version 2.6) that supports logical volume management. It is required by LVM2 and EVMS. The original ...
  38. [38]
    Manage Virtual Hard Disks (VHD) - Microsoft Learn
    Jun 25, 2025 · Manage virtual hard disks (VHDs) with the Disk Management utility in Windows, where you can view, create, attach, and detach a VHD.Missing: loop | Show results with:loop
  39. [39]
    Amazon EBS volume types - AWS Documentation
    Oct 15, 2025 · Amazon EBS provides the following volume types, which differ in performance characteristics and price, so that you can tailor your storage performance and cost.AWS Nitro System · Amazon EBS Throughput... · General Purpose SSD volumesMissing: loop | Show results with:loop
  40. [40]
    ISO9660 Filesystem - The Linux Kernel documentation
    This 2nd Edition of Standard ECMA-119 is technically identical with ISO 9660. so it is a valid and gratis substitute of the official ISO specification.