> For the complete documentation index, see [llms.txt](https://applezulab.netdpi.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://applezulab.netdpi.net/02-linux-xi-tong-cao-zuo/linux-console-over-rs232.md).

# 透過 RS-232 操作 Linux console

Debian sample

修改 : /etc/lilo.conf

增加 2 行 serial=0,9600n8 vga = normal #

image= ... append="console=ttyS0"

改好之後重新執行 lilo

修改 : /etc/inittab

\#Example how to put a getty on a serial line (for a terminal)

\#T0 for ttyS0

T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100 #T1:23:respawn:/sbin/getty -L ttyS1 9600 vt100

or

/usr/doc/faq/howto/NET-2-HOWTO.gz 有講得很清楚.

1. /etc/inittab 在 # Serial lines 這段開一個 s2:45:respawn:/sbin/agetty -mt60 38400 ttyS1
2. /etc/rc.d/rc.S 最下一列開 /bin/sh /etc/rc.d/rc.serial
3. 如果您的 PC 沒有 multi-port of serial 的話, rc.serial 可以不要管了, 不過可以再去 check 一下, 我都是把 # Do AUTOMATIC\_IRQ probing 這段的 #AUTO\_IRQ=auto\_irq 關掉. 去 # MANUAL CONFIGURATION 把 ${SETSERIAL} /dev/cua0 uart 16550 port 0x3F8 irq 4 ${SETSERIAL} /dev/cua1 uart 16550 port 0x2F8 irq 3 打開
4. /etc/default 加一個 agetty.ttyS1


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://applezulab.netdpi.net/02-linux-xi-tong-cao-zuo/linux-console-over-rs232.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
