| The Following User Says Thank You to peterleinchen For This Useful Post: | ||
|
|
07-13-2012
, 06:45 PM
|
|
|
Posts: 3,840 |
Thanked: 5,613 times |
Joined on Mar 2011
|
#92
|
| The Following 4 Users Say Thank You to Estel For This Useful Post: | ||
|
|
07-13-2012
, 06:45 PM
|
|
Posts: 1,378 |
Thanked: 1,911 times |
Joined on Apr 2010
@ St. Helens, England
|
#93
|
| The Following User Says Thank You to sixwheeledbeast For This Useful Post: | ||
|
|
07-13-2012
, 07:15 PM
|
|
|
Posts: 947 |
Thanked: 1,106 times |
Joined on Aug 2010
@ Ruhrgebiet, Germany
|
#94
|
...
that having fragmented swap with lower priority (as when enabling 2nd swap with higher priority, without disabling 1st one), won't work well, as due to flawed implementation, there are still writes occurring on lower-priority (=fragmented) swap:
...
| The Following User Says Thank You to peterleinchen For This Useful Post: | ||
|
|
07-14-2012
, 09:26 AM
|
|
Posts: 216 |
Thanked: 121 times |
Joined on May 2010
@ Bilbao (Basque Country [Spain])
|
#95
|
What do you think of my version of scripts on the wiki page?
Do they work for everyone?
| The Following User Says Thank You to malkavian For This Useful Post: | ||
|
|
07-14-2012
, 09:36 AM
|
|
Posts: 216 |
Thanked: 121 times |
Joined on May 2010
@ Bilbao (Basque Country [Spain])
|
#96
|
| The Following User Says Thank You to malkavian For This Useful Post: | ||
|
|
07-14-2012
, 11:10 AM
|
|
Posts: 1,378 |
Thanked: 1,911 times |
Joined on Apr 2010
@ St. Helens, England
|
#97
|
Well, scripts look nice, but maybe "sudo" won't work for everybody. Mines must be used as root.
run-standalone.sh /home/user/.myscript/swapswitch.sh | sudo gainroot
| The Following User Says Thank You to sixwheeledbeast For This Useful Post: | ||
|
|
07-15-2012
, 04:20 AM
|
|
Posts: 308 |
Thanked: 343 times |
Joined on Dec 2010
|
#98
|
|
|
07-15-2012
, 04:28 PM
|
|
|
Posts: 947 |
Thanked: 1,106 times |
Joined on Aug 2010
@ Ruhrgebiet, Germany
|
#99
|
Ummm, and I am thinking that there isn't a command to modify swap priorities without disabling and re-enabling it.
I am certain I have seen some script that is
"if not root - sudo me"

#!/bin/sh
# executing a shell script given as parameter(s) as root
if [ `id -u` != 0 ] ; then
exec sudo gainroot <<EOF
exec sh $0 $*
EOF
exit $?
fi
# own shell code from here
| The Following 6 Users Say Thank You to peterleinchen For This Useful Post: | ||
|
|
07-16-2012
, 01:40 PM
|
|
Posts: 17 |
Thanked: 22 times |
Joined on Jul 2012
@ Bulgaria
|
#100
|
![]() |
| Thread Tools | Search this Thread |
|
And do it with lesser nice, like
'nice -20 switchswap.sh'