wip
This commit is contained in:
parent
d4f8224833
commit
f06ecd1665
1 changed files with 16 additions and 0 deletions
16
entry.sh
16
entry.sh
|
@ -2,7 +2,23 @@
|
||||||
|
|
||||||
function first_stage(){
|
function first_stage(){
|
||||||
echo foo first_stage
|
echo foo first_stage
|
||||||
|
creating image file
|
||||||
|
dd if=/dev/zero of=/root/disk.img bs=1M count=512
|
||||||
|
losetup -f /root/disk.img
|
||||||
|
(
|
||||||
|
echo o # Create a new empty DOS partition table
|
||||||
|
echo n # Add a new partition
|
||||||
|
echo p # Primary partition
|
||||||
|
echo 1 # Partition number
|
||||||
|
echo # First sector (Accept default: 1)
|
||||||
|
echo # Last sector (Accept default: varies)
|
||||||
|
echo w # Write changes
|
||||||
|
) | fdisk /dev/loop0
|
||||||
|
losetup -d /dev/loop0
|
||||||
|
losetup -P /root/disk.img /dev/loop0
|
||||||
|
lsblk
|
||||||
echo mount divice to $TARGET
|
echo mount divice to $TARGET
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function second_stage(){
|
function second_stage(){
|
||||||
|
|
Loading…
Reference in a new issue