A machine too small for the models it would serve is said so first
A control plane that is also a node, serving the starter model and two judges, needs about 10.5 GB: 3.5 for itself, 2 for the starter, 2 for each judge, and one more because the scheduler counts whole gigabytes. On 8 GB the install did every step and then had nowhere to run the starter. The setup's checks now fail this machine's memory and name what it would serve, and server init refuses before it installs anything, naming the flags that leave those models off it. quick-install.md said 8 GB; it says 12. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
06baa38858
commit
d110968243
10 files changed
+131
-5
No files matched your search
@@ -53,6 +53,11 @@ type Machine struct {
|
||||
Remote onboard.Remote
|
||||
// Local is this machine, where sudo is not needed (setup runs as root).
|
||||
Local bool
|
||||
// ServesMB is memory it needs beyond its roles' for the models it will
|
||||
// serve itself, and Serves names them. Short of it is a failure, not a
|
||||
// warning: the install would finish and then have nowhere to run them.
|
||||
ServesMB int
|
||||
Serves string
|
||||
}
|
||||
|
||||
// Level is how bad a finding is.
|
||||
@@ -269,7 +274,17 @@ func Evaluate(m Machine, facts map[string]string, at time.Time) []Finding {
|
||||
}
|
||||
}
|
||||
room("cpus", cpus, need.CPUs, "CPUs")
|
||||
room("memory", mem, need.MemoryMB, "MB")
|
||||
if m.ServesMB > 0 {
|
||||
want := need.MemoryMB + m.ServesMB
|
||||
d := fmt.Sprintf("%d MB (needs %d with %s)", mem, want, m.Serves)
|
||||
if mem >= want {
|
||||
f("memory", OK, d, "")
|
||||
} else {
|
||||
f("memory", Fail, d, "give it more memory, or turn off "+m.Serves+" or This machine as a node")
|
||||
}
|
||||
} else {
|
||||
room("memory", mem, need.MemoryMB, "MB")
|
||||
}
|
||||
room("disk", disk, need.DiskGB, "GB free")
|
||||
|
||||
// Time. Leases and etcd's elections go wrong on clocks that disagree.
|
||||
|
||||
@@ -107,3 +107,16 @@ func TestAgainstRealMachines(t *testing.T) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// The guide's first recording: 8 GB, a control plane serving the starter and
|
||||
// both judges, every step done and then no room for the starter. Now said at
|
||||
// the checks, as a failure, before anything is installed.
|
||||
func TestAMachineTooSmallForTheModelsItServesFailsTheCheck(t *testing.T) {
|
||||
m := Machine{Name: "llm-1", Roles: []Role{RoleControl, RoleWitness}, ServesMB: 7 * 1024, Serves: "the starter model and 2 judges"}
|
||||
if l, d := levelOf(Evaluate(m, facts(map[string]string{"mem_mb": "7941"}), time.Now()), "memory"); l != Fail || !strings.Contains(d, "2 judges") {
|
||||
t.Errorf("8 GB: %v %q", l, d)
|
||||
}
|
||||
if l, d := levelOf(Evaluate(m, facts(map[string]string{"mem_mb": "11961"}), time.Now()), "memory"); l != OK {
|
||||
t.Errorf("12 GB: %v %q", l, d)
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user