Article Title: losetup: Set and control loopdevices. Linux is a technology channel of the IT lab in China. Including desktop applications, Linux system management, kernel research, embedded systems, open source, and other basic categories losetup: Set and control loop devices
Name Losetup-set and control loop devices
Grammar Losetup [-e encryption] [-o offset] loop_device file losetup [-d] loop_device
Description Losetup is used to combine the loop device with the file or block device, and split the device. query the status before the loop device object, for example, only set the parameter Number of loop_device. the current status of the loop device is displayed.
Item -D
Detach a file or package from a loop
-E encryption
Enable resource encoding. The following column lists the optional parameter numbers:
NONE
Do not code (fixed value ).
XOR
Use simple XOR code encoding
DES
Use DES to code. the DES encoding function must be added to the kernel. DES code encoding is to use the starting value as the password protection to prevent others from breaking through the wordcode method.
-O offset
When the resource is opened, the resource translation (offset) is several bytes to connect with the file or configuration.
File case /Dev/loop0,/dev/loop1,... loop devices (major = 7)
Example If the core uses a model group, you must first use the following command to load the model group.
# Insmod loop. o
The following column is a simple single example for loop installation.
Dd if =/dev/zero of =/file bs = 1 k count = 100
Losetup-e des/dev/loop0/file
Password:
Init (up to 16 hex digits ):
Mkfs-t ext2/dev/loop0 100
Mount-t ext2/dev/loop0/mnt
...
Umount/dev/loop0
Losetup-d/dev/loop0
The core uses a modulo group, and the lower column is used to remove the loop group.
# Rmmod loop
Limits DES code encoding is slow for 10 minutes, but XOR is weak for 10 minutes.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service