restart_server
Restart the Minecraft server to apply configuration changes or resolve issues by stopping and starting the server process.
Instructions
Restart the Minecraft server (stop then start). Useful after configuration changes.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/core/ServerManager.ts:231-238 (handler)The 'restart' method in ServerManager stops and then starts the server.
/** Restart the server */ async restart(): Promise<string> { const stopResult = await this.stop(); // Wait a moment for cleanup await new Promise((r) => setTimeout(r, 2000)); const startResult = await this.start(); return `Stop: ${stopResult}\nStart: ${startResult}`; } - src/tools/server-tools.ts:44-53 (registration)The 'restart_server' MCP tool is registered here, which calls the manager.restart() method.
// --- Restart Server --- server.tool( "restart_server", "Restart the Minecraft server (stop then start). Useful after configuration changes.", {}, async () => { const result = await manager.restart(); return { content: [{ type: "text", text: result }] }; } );