Журнал лабораторных работ

Содержание

Журнал

Вторник (02/21/12)

/dev/pts/3
09:10:20
#losetup -a

/dev/pts/4
09:10:35
#losetup /dev/loop0 /tmp/disk.img

/dev/pts/3
09:10:35
#losetup /dev/loop0 /tmp/disk.img

/dev/pts/4
09:10:49
#fdisk /dev/loop0
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0x69eb0505.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/3
09:10:49
#fdisk /dev/loop0
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0x69eb0505.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/4
09:11:04
#fdisk -l /dev/loop0
Disk /dev/loop0: 1048 MB, 1048576000 bytes
255 heads, 63 sectors/track, 127 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/loop0 doesn't contain a valid partition table
/dev/pts/3
09:11:04
#fdisk -l /dev/loop0
Disk /dev/loop0: 1048 MB, 1048576000 bytes
255 heads, 63 sectors/track, 127 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/loop0 doesn't contain a valid partition table
/dev/pts/4
09:11:11
#fdisk
Usage:
 fdisk [options] <disk>    change partition table
 fdisk [options] -l <disk> list partition table(s)
 fdisk -s <partition>      give partition size(s) in blocks
Options:
 -b <size>                 sector size (512, 1024, 2048 or 4096)
 -c                        switch off DOS-compatible mode
 -h                        print help
 -u <size>                 give sizes in sectors instead of cylinders
 -v                        print version
 -C <number>               specify the number of cylinders
 -H <number>               specify the number of heads
 -S <number>               specify the number of sectors per track
/dev/pts/3
09:11:11
#fdisk
Usage:
 fdisk [options] <disk>    change partition table
 fdisk [options] -l <disk> list partition table(s)
 fdisk -s <partition>      give partition size(s) in blocks
Options:
 -b <size>                 sector size (512, 1024, 2048 or 4096)
 -c                        switch off DOS-compatible mode
 -h                        print help
 -u <size>                 give sizes in sectors instead of cylinders
 -v                        print version
 -C <number>               specify the number of cylinders
 -H <number>               specify the number of heads
 -S <number>               specify the number of sectors per track
/dev/pts/4
09:11:14
#losetup -a
/dev/loop0: [0801]:1736742 (/tmp/disk.img)
/dev/pts/3
09:11:14
#losetup -a
/dev/loop0: [0801]:1736742 (/tmp/disk.img)
/dev/pts/4
09:11:22
#cfdisk /dev/loop0
/dev/pts/3
09:11:22
#cfdisk /dev/loop0
/dev/pts/4
09:12:04
#cfdisk /dev/loop0
/dev/pts/3
09:12:04
#cfdisk /dev/loop0
/dev/pts/4
09:12:09
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
/dev/sda5            6687        7295     4883728+  83  Linux
Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xf64ce41d
   Device Boot      Start         End      Blocks   Id  System
/dev/pts/3
09:12:09
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
/dev/sda5            6687        7295     4883728+  83  Linux
Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xf64ce41d
   Device Boot      Start         End      Blocks   Id  System
/dev/pts/4
09:12:17
#kpartx
usage : kpartx [-a|-d|-l] [-v] wholedisk
        -a add partition devmappings
        -d del partition devmappings
        -l list partitions devmappings that would be added by -a
        -p set device name-partition number delimiter
        -g force GUID partition table (GPT)
        -v verbose
/dev/pts/3
09:12:17
#kpartx
usage : kpartx [-a|-d|-l] [-v] wholedisk
        -a add partition devmappings
        -d del partition devmappings
        -l list partitions devmappings that would be added by -a
        -p set device name-partition number delimiter
        -g force GUID partition table (GPT)
        -v verbose
