NetApp and Linux: Difference between revisions

From Lolly's Wiki
Jump to navigationJump to search
No edit summary
Line 20: Line 20:
/dev/sda6        25393152    33552383    4079616  82  Linux swap / Solaris
/dev/sda6        25393152    33552383    4079616  82  Linux swap / Solaris
</source>
</source>
Partition 2 does not matter because it is just metadata of partitioning. We are aligned!

Revision as of 12:19, 17 August 2015

Linux NetApp

Check partitioning

Maybe this works:

# fdisk -l /dev/sda | awk '/^\/dev\//{fieldnum=2;if($fielnum=="*"){fieldnum++}blockalign=$fieldnum/8;if(blockalign!=int(blockalign)){match($0,$fieldnum);printf "%s <<<<<<< Bucket %d\n",substr($0,0,RSTART-2)"_"substr($0,RSTART,RLENGTH)"_"substr($0,RSTART+RLENGTH+1),8*(blockalign-int(blockalign));}else{print $0;}next;}{print;}'

Disk /dev/sda: 17.2 GB, 17179869184 bytes
64 heads, 32 sectors/track, 16384 cylinders, total 33554432 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d6bea

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048    13672447     6835200   83  Linux
/dev/sda2       _13674494_   33552383     9938945    5  Extended <<<<<<< Bucket 6
/dev/sda5        13674496    25391103     5858304   83  Linux
/dev/sda6        25393152    33552383     4079616   82  Linux swap / Solaris

Partition 2 does not matter because it is just metadata of partitioning. We are aligned!