projects
/
live-boot-grml.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merging casper 1.226.
[live-boot-grml.git]
/
scripts
/
live
diff --git
a/scripts/live
b/scripts/live
index
26a6a46
..
cdcbc18
100755
(executable)
--- a/
scripts/live
+++ b/
scripts/live
@@
-667,7
+667,7
@@
is_nice_device ()
{
sysfs_path="${1#/sys}"
{
sysfs_path="${1#/sys}"
- if /lib/udev/path_id "${sysfs_path}" |
grep -E
-q "ID_PATH=(usb|pci-|platform-orion-ehci|platform-mmc|platform-mxsdhci|)"
+ if /lib/udev/path_id "${sysfs_path}" |
egrep
-q "ID_PATH=(usb|pci-|platform-orion-ehci|platform-mmc|platform-mxsdhci|)"
then
return 0
elif echo "${sysfs_path}" | grep -q '^/block/vd[a-z]$'
then
return 0
elif echo "${sysfs_path}" | grep -q '^/block/vd[a-z]$'
@@
-705,7
+705,7
@@
copy_live_to ()
if [ "${copytodev}" = "ram" ]
then
# copying to ram:
if [ "${copytodev}" = "ram" ]
then
# copying to ram:
- freespace=$(
expr $(awk '/MemFree/{print $2}' /proc/meminfo) + $( awk '/\<Cached/{print $2}' /proc/meminfo )
)
+ freespace=$(
awk '/^MemFree:/{f=$2} /^Cached:/{c=$2} END{print f+c}' /proc/meminfo
)
mount_options="-o size=${size}k"
free_string="memory"
fstype="tmpfs"
mount_options="-o size=${size}k"
free_string="memory"
fstype="tmpfs"
@@
-1008,7
+1008,7
@@
do_snap_copy ()
todev=$(awk -v pat="$(base_path ${todir})" '$2 == pat { print $1 }' /proc/mounts)
freespace=$(df -k | awk '/'${todev}'/{print $4}')
else
todev=$(awk -v pat="$(base_path ${todir})" '$2 == pat { print $1 }' /proc/mounts)
freespace=$(df -k | awk '/'${todev}'/{print $4}')
else
- freespace=$(
expr $(awk '/MemFree/{print $2}' /proc/meminfo) + $( awk '/\<Cached/{print $2}' /proc/meminfo)
)
+ freespace=$(
awk '/^MemFree:/{f=$2} /^Cached:/{c=$2} END{print f+c}' /proc/meminfo
)
fi
tomount="/mnt/tmpsnap"
fi
tomount="/mnt/tmpsnap"
@@
-1677,7
+1677,7
@@
find_livefs ()
# or do the scan of block devices
# prefer removable devices over non-removable devices, so scan them first
# or do the scan of block devices
# prefer removable devices over non-removable devices, so scan them first
- for sysblock in $(echo /sys/block/* | tr ' ' '\n' |
grep -vE
"/(loop|ram|dm-|fd)")
+ for sysblock in $(echo /sys/block/* | tr ' ' '\n' |
egrep -v
"/(loop|ram|dm-|fd)")
do
if [ "$(cat ${sysblock}/removable)" = "1" ]
then
do
if [ "$(cat ${sysblock}/removable)" = "1" ]
then
@@
-1918,9
+1918,7
@@
mountroot ()
umount "${rootmnt}/dev"
fi
umount "${rootmnt}/dev"
fi
- # Kill the debconf-communicate instance and close fd's associated with·
- # debconf-communicate.
- kill $DEBCONF_COMMUNICATE_PID
+ # Close the fd's associated with debconf-communicate
exec 3>&- 4<&-
rm -f /tmp/debconf-in.fifo
rm -f /tmp/debconf-out.fifo
exec 3>&- 4<&-
rm -f /tmp/debconf-in.fifo
rm -f /tmp/debconf-out.fifo