HZ in linux/param.h
example:
vi ...linux/param.h
#ifndef _LINUX_PARAM_H
#define _LINUX_PARAM_H

#include 

#endif
vi /hda4/usr/include/asm/param.h #ifndef _ASMi386_PARAM_H #define _ASMi386_PARAM_H #ifndef HZ #define HZ 100 #endif

timer interrupt

kernel uses it to keep track of time intervals.

architecture dependent value defined in linux/param.h

1024 for alpha; 100 for all other platforms

timer interrupt increments "jiffies" value.

therefore "jiffies" is the number of clock ticks since GNUX was booted.

declared in linux/sched.h

fundamental time limit on uptime possible in GNUX

>> ulongs=2^32
ulongs =
   4.2950e+09
>> seconds=ulongs/100
seconds =
   4.2950e+07
>> hours=seconds/3600
hours =
   1.1930e+04
>> days=hours/24
days =
  497.1027
e.g. can't have more than 498 days uptime.

ordinarily with "toy" operating systems that crash several times a day, that's not a problem, but GNUX is actually so reliable that the above limit is a problem.

solution: buy a dec alpha:

>> ulongs=2^64
ulongs =
   1.8447e+19
>> seconds=ulongs/100
seconds =
   1.8447e+17
>> hours=seconds/3600
hours =
   5.1241e+13
>> days=hours/24
days =
   2.1350e+12
>> years=days/365.242
years =
   5.8455e+09
uptime: more than 5 billion years.

redefining HZ

reasonable values range from 19 to 10k.
(19 is the smallest value the hardware supports)

100 is probably the best value for most things.

reduce to extend uptime but computer sluggish;

10k gives less than 5 days uptime.

increasing doesn't necessarily make computer go faster (e.g. more time spent in servicing interrupts, etc.)

warning: if you change this value you must recompile and reinstall all modules.