Преглед на файлове

New Core Storage blog post

Thomas Buck преди 8 години
родител
ревизия
b85ef99317
променени са 1 файла, в които са добавени 46 реда и са изтрити 0 реда
  1. 46
    0
      input/blog/2015/2015_08_06_core_storage.md

+ 46
- 0
input/blog/2015/2015_08_06_core_storage.md Целия файл

@@ -0,0 +1,46 @@
1
+title: Blog
2
+post: Core Storage Partition resizing
3
+date: 2015-08-06
4
+comments: true
5
+flattr: true
6
+twitter: xythobuz
7
+---
8
+
9
+## {{ page["post"] }}
10
+<!--%
11
+from datetime import datetime
12
+date = datetime.strptime(page["date"], "%Y-%m-%d").strftime("%B %d, %Y")
13
+print "*Posted at %s.*" % date
14
+%-->
15
+
16
+Basically, Disk Utility in Yosemite started using Core Storage sometimes when creating new partitions. Unfortunately, if it then encounters a Core Storage Volume, it completely shits its pants and doesn’t do anything anymore.
17
+
18
+Presumably, this will be fixed in the next release, El Capitan.
19
+
20
+In the meantime, some command line diskutil Foo is required to fix your partition map when Disk Utility does no longer want to do this.
21
+
22
+In my case, I wanted to shrink a Core Storage Logical Volume, to make room for a new NTFS partition shared between Mac and Windows. Of course, Windows can’t read the Core Storage Volume, and NTFS inside Core Storage is not even possible anyways.
23
+
24
+So, I needed to shrink the volume and add a new one. Between the steps, I tried again and again to use Disk Utility, but it only fucked up things more. So keep it closed and stay with diskutil.
25
+
26
+In the end, I had to do something like the following. diskN is the physical disk where everything was located, and diskNsX is the newly created partition.
27
+
28
+    diskutil list
29
+    diskutil cs list
30
+    
31
+    diskutil unmountDisk diskN
32
+
33
+Sometimes it seems to be possible to revert a Core Storage Volume, so you can go back to Disk Utility. However, this was not possible with my partition. So I continued like this:
34
+
35
+    diskutil cs resizeStack LVUUID partsize
36
+    sudo gpt -r show diskN
37
+
38
+Then find the start sector of the newly freed space, substract 262144 (= 128MiB) from size (Apple required padding between partitions), and use these numbers for your new partition (yours will differ!):
39
+
40
+    sudo gpt add -b 1700605768 -s 1698790088 -t windows diskN
41
+    sudo newfs_exfat -v "Shared" /dev/rdiskNsX
42
+    diskutil repairDisk diskN
43
+    for all partitions: diskutil repairVolume diskNsX
44
+
45
+And that’s it. Not as bad as it seemed.
46
+

Loading…
Отказ
Запис