Andrius Štikonas
5a83e741cb
Add support for detecting ISO9660 file systems.
...
BUG: 364476
2017-09-08 11:42:12 +01:00
Andrius Štikonas
7dba4b8245
Record sector size in FileSystem class.
2017-09-03 15:37:14 +01:00
Pali Rohár
feec00f4e7
Add basic support for UDF filesystem
...
For reading UDF label and UUID is needed blkid >= 2.30. For creating new
UDF filesystem is needed mkudffs binary from the udftools package.
When creating new UDF fileystem, revision 2.01 for hard disk media is used.
Therefore it is not possible to use it for optical (or other) medias.
Problems:
* Check for min and max capacity is incorrect as it depends on logical
(sector) size of the disk.
* Check for max label length is incorrect too as it depends on characters
itself in label.
* Specifying label is not working yet as FileSystem::create() does not get
label parameter.
* UDF filesystem should be used on unpartitioned disk, without MBR or GPT
and spanning whole disk, but KDE Partition Manager does not support it.
* When MBR is used, MBR partition id should be 0x07, but currently it is
incorrect 0x83. See: https://serverfault.com/a/829172 (same for GPT)
2017-08-31 10:12:44 +01:00
Andrius Štikonas
037380228d
QRegularExpression->QJson
...
lsblk LUKS mapping point parsing now uses json.
2017-07-04 14:42:39 +01:00
Andrius Štikonas
311a171307
Use QtJson to parse lsblk output.
2017-06-28 14:11:43 +01:00
Harald Sitter
984a4e9ace
fix device RO check
...
Summary:
- mark deviceNode const
- copy it as deviceName
- mutate deviceName by removing `/dev/`
- use the new deviceName for the read-only check
this makes sure we emit the unmodified deviceNode (e.g. /dev/vda) rather
than the name (e.g. vda). unbreaks for example calamares which doesn't
know what to do with "vda".
CCBUG: 378607
Test Plan:
- without fix clamares fails to list devices
- with the fix calamares lists devices
Reviewers: stikonas
Reviewed By: stikonas
Differential Revision: https://phabricator.kde.org/D6414
2017-06-28 13:51:27 +02:00
Andrius Štikonas
a35702e911
Use lsblk's TYPE=disk when scanning for devices.
...
The previous way relied on kernel device numbers but this gets ugly, especially
in cases when device number is not assigned such as virtio disks.
BUG: 378607
2017-06-22 03:11:58 +01:00
Andrius Štikonas
fda1e219de
Add more major device numbers for virtio.
...
BUG: 378607
2017-06-20 15:51:13 +01:00
Andrius Štikonas
d2ce014589
Use range based for instead of Q_FOREACH.
...
Bump Qt version requirements to 5.7.0
2017-06-01 11:16:09 +01:00
Alexander Schlarb
427e37a047
Prevent the libparted backend from exposing "null devices"
...
REVIEW: 129968
BUG: 375394
2017-02-25 13:45:22 +00:00
Teo Mrnjavac
876a3932fd
Do not filter out KVM virtual disks in LibPartedBackend::scanDevices.
2017-02-17 11:55:15 +01:00
Andrius Štikonas
16c12ddb9e
Both swap and LVM PV should not use KDiskFreeSpaceInfo.
2017-01-26 18:07:28 +00:00
Andrius Štikonas
901d01185f
Do not set LUKS logical sector size to 512.
...
This breaks used space reporting for LUKS encrypted LVM LV.
2017-01-25 18:21:25 +01:00
Andrius Štikonas
f8ba25fdfa
Improve used space detection to use fs utils when not mounted.
2017-01-05 17:27:17 +00:00
Andrius Štikonas
2e960d5c00
Make initLUKS function non-static.
2016-11-30 17:18:51 +00:00
Teo Mrnjavac
39ec355b70
Remove obsolete headers.
2016-11-30 16:42:03 +01:00
Andrius Štikonas
e42020dc9b
Disable loop devices for now.
...
BUG: https://calamares.io/bugs/browse/CAL-416
After the release we can break API and add option to include/exclude them.
2016-11-25 15:31:09 +00:00
Andrius Štikonas
3c58349561
Make sure KDiskFreeSpaceInfo is never used for swap.
2016-11-15 17:00:59 +00:00
Andrius Štikonas
e3214a1b48
Do not call KDiskFreeSpaceInfo::freeSpaceInfo without a non-empty mount point.
2016-11-05 20:29:31 +00:00
Andrius Štikonas
b539f835b1
Revert KAuth support. At the moment it causes more problems than helps.
2016-10-29 19:45:33 +01:00
Andrius Štikonas
28fa6ac5a4
Add support for GTP partition labels.
2016-09-24 22:15:15 +01:00
Chantara Tith
874900fe72
Move initLUKS from helpers to FS::luks.
2016-09-12 23:49:20 +07:00
Chantara Tith
bcd6156628
Reduce code duplication in handling mountPoint/mount/diskSpace.
2016-09-12 17:23:19 +07:00
Andrius Štikonas
b3e82d7c75
Cache LUKS specific variables during initial scan.
2016-09-04 23:32:00 +01:00
Andrius Štikonas
4889a0ef34
Remove some TODO comments.
2016-08-31 20:37:32 +01:00
Andrius Štikonas
5ab60c6dfa
Enable used space reporting for swap.
...
BUG: 367473
2016-08-29 12:12:57 +01:00
Andrius Štikonas
ef2c85e60f
Silence clang warning + some other small changes.
...
Fix a typo in a comment
2016-08-24 23:01:36 +01:00
Andrius Štikonas
4de925735e
Convert some for loops into for ranged based loops.
2016-08-15 17:20:50 +01:00
Andrius Štikonas
ca2e46a6e0
More work on C++11 for loops.
2016-08-15 17:20:50 +01:00
Chantara Tith
87e9bf9cb5
House-cleaning, removing finished TODO and FIXME tasks.
2016-08-15 17:20:50 +01:00
Chantara Tith
12a74b4a2b
Use VG as PV mount point.
2016-08-15 17:20:50 +01:00
Chantara Tith
0952ffb11f
Hardcode LUKS payload offset return value in byte size instead of sector number.
2016-08-15 17:20:50 +01:00
Chantara Tith
fcc8a7c992
Initial Device separation
2016-08-15 17:20:50 +01:00
Chantara Tith
0a6de0c2f0
Set VG name as PV mount point
2016-08-15 17:20:50 +01:00
Andrius Štikonas
0f33fe07c9
Fix coverity issues and some other minor simplifications.
2016-08-05 13:55:56 +01:00
Andrius Štikonas
0e9298baf8
Revert "Add KAuth helper to detectFileSystem."
...
This reverts commit 71921cf500
.
2016-07-29 18:15:28 +01:00
Andrius Štikonas
918cf2ffa4
Use more compact syntax for passing and returning kauth helper arguments.
2016-07-29 14:19:12 +01:00
Andrius Štikonas
a8b35c56a3
Fix btrfs support.
2016-07-27 20:55:35 +01:00
Andrius Štikonas
71921cf500
Add KAuth helper to detectFileSystem.
2016-07-25 16:33:49 +01:00
Andrius Štikonas
c4b28aa91f
Revert "Use udevadm for detecting file system type."
...
udevadm seems to suffer from race conditions and sometimes returns exit code 4.
This reverts commit 5ea32b446c
.
2016-07-24 21:36:56 +01:00
Andrius Štikonas
5ea32b446c
Use udevadm for detecting file system type.
2016-07-24 15:18:27 +01:00
Andrius Štikonas
2e9166d2d4
Improve comment of major device numbers.
...
Exclude read-only block devices.
2016-07-23 22:01:38 +01:00
Andrius Štikonas
c8e9c72d88
Look for more type of block devices.
2016-07-22 15:53:15 +01:00
Andrius Štikonas
b5d1529370
excludeReadOnly->excludeLoop.
2016-07-22 13:18:34 +01:00
Andrius Štikonas
4a0b8f8efb
Use lsblk to detect devices.
2016-07-22 12:56:59 +01:00
Andrius Štikonas
e64a82ff19
Use KAuth to get privileges needed for detecting partitions.
2016-07-22 12:00:01 +01:00
Andrius Štikonas
3a2b78e143
Improve semantic markup of translations.
2016-07-17 23:41:00 +01:00
Andrius Štikonas
5e982b5b1e
Fix memory leaks.
2016-06-02 13:46:16 +01:00
Andrius Štikonas
b4a13599aa
Libpartedbackend can also use KDiskFreeSpaceInfo for mounted luks partitions.
2016-05-22 00:52:07 +01:00
Andrius Štikonas
35a4798672
Add some support to get used space info for mounted LUKS partitions using KDiskFreeSpaceInfo.
2016-05-22 00:48:55 +01:00