Bugzilla – Attachment 66188 Details for
Bug 147584
powersaved remounts all file systems during boot
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
IDP Log In
|
Forgot Password
[patch]
patch for /usr/lib/powersave/scripts
bug-147584.patch (text/plain), 3.22 KB, created by
Forgotten User ZhJd0F0L3x
on 2006-02-02 14:41:10 UTC
(
hide
)
Description:
patch for /usr/lib/powersave/scripts
Filename:
MIME Type:
Creator:
Forgotten User ZhJd0F0L3x
Created:
2006-02-02 14:41:10 UTC
Size:
3.22 KB
patch
obsolete
>Index: set_disk_settings >=================================================================== >--- set_disk_settings (revision 1818) >+++ set_disk_settings (working copy) >@@ -33,6 +33,9 @@ > # but there maybe added more in future. > # > >+# where do we store if _we_ remounted a device? >+STORE="/var/run/powersaved.remount" >+ > # The script might take following parameters: > # > # 1) The powersave daemon event that caused the script to be invoked >@@ -102,7 +105,7 @@ > # proper commit=XXX settings if necessary > do_remounts() { > >- local DEV MP FST OPTS DUMP PASS REMOUNT >+ local DEV MP FST OPTS OLDOPTS DUMP PASS REMOUNT LINE > > REMOUNT=$1 > >@@ -110,28 +113,39 @@ > > case $REMOUNT in > yes) >+ rm -f $STORE # better safe than sorry. > while read DEV MP FST OPTS DUMP PASS ; do >+ OLDOPTS=$OPTS > OPTS=${OPTS//commit=[0-9]*/} > OPTS=${OPTS//,,/,} > case "$FST" in >- "ext3") mount $DEV -t $FST $MP -o remount,$OPTS,commit=$HD_MAX_AGE ;; >- "reiserfs") [ "$HD_NOATIME" = "yes" ] && OPTS="$OPTS,noatime" >- mount $DEV -t $FST $MP -o remount,$OPTS,commit=$HD_MAX_AGE ;; >- "xfs") mount $DEV -t $FST $MP -o remount,$OPTS ;; >+ "ext3") >+ DEBUG "mount $DEV -t $FST $MP -o remount,$OPTS,commit=$HD_MAX_AGE" DIAG >+ mount $DEV -t $FST $MP -o remount,$OPTS,commit=$HD_MAX_AGE >+ echo "$DEV -t $FST $MP -o remount,$OLDOPTS" >> $STORE >+ ;; >+ "reiserfs") >+ [ "$HD_NOATIME" = "yes" ] && OPTS="$OPTS,noatime" >+ DEBUG "mount $DEV -t $FST $MP -o remount,$OPTS,commit=$HD_MAX_AGE" DIAG >+ mount $DEV -t $FST $MP -o remount,$OPTS,commit=$HD_MAX_AGE >+ echo "$DEV -t $FST $MP -o remount,$OLDOPTS" >> $STORE >+ ;; >+ "xfs") >+ DEBUG "mount $DEV -t $FST $MP -o remount,$OPTS" DIAG >+ mount $DEV -t $FST $MP -o remount,$OPTS >+ echo "$DEV -t $FST $MP -o remount,$OLDOPTS" >> $STORE >+ ;; > esac > done < /etc/mtab > ;; > no) >- while read DEV MP FST OPTS DUMP PASS ; do >- OPTS=${OPTS//commit=[0-9]*/} >- OPTS=${OPTS//,,/,} >- case "$FST" in >- "ext3") mount $DEV -t $FST $MP -o remount,$OPTS ;; >- "reiserfs") [ "$HD_NOATIME" = "yes" ] && OPTS="${OPTS//noatime/}" >- mount $DEV -t $FST $MP -o remount,$OPTS ;; >- "xfs") mount $DEV -t $FST $MP -o remount,$OPTS ;; >- esac >- done < /etc/mtab >+ if [ -f $STORE ]; then >+ while read LINE; do >+ DEBUG "remounting with original options: 'mount $LINE'" DIAG >+ mount $LINE >+ done < $STORE >+ rm $STORE >+ fi > ;; > *) DEBUG "invalid function call: do_remounts '$REMOUNT'" ERROR > return 1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 147584
: 66188