This repository has been archived on 2023-08-20. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
RescueBootCD/build_initrd.sh

19 lines
418 B
Bash
Executable File

#!/bin/sh
# crear la imagen del rootfs
dd if=/dev/zero of=file.rootfs bs=1k count=4096
mke2fs -F -m 0 -N 2000 file.rootfs
#################################
# montar y copiar los ficheros
#################################
mount -t ext2 -o loop file.rootfs tmp.mountp
cp -dRvp rootfs/* tmp.mountp/
umount tmp.mountp
# comprimir
dd if=file.rootfs bs=1k | gzip -v9 > rootfs.gz
# borrar fichero temporal
rm file.rootfs