/dev/pts/4
09:12:31
#kpartx /dev/loop0
/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?
loop0p1 : 0 192717 /dev/loop0 63
loop0p2 : 0 385560 /dev/loop0 192780
/dev/pts/3
09:12:31
#kpartx /dev/loop0
/proc/misc: No entry for device-mapper found
Is device-mapper driver missing from kernel?
loop0p1 : 0 192717 /dev/loop0 63
loop0p2 : 0 385560 /dev/loop0 192780
/dev/pts/4
09:12:38
#fdisk /dev/loop0
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/3
09:12:38
#fdisk /dev/loop0
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/4
09:12:50
#mkfs
Usage: mkfs [-V] [-t fstype] [fs-options] device [size]
/dev/pts/3
09:12:50
#mkfs
Usage: mkfs [-V] [-t fstype] [fs-options] device [size]
/dev/pts/4
09:13:37
#mkfs -t ext3 /dev/loop0p1
mke2fs 1.41.12 (17-May-2010)
Could not stat /dev/loop0p1 --- No such file or directory
The device apparently does not exist; did you specify it correctly?
/dev/pts/3
09:13:37
#mkfs -t ext3 /dev/loop0p1
mke2fs 1.41.12 (17-May-2010)
Could not stat /dev/loop0p1 --- No such file or directory
The device apparently does not exist; did you specify it correctly?
/dev/pts/4
09:13:59
#kpartx -a /dev/loop0

/dev/pts/3
09:13:59
#kpartx -a /dev/loop0

/dev/pts/4
09:15:16
#fdisk /dev/loop
Unable to open /dev/loop
/dev/pts/3
09:15:16
#fdisk /dev/loop
Unable to open /dev/loop
/dev/pts/4
09:15:19
#fdisk /dev/loop0
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/3
09:15:19
#fdisk /dev/loop0
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/4
09:15:25
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/3
09:15:25
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/4
09:15:30
#losetup -a
/dev/loop0: [0801]:1736742 (/tmp/disk.img)
/dev/pts/3
09:15:30
#losetup -a
/dev/loop0: [0801]:1736742 (/tmp/disk.img)
/dev/pts/4
09:15:56
#ls -l /dev/mapper/
total 0
crw------- 1 root root 10, 236 Feb 21 10:12 control
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p1 -> ../dm-0
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p2 -> ../dm-1
/dev/pts/3
09:15:56
#ls -l /dev/mapper/
total 0
crw------- 1 root root 10, 236 Feb 21 10:12 control
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p1 -> ../dm-0
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p2 -> ../dm-1
/dev/pts/4
09:16:10
#mkfs /dev/loop0p1
mke2fs 1.41.12 (17-May-2010)
Could not stat /dev/loop0p1 --- No such file or directory
The device apparently does not exist; did you specify it correctly?
/dev/pts/3
09:16:10
#mkfs /dev/loop0p1
mke2fs 1.41.12 (17-May-2010)
Could not stat /dev/loop0p1 --- No such file or directory
The device apparently does not exist; did you specify it correctly?
/dev/pts/4
09:17:06
#mkfs /dev/loop0
mke2fs 1.41.12 (17-May-2010)
/dev/loop0 is apparently in use by the system; will not make a filesystem here!
/dev/pts/3
09:17:06
#mkfs /dev/loop0
mke2fs 1.41.12 (17-May-2010)
/dev/loop0 is apparently in use by the system; will not make a filesystem here!
/dev/pts/4
09:17:12
#mkisofs
bash: mkisofs: command not found
/dev/pts/3
09:17:12
#mkisofs
bash: mkisofs: command not found
/dev/pts/4
09:18:00
#mkisofs
bash: mkisofs: command not found
/dev/pts/3
09:18:00
#mkisofs
bash: mkisofs: command not found
/dev/pts/4
09:18:08
#ls -l /dev/mapper/
total 0
crw------- 1 root root 10, 236 Feb 21 10:12 control
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p1 -> ../dm-0
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p2 -> ../dm-1
/dev/pts/3
09:18:08
#ls -l /dev/mapper/
total 0
crw------- 1 root root 10, 236 Feb 21 10:12 control
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p1 -> ../dm-0
lrwxrwxrwx 1 root root       7 Feb 21 10:15 loop0p2 -> ../dm-1
/dev/pts/4
09:20:31
#mkfs /dev/mapper/loop0p2 -t ext3
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
48384 inodes, 192780 blocks
9639 blocks (5.00%) reserved for the super user
First data block=1
Maximum filesystem blocks=67371008
24 block groups
8192 blocks per group, 8192 fragments per group
2016 inodes per group
Superblock backups stored on blocks:
        8193, 24577, 40961, 57345, 73729
Writing inode tables: done
Creating journal (4096 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 22 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
/dev/pts/3
09:20:31
#mkfs /dev/mapper/loop0p2 -t ext3
mke2fs 1.41.12 (17-May-2010)
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
48384 inodes, 192780 blocks
9639 blocks (5.00%) reserved for the super user
First data block=1
Maximum filesystem blocks=67371008
24 block groups
8192 blocks per group, 8192 fragments per group
2016 inodes per group
Superblock backups stored on blocks:
        8193, 24577, 40961, 57345, 73729
Writing inode tables: done
Creating journal (4096 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 22 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.
/dev/pts/4
09:22:57
#fdisk
Usage:
 fdisk [options] <disk>    change partition table
 fdisk [options] -l <disk> list partition table(s)
 fdisk -s <partition>      give partition size(s) in blocks
Options:
 -b <size>                 sector size (512, 1024, 2048 or 4096)
 -c                        switch off DOS-compatible mode
 -h                        print help
 -u <size>                 give sizes in sectors instead of cylinders
 -v                        print version
 -C <number>               specify the number of cylinders
 -H <number>               specify the number of heads
 -S <number>               specify the number of sectors per track
/dev/pts/3
09:22:57
#fdisk
Usage:
 fdisk [options] <disk>    change partition table
 fdisk [options] -l <disk> list partition table(s)
 fdisk -s <partition>      give partition size(s) in blocks
Options:
 -b <size>                 sector size (512, 1024, 2048 or 4096)
 -c                        switch off DOS-compatible mode
 -h                        print help
 -u <size>                 give sizes in sectors instead of cylinders
 -v                        print version
 -C <number>               specify the number of cylinders
 -H <number>               specify the number of heads
 -S <number>               specify the number of sectors per track
09:23:02
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/4
09:23:02
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
09:23:05
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/3
09:23:05
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/4
09:23:49
#cfdisk /dev/loop0
/dev/pts/3
09:23:49
#cfdisk /dev/loop0
/dev/pts/4
09:25:00
#losetup -a
/dev/loop0: [0801]:1736742 (/tmp/disk.img)
/dev/pts/3
09:25:00
#losetup -a
/dev/loop0: [0801]:1736742 (/tmp/disk.img)
/dev/pts/4
09:25:14
#fdisk /dev/loop0
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/3
09:25:14
#fdisk /dev/loop0
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').
Command (m for help): ^C
/dev/pts/4
09:25:32
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/3
09:25:32
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/4
09:25:36
#ls -l /dev/loop1
brw-rw---- 1 root disk 7, 1 Feb 21 09:41 /dev/loop1
/dev/pts/3
09:25:36
#ls -l /dev/loop1
brw-rw---- 1 root disk 7, 1 Feb 21 09:41 /dev/loop1
/dev/pts/4
09:26:21
#ls -l /dev/mapper
total 0
crw------- 1 root root 10, 236 Feb 21 10:12 control
lrwxrwxrwx 1 root root       7 Feb 21 10:20 loop0p1 -> ../dm-0
lrwxrwxrwx 1 root root       7 Feb 21 10:22 loop0p2 -> ../dm-1
/dev/pts/3
09:26:21
#ls -l /dev/mapper
total 0
crw------- 1 root root 10, 236 Feb 21 10:12 control
lrwxrwxrwx 1 root root       7 Feb 21 10:20 loop0p1 -> ../dm-0
lrwxrwxrwx 1 root root       7 Feb 21 10:22 loop0p2 -> ../dm-1
/dev/pts/4
09:26:28
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/3
09:26:28
#fdisk -l
Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000b4942
   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        6079    48827392   83  Linux
/dev/sda2            6079        6687     4882432   82  Linux swap / Solaris
/dev/sda3            6687        7295     4883760    5  Extended
...
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-0 doesn't contain a valid partition table
Disk /dev/dm-1: 197 MB, 197406720 bytes
255 heads, 63 sectors/track, 24 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/dm-1 doesn't contain a valid partition table
/dev/pts/4
09:27:08
#fdisk -l /dev/loop0
Disk /dev/loop0: 1048 MB, 1048576000 bytes
255 heads, 63 sectors/track, 127 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
      Device Boot      Start         End      Blocks   Id  System
/dev/loop0p1               1          12       96358+  83  Linux
/dev/loop0p2              13          36      192780   83  Linux
/dev/pts/3
09:27:08
#fdisk -l /dev/loop0
Disk /dev/loop0: 1048 MB, 1048576000 bytes
255 heads, 63 sectors/track, 127 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
      Device Boot      Start         End      Blocks   Id  System
/dev/loop0p1               1          12       96358+  83  Linux
/dev/loop0p2              13          36      192780   83  Linux
09:27:21
#mount /dev/mapper/loop0p1 /mnt

/dev/pts/4
09:27:21
#mount /dev/mapper/loop0p1 /mnt

09:29:03
#df -h /mnt
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/loop0p1    92M  1.6M   85M   2% /mnt
/dev/pts/3
09:29:03
#df -h /mnt
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/loop0p1    92M  1.6M   85M   2% /mnt
/dev/pts/4
09:29:11
#apt-get install mdadm
Unpacking mdadm (from .../mdadm_3.1.4-1+8efb9d1+squeeze1_i386.deb) ...
Processing triggers for man-db ...
Setting up mdadm (3.1.4-1+8efb9d1+squeeze1) ...
Generating array device nodes... done.
Generating mdadm.conf... done.
update-initramfs: deferring update (trigger activated)
Starting MD monitoring service: mdadm --monitor.
Assembling MD arrays...done (no arrays found in config file or automatically).
Processing triggers for initramfs-tools ...
update-initramfs: Generating /boot/initrd.img-2.6.39-bpo.2-686-pae
W: mdadm: /etc/mdadm/mdadm.conf defines no arrays.
W: mdadm: no arrays defined in configuration file.
/dev/pts/3
09:29:11
#apt-get install mdadm
Unpacking mdadm (from .../mdadm_3.1.4-1+8efb9d1+squeeze1_i386.deb) ...
Processing triggers for man-db ...
Setting up mdadm (3.1.4-1+8efb9d1+squeeze1) ...
Generating array device nodes... done.
Generating mdadm.conf... done.
update-initramfs: deferring update (trigger activated)
Starting MD monitoring service: mdadm --monitor.
Assembling MD arrays...done (no arrays found in config file or automatically).
Processing triggers for initramfs-tools ...
update-initramfs: Generating /boot/initrd.img-2.6.39-bpo.2-686-pae
W: mdadm: /etc/mdadm/mdadm.conf defines no arrays.
W: mdadm: no arrays defined in configuration file.
/dev/pts/4
09:37:09
#cat /proc/mdstat
Personalities :
unused devices: <none>
/dev/pts/3
09:37:09
#cat /proc/mdstat
Personalities :
unused devices: <none>
/dev/pts/4
09:37:35
#dd -if=/dev/zero bs=1024k count=100 -of=/tmp/disk1.img
dd: invalid option -- 'i'
Try `dd --help' for more information.
/dev/pts/3
09:37:35
#dd -if=/dev/zero bs=1024k count=100 -of=/tmp/disk1.img
dd: invalid option -- 'i'
Try `dd --help' for more information.
09:39:28
#dd if=/dev/zero bs=1024k count=100 of=/tmp/disk1.img
100+0 records in
100+0 records out
104857600 bytes (105 MB) copied, 0.242695 s, 432 MB/s
/dev/pts/4
09:39:28
#dd if=/dev/zero bs=1024k count=100 of=/tmp/disk1.img
100+0 records in
100+0 records out
104857600 bytes (105 MB) copied, 0.242695 s, 432 MB/s
09:39:50
#dd if=/dev/zero bs=1024k count=100 of=/tmp/disk2.img
100+0 records in
100+0 records out
104857600 bytes (105 MB) copied, 0.225552 s, 465 MB/s
/dev/pts/3
09:39:50
#dd if=/dev/zero bs=1024k count=100 of=/tmp/disk2.img
100+0 records in
100+0 records out
104857600 bytes (105 MB) copied, 0.225552 s, 465 MB/s
/dev/pts/4
09:39:54
#losetup
Usage:
 losetup loop_device                             give info
 losetup -a | --all                              list all used
 losetup -d | --detach <loopdev> [<loopdev> ...] delete
 losetup -f | --find                             find unused
 losetup -c | --set-capacity <loopdev>           resize
 losetup -j | --associated <file> [-o <num>]     list all associated with <file>
 losetup [ options ] {-f|--find|loopdev} <file>  setup
Options:
 -e | --encryption <type> enable data encryption with specified <name/num>
...
 -p | --pass-fd <num>     read passphrase from file descriptor <num>
 -r | --read-only         setup read-only loop device
      --show              print device name (with -f <file>)
 -N | --nohashpass        Do not hash the given password (Debian hashes)
 -k | --keybits <num>     specify number of bits in the hashed key given
                          to the cipher.  Some ciphers support several key
                          sizes and might be more efficient with a smaller
                          key size.  Key sizes < 128 are generally not
                          recommended
 -v | --verbose           verbose mode
/dev/pts/3
09:39:54
#losetup
Usage:
 losetup loop_device                             give info
 losetup -a | --all                              list all used
 losetup -d | --detach <loopdev> [<loopdev> ...] delete
 losetup -f | --find                             find unused
 losetup -c | --set-capacity <loopdev>           resize
 losetup -j | --associated <file> [-o <num>]     list all associated with <file>
 losetup [ options ] {-f|--find|loopdev} <file>  setup
Options:
 -e | --encryption <type> enable data encryption with specified <name/num>
...
 -p | --pass-fd <num>     read passphrase from file descriptor <num>
 -r | --read-only         setup read-only loop device
      --show              print device name (with -f <file>)
 -N | --nohashpass        Do not hash the given password (Debian hashes)
 -k | --keybits <num>     specify number of bits in the hashed key given
                          to the cipher.  Some ciphers support several key
                          sizes and might be more efficient with a smaller
                          key size.  Key sizes < 128 are generally not
                          recommended
 -v | --verbose           verbose mode
/dev/pts/4
09:39:59
#losetup -d /dev/loop0
loop: can't delete device /dev/loop0: Device or resource busy
/dev/pts/3
09:39:59
#losetup -d /dev/loop0
loop: can't delete device /dev/loop0: Device or resource busy
/dev/pts/4
09:40:08
#umount /mnt

/dev/pts/3
09:40:08
#umount /mnt

/dev/pts/4
09:40:13
#losetup -d /dev/loop0
loop: can't delete device /dev/loop0: Device or resource busy
/dev/pts/3
09:40:13
#losetup -d /dev/loop0
loop: can't delete device /dev/loop0: Device or resource busy
/dev/pts/4
09:40:14
#losetup -d /dev/loop0
loop: can't delete device /dev/loop0: Device or resource busy
/dev/pts/3
09:40:14
#losetup -d /dev/loop0
loop: can't delete device /dev/loop0: Device or resource busy
/dev/pts/4
09:40:35
#kraptx -d /dev/loop0
bash: kraptx: command not found
/dev/pts/3
09:40:35
#kraptx -d /dev/loop0
bash: kraptx: command not found
/dev/pts/4
09:40:56
#kpartx -d /dev/loop0

/dev/pts/3
09:40:56
#kpartx -d /dev/loop0

Файлы

  • /proc/mdstat
  • /proc/mdstat
    >
    Personalities :
    unused devices: <none>
    

    Статистика

    Время первой команды журнала09:10:20 2012- 2-21
    Время последней команды журнала09:40:56 2012- 2-21
    Количество командных строк в журнале101
    Процент команд с ненулевым кодом завершения, %25.74
    Процент синтаксически неверно набранных команд, % 5.94
    Суммарное время работы с терминалом *, час 0.51
    Количество командных строк в единицу времени, команда/мин 3.30
    Частота использования команд
    fdisk30|=============================| 29.70%
    losetup17|================| 16.83%
    mkfs10|=========| 9.90%
    ls8|=======| 7.92%
    kpartx8|=======| 7.92%
    cfdisk6|=====| 5.94%
    dd6|=====| 5.94%
    mkisofs4|===| 3.96%
    df2|=| 1.98%
    cat2|=| 1.98%
    umount2|=| 1.98%
    apt-get2|=| 1.98%
    mount2|=| 1.98%
    kraptx2|=| 1.98%
    ____
    *) Интервалы неактивности длительностью 30 минут и более не учитываются

    Справка

    Для того чтобы использовать LiLaLo, не нужно знать ничего особенного: всё происходит само собой. Однако, чтобы ведение и последующее использование журналов было как можно более эффективным, желательно иметь в виду следующее:
    1. В журнал автоматически попадают все команды, данные в любом терминале системы.

    2. Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду w. В поле WHAT, соответствующем текущему терминалу, должна быть указана программа script.

    3. Команды, при наборе которых были допущены синтаксические ошибки, выводятся перечёркнутым текстом:
      $ l s-l
      bash: l: command not found
      

    4. Если код завершения команды равен нулю, команда была выполнена без ошибок. Команды, код завершения которых отличен от нуля, выделяются цветом.
      $ test 5 -lt 4
      Обратите внимание на то, что код завершения команды может быть отличен от нуля не только в тех случаях, когда команда была выполнена с ошибкой. Многие команды используют код завершения, например, для того чтобы показать результаты проверки

    5. Команды, ход выполнения которых был прерван пользователем, выделяются цветом.
      $ find / -name abc
      find: /home/devi-orig/.gnome2: Keine Berechtigung
      find: /home/devi-orig/.gnome2_private: Keine Berechtigung
      find: /home/devi-orig/.nautilus/metafiles: Keine Berechtigung
      find: /home/devi-orig/.metacity: Keine Berechtigung
      find: /home/devi-orig/.inkscape: Keine Berechtigung
      ^C
      

    6. Команды, выполненные с привилегиями суперпользователя, выделяются слева красной чертой.
      # id
      uid=0(root) gid=0(root) Gruppen=0(root)
      

    7. Изменения, внесённые в текстовый файл с помощью редактора, запоминаются и показываются в журнале в формате ed. Строки, начинающиеся символом "<", удалены, а строки, начинающиеся символом ">" -- добавлены.
      $ vi ~/.bashrc
      2a3,5
      >    if [ -f /usr/local/etc/bash_completion ]; then
      >         . /usr/local/etc/bash_completion
      >        fi
      

    8. Для того чтобы изменить файл в соответствии с показанными в диффшоте изменениями, можно воспользоваться командой patch. Нужно скопировать изменения, запустить программу patch, указав в качестве её аргумента файл, к которому применяются изменения, и всавить скопированный текст:
      $ patch ~/.bashrc
      В данном случае изменения применяются к файлу ~/.bashrc

    9. Для того чтобы получить краткую справочную информацию о команде, нужно подвести к ней мышь. Во всплывающей подсказке появится краткое описание команды.

      Если справочная информация о команде есть, команда выделяется голубым фоном, например: vi. Если справочная информация отсутствует, команда выделяется розовым фоном, например: notepad.exe. Справочная информация может отсутствовать в том случае, если (1) команда введена неверно; (2) если распознавание команды LiLaLo выполнено неверно; (3) если информация о команде неизвестна LiLaLo. Последнее возможно для редких команд.

    10. Большие, в особенности многострочные, всплывающие подсказки лучше всего показываются браузерами KDE Konqueror, Apple Safari и Microsoft Internet Explorer. В браузерах Mozilla и Firefox они отображаются не полностью, а вместо перевода строки выводится специальный символ.

    11. Время ввода команды, показанное в журнале, соответствует времени начала ввода командной строки, которое равно тому моменту, когда на терминале появилось приглашение интерпретатора

    12. Имя терминала, на котором была введена команда, показано в специальном блоке. Этот блок показывается только в том случае, если терминал текущей команды отличается от терминала предыдущей.

    13. Вывод не интересующих вас в настоящий момент элементов журнала, таких как время, имя терминала и других, можно отключить. Для этого нужно воспользоваться формой управления журналом вверху страницы.

    14. Небольшие комментарии к командам можно вставлять прямо из командной строки. Комментарий вводится прямо в командную строку, после символов #^ или #v. Символы ^ и v показывают направление выбора команды, к которой относится комментарий: ^ - к предыдущей, v - к следующей. Например, если в командной строке было введено:

      $ whoami
      
      user
      
      $ #^ Интересно, кто я?
      
      в журнале это будет выглядеть так:
      $ whoami
      
      user
      
      Интересно, кто я?

    15. Если комментарий содержит несколько строк, его можно вставить в журнал следующим образом:

      $ whoami
      
      user
      
      $ cat > /dev/null #^ Интересно, кто я?
      
      Программа whoami выводит имя пользователя, под которым 
      мы зарегистрировались в системе.
      -
      Она не может ответить на вопрос о нашем назначении 
      в этом мире.
      
      В журнале это будет выглядеть так:
      $ whoami
      user
      
      Интересно, кто я?
      Программа whoami выводит имя пользователя, под которым
      мы зарегистрировались в системе.

      Она не может ответить на вопрос о нашем назначении
      в этом мире.
      Для разделения нескольких абзацев между собой используйте символ "-", один в строке.

    16. Комментарии, не относящиеся непосредственно ни к какой из команд, добавляются точно таким же способом, только вместо симолов #^ или #v нужно использовать символы #=

    17. Содержимое файла может быть показано в журнале. Для этого его нужно вывести с помощью программы cat. Если вывод команды отметить симоволами #!, содержимое файла будет показано в журнале в специально отведённой для этого секции.
    18. Для того чтобы вставить скриншот интересующего вас окна в журнал, нужно воспользоваться командой l3shot. После того как команда вызвана, нужно с помощью мыши выбрать окно, которое должно быть в журнале.
    19. Команды в журнале расположены в хронологическом порядке. Если две команды давались одна за другой, но на разных терминалах, в журнале они будут рядом, даже если они не имеют друг к другу никакого отношения.
      1
          2
      3   
          4
      
      Группы команд, выполненных на разных терминалах, разделяются специальной линией. Под этой линией в правом углу показано имя терминала, на котором выполнялись команды. Для того чтобы посмотреть команды только одного сенса, нужно щёкнуть по этому названию.

    О программе

    LiLaLo (L3) расшифровывается как Live Lab Log.
    Программа разработана для повышения эффективности обучения Unix/Linux-системам.
    (c) Игорь Чубин, 2004-2008

    $Id$