Use correct syntax markup for shell

Approved by:	carlavilla
This commit is contained in:
Li-Wen Hsu 2021-03-14 20:08:55 +08:00
parent 55c95407aa
commit a9a9e66105
No known key found for this signature in database
GPG key ID: 8D7BCC7D012FD37E
666 changed files with 17924 additions and 17924 deletions

View file

@ -341,7 +341,7 @@ By default, FreeBSD supports four serial ports which are commonly known as [.fil
To see if the system recognizes the serial ports, look for system boot messages that start with `uart`:
[source,bash]
[source,shell]
....
# grep uart /var/run/dmesg.boot
....
@ -350,21 +350,21 @@ If the system does not recognize all of the needed serial ports, additional entr
To determine the default set of terminal I/O settings used by the port, specify its device name. This example determines the settings for the call-in port on [.filename]#COM2#:
[source,bash]
[source,shell]
....
# stty -a -f /dev/ttyu1
....
System-wide initialization of serial devices is controlled by [.filename]#/etc/rc.d/serial#. This file affects the default settings of serial devices. To change the settings for a device, use `stty`. By default, the changed settings are in effect until the device is closed and when the device is reopened, it goes back to the default set. To permanently change the default set, open and adjust the settings of the initialization device. For example, to turn on `CLOCAL` mode, 8 bit communication, and `XON/XOFF` flow control for [.filename]#ttyu5#, type:
[source,bash]
[source,shell]
....
# stty -f /dev/ttyu5.init clocal cs8 ixon ixoff
....
To prevent certain settings from being changed by an application, make adjustments to the locking device. For example, to lock the speed of [.filename]#ttyu5# to 57600 bps, type:
[source,bash]
[source,shell]
....
# stty -f /dev/ttyu5.lock 57600
....
@ -400,7 +400,7 @@ There are at least two utilities in the base-system of FreeBSD that can be used
+
For example, to connect from a client system that runs FreeBSD to the serial connection of another system:
+
[source,bash]
[source,shell]
....
# cu -l /dev/cuauN
....
@ -459,7 +459,7 @@ The final field is used to specify whether the port is secure. Marking a port as
After making any changes to [.filename]#/etc/ttys#, send a SIGHUP (hangup) signal to the `init` process to force it to re-read its configuration file:
[source,bash]
[source,shell]
....
# kill -HUP 1
....
@ -481,7 +481,7 @@ Make sure the terminal and FreeBSD agree on the bps rate and parity settings. Fo
Use `ps` to make sure that a `getty` process is running and serving the terminal. For example, the following listing shows that a `getty` is running on the second serial port, [.filename]#ttyu1#, and is using the `std.38400` entry in [.filename]#/etc/gettytab#:
[source,bash]
[source,shell]
....
# ps -axww|grep ttyu
22189 d1 Is+ 0:00.03 /usr/libexec/getty std.38400 ttyu1
@ -589,14 +589,14 @@ ttyu0 "/usr/libexec/getty V19200" dialup on
After editing [.filename]#/etc/ttys#, wait until the modem is properly configured and connected before signaling `init`:
[source,bash]
[source,shell]
....
# kill -HUP 1
....
High-speed modems, like V.32, V.32bis, and V.34 modems, use hardware (`RTS/CTS`) flow control. Use `stty` to set the hardware flow control flag for the modem port. This example sets the `crtscts` flag on [.filename]#COM2#'s dial-in and dial-out initialization devices:
[source,bash]
[source,shell]
....
# stty -f /dev/ttyu1.init crtscts
# stty -f /dev/cuau1.init crtscts
@ -610,7 +610,7 @@ Hook up the modem to the FreeBSD system and boot the system. If the modem has st
If the DTR indicator does not light, login to the FreeBSD system through the console and type `ps ax` to see if FreeBSD is running a `getty` process on the correct port:
[source,bash]
[source,shell]
....
114 ?? I 0:00.10 /usr/libexec/getty V19200 ttyu0
....
@ -661,7 +661,7 @@ Use the highest bps rate the modem supports in the `br` capability. Then, type `
Or, use `cu` as `root` with the following command:
[source,bash]
[source,shell]
....
# cu -lline -sspeed
....
@ -693,7 +693,7 @@ tip57600|Dial any phone number at 57600 bps:\
This should now work:
[source,bash]
[source,shell]
....
# tip -115200 5551234
....
@ -708,7 +708,7 @@ cu115200|Use cu to dial any number at 115200bps:\
and type:
[source,bash]
[source,shell]
....
# cu 5551234 -s 115200
....
@ -824,7 +824,7 @@ This section provides a fast overview of setting up the serial console. This pro
. Connect the serial cable to [.filename]#COM1# and the controlling terminal.
. To configure boot messages to display on the serial console, issue the following command as the superuser:
+
[source,bash]
[source,shell]
....
# echo 'console="comconsole"' >> /boot/loader.conf
....
@ -892,7 +892,7 @@ The options, except for `-P`, are passed to the boot loader. The boot loader wil
+
When FreeBSD starts, the boot blocks echo the contents of [.filename]#/boot.config# to the console. For example:
+
[source,bash]
[source,shell]
....
/boot.config: -P
Keyboard: no
@ -929,7 +929,7 @@ After the message, there will be a small pause before the boot blocks continue l
+
Press any key, other than kbd:[Enter], at the console to interrupt the boot process. The boot blocks will then prompt for further action:
+
[source,bash]
[source,shell]
....
>> FreeBSD/i386 BOOT
Default: 0:ad(0,a)/boot/loader
@ -970,7 +970,7 @@ By default, the serial port settings are 9600 baud, 8 bits, no parity, and 1 sto
* Edit [.filename]#/etc/make.conf# and set `BOOT_COMCONSOLE_SPEED` to the new console speed. Then, recompile and install the boot blocks and the boot loader:
+
[source,bash]
[source,shell]
....
# cd /sys/boot
# make clean