sched_stress.sh 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. #!/bin/sh
  2. #
  3. #
  4. # Copyright (c) International Business Machines Corp., 2001
  5. #
  6. # This program is free software; you can redistribute it and/or modify
  7. # it under the terms of the GNU General Public License as published by
  8. # the Free Software Foundation; either version 2 of the License, or
  9. # (at your option) any later version.
  10. #
  11. # This program is distributed in the hope that it will be useful,
  12. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
  14. # the GNU General Public License for more details.
  15. #
  16. # You should have received a copy of the GNU General Public License
  17. # along with this program; if not, write to the Free Software
  18. # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  19. #
  20. #
  21. #
  22. # FILE : sched_stress
  23. #
  24. # PURPOSE : Exports required environment variables and runs sched_driver
  25. #
  26. # The command below will only work on x86 setups, b/c other archs keep
  27. # their bootfiles other locations.
  28. export KERNEL=./sched_datafile
  29. touch $KERNEL
  30. echo 0.000000 > sch.measure
  31. export RAWDEV=`df / | grep dev | awk {'print $1'}`
  32. sched_driver -s 0.9 -t 0.02 -p 2 > /tmp/tmp$$
  33. tail -n 5 /tmp/tmp$$
  34. rm -rf /tmp/tmp$$ ./sched_datafile sch.measure