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