diff options
author | Lucas Affonso Xavier de Morais | 2014-09-26 15:59:39 +0200 |
---|---|---|
committer | Michael Pereira Neves | 2014-10-28 14:14:50 +0100 |
commit | 5efbc0fa19e6b4f3d24f849a197af5f136d17355 (patch) | |
tree | 40e5059b846d1c34e86f00bea80cc84ce7a907cd | |
parent | [setup_partitions] make mounting more verbose (diff) | |
download | tm-scripts-5efbc0fa19e6b4f3d24f849a197af5f136d17355.tar.gz tm-scripts-5efbc0fa19e6b4f3d24f849a197af5f136d17355.tar.xz tm-scripts-5efbc0fa19e6b4f3d24f849a197af5f136d17355.zip |
[setup_partitions] -e option removed from all the echo commands, for ash compatibility.
-rw-r--r-- | partitioner/config | 17 | ||||
-rwxr-xr-x | remote/rootfs/rootfs-stage32/data/opt/openslx/scripts/systemd-setup_partitions | 12 |
2 files changed, 6 insertions, 23 deletions
diff --git a/partitioner/config b/partitioner/config deleted file mode 100644 index bf34dcca..00000000 --- a/partitioner/config +++ /dev/null @@ -1,17 +0,0 @@ -#Partitions -SLX_PARTITION_TYPE='GPT' -# SLX_CHOOSEN_DISK='sda' -SLX_AUTOMATIC_PARTITIONING='no' -SLX_DELETE_PARTITION_TABLE='no' -SLX_PARTITION_TABLE=' -44,10G,/tmp -43,10G,/boot,bootable -42,10G,/cache -41,10G,/home -40,5G,/teste' - -#Create GPT or msdos style partition table -#Choose disk to partition -#Don't be interactive, use carefully -#Override existing partitions -#Partition table in the format: ID,Size,Mountpoint,Bootable
\ No newline at end of file diff --git a/remote/rootfs/rootfs-stage32/data/opt/openslx/scripts/systemd-setup_partitions b/remote/rootfs/rootfs-stage32/data/opt/openslx/scripts/systemd-setup_partitions index 1f29ec7d..bd80890b 100755 --- a/remote/rootfs/rootfs-stage32/data/opt/openslx/scripts/systemd-setup_partitions +++ b/remote/rootfs/rootfs-stage32/data/opt/openslx/scripts/systemd-setup_partitions @@ -106,7 +106,7 @@ mount_partition () { mount -t auto -o noexec "$partition" "$mountpoint" || return $? fi fi - echo -e "${partition}\t${mountpoint}\tauto\t\tnoauto,noexec\t\t 0 0" >> "/etc/fstab" + echo "${partition}\t${mountpoint}\tauto\t\tnoauto,noexec\t\t 0 0" >> "/etc/fstab" } read_partitions () { @@ -123,7 +123,7 @@ read_partitions () { for part in $(cat /proc/partitions | tr -s ' ' | cut -d ' ' -f5 | grep -o -e "$hd[0-9][0-9]*$"); do LINE="/dev/$part " LINE=${LINE}$(sgdisk /dev/$hd -i ${part:3} | grep 'GUID code' | cut -d ' ' -f4) - echo -e $LINE >> "/etc/disk.partition" + echo $LINE >> "/etc/disk.partition" done fi done @@ -163,7 +163,7 @@ for PARTITION in $SLX_PARTITION_TABLE; do if diskfm "$tmppart"; then # echo "$tmppart is mounted to /mnt/tmp at $(sysup)" >/tmp/tmpready mount_temp "$mopt" "$tmppart" || continue - echo -e "${tmppart}\t/tmp\t\tauto\t\tnoexec\t 0 0" >> "/etc/fstab" + echo "${tmppart}\t/tmp\t\tauto\t\tnoexec\t 0 0" >> "/etc/fstab" HAVE_TEMP="yes" echo "$tmppart mounted on /tmp" else @@ -177,7 +177,7 @@ for PARTITION in $SLX_PARTITION_TABLE; do #mount -t auto ${openslxpart} /mnt/media/${openslxpart#/dev/*} \n\ #test -d /mnt/media/${openslxpart#/dev/*}/home && \ #ln -sf /media/${openslxpart#/dev/*} /var/home - echo -e "${openslxpart}\t/media/${openslxpart#/dev/*}\tauto\t\tnoauto\t\t 0 0" >> "/etc/fstab" + echo "${openslxpart}\t/media/${openslxpart#/dev/*}\tauto\t\tnoauto\t\t 0 0" >> "/etc/fstab" echo "special partition ${openslxpart} mounted on /media/${openslxpart#/dev/*}" done ;; @@ -185,7 +185,7 @@ for PARTITION in $SLX_PARTITION_TABLE; do # Check for standard swap partitions and make them available to the system HAVE_SWAP=no for swppart in $(grep -e "82$\|0657FD6D-A4AB-43C4-84E5-0933C84B4F4F$" /etc/disk.partition | cut -d ' ' -f1); do - echo -e "$swppart\tswap\t\tswap\t\tdefaults\t 0 0" >> "/etc/fstab" + echo "$swppart\tswap\t\tswap\t\tdefaults\t 0 0" >> "/etc/fstab" swapon "$swppart" -p 10 && HAVE_SWAP=yes # low priority, in case we have zram swap, prefer that) echo "swap partition found and activated" done @@ -210,7 +210,7 @@ done for linuxpart in $(grep -e "83$\|0FC63DAF-8483-4772-8E79-3D69D8477DE4$" /etc/disk.partition | cut -d ' ' -f1); do mountpoint="/media" mkdir -p "${mountpoint}/${linuxpart#/dev/*}" - echo -e "${linuxpart}\t${mountpoint}/${linuxpart#/dev/*}\tauto\t\tnoauto,noexec\t 0 0" >> "/etc/fstab" + echo "${linuxpart}\t${mountpoint}/${linuxpart#/dev/*}\tauto\t\tnoauto,noexec\t 0 0" >> "/etc/fstab" echo "linux partition ${linuxpart} mounted on ${mountpoint}/${linuxpart#/dev/*}" done |