Содержащиеся вНайти другие документыРесурсы поддержки | Загрузить это руководство в формате PDF (79 КБ)
Chapter 2 ChorusOS 4.0 Operating System Design ChangesThis chapter lists the changes and new features in the design of the ChorusOS 4.0 operating system. 2.1 Multiple RAM DisksUp to 16 RAM disks are supported by the ChorusOS 4.0 operating system. This number does not include internal RAM disks used as memory banks. Configuration of multiple RAM disks is achieved by modifying the following tunables:
These tunables can be read by the target, but not modified, using the To return the value of
To return the size of RAM disk a, type:
See the sysctl(1M) man page for more information. After defining your RAM disks, you must associate them with a device.
This is achieved using the mknod
The device_name is the device name within /dev, device_type is either c for character, or b for block, major_number is the major device number, and minor_number is the minor device number. The minor_number determines what number is allocated to each RAM disk according to the following table: Table 2-1 RAM Disk Identification
See the mknod(1M) man page for more information. Here is an example of device definitions for RAM disk 0: # Devices for RAM disk #0 # must define both block and character modes # Character mode mknod /dev/rrd0a c 13 0 mknod /dev/rrd0b c 13 1 mknod /dev/rrd0c c 13 2 mknod /dev/rrd0d c 13 3 mknod /dev/rrd0e c 13 4 mknod /dev/rrd0f c 13 5 mknod /dev/rrd0g c 13 6 mknod /dev/rrd0h c 13 7 # Block mode mknod /dev/rd0a b 14 0 mknod /dev/rd0b b 14 1 mknod /dev/rd0c b 14 2 mknod /dev/rd0d b 14 3 mknod /dev/rd0e b 14 4 mknod /dev/rd0f b 14 5 mknod /dev/rd0g b 14 6 mknod /dev/rd0h b 14 7 Which partitions you define will depend on which entries you have defined in your /etc/disktab file. See the disktab(4CC) man page for more information. Here is an example /etc/disktab entry which defines
RAM disk rd1Meg:\
:ns#4:nt#4:nc#2048 \
:pa#1024:oa#0:ta=MSDOS: \
:pb#1024:ob#0:tb=MSDOS: \
:pc#2048:oc#0:tc=unused:
Your device definition file will look like this: Devices for RAM disk rd1Meg # must define both block and character modes # Character mode mknod /dev/rrd0a c 13 0 mknod /dev/rrd0b c 13 1 # Block mode mknod /dev/rd0a b 14 0 mknod /dev/rd0b b 14 1 Label the RAM disk using the disklabel command:
Format the partitions as follows:
Finally, to mount the partitions, do the following:
See ChorusOS 4.0 File System Administration Guide for more information on RAM disks. 2.2 Flash FeatureThe
The mkdosflashfs and dosfsck commands, which create and check a DOS File system respectively, have been removed. Use the newfs_dos and fsck_dos commands instead. See the newfs_dos(1M) and fsck_dos(1M) man pages for more information. For more information on the 2.3 Swap SystemIn ChorusOS 3.2, the swap system was implemented over NFS. In ChorusOS 4.0, the swap system is implemented as a UFS-based file system which requires a local IDE or SCSI disk. Mount the swap system with the following command:
Swap areas greater than 2 Gigabytes are supported in ChorusOS 4.0. See "How to Activate a Swap Partition" in ChorusOS 4.0 File System Administration Guide for information on preparing and activating a swap partition. 2.4 Target Initialization and AdministrationNew support for target initialization and administration is provided in the ChorusOS 4.0 operating system:
This is a more flexible and easy-to-configure approach than in ChorusOS 3.2,
where network and file system initialization was handled by the You can customize system initialization using a /etc/rc.chorus file. See the rc.chorus(4CC) man page for more information. To build a system image, you now need a sysadm.ini file in order to configure the network and any devices. See the sysadm.ini(4CC) man page for more information. 2.5 Compressed ExecutablesThe storage space of executable files may be reduced by compressing
them with the GNU zip utility gzip. When the
Dynamic libraries can also be compressed in the same way. See the GZ_FILE(5FEA), the afexec(2K), and the aload(2K) man pages for more information. 2.6 Running Executable Files From MemoryIt is now possible to run executable files directly from memory by specifying the path to the relocatable binary in the following form: ram:0xstart:0xlength: start is the starting address at which the binary is stored and length is the length of the binary. See the afexec(2K) man page for more information. 2.7 Hot RestartHot restart is now available on all platforms and is enabled with the 2.8 PPP and SLIP ArchitectureThe PPP architecture has been redesigned in the ChorusOS 4.0 operating system, making its use and operation much closer to that used in BSD UNIX. There is no longer a specific API to dynamically manage serial lines as there was in the ChorusOS 3.2 operating system. The The ChorusOS 4.0 PPP daemon is an improved version of the BSD daemon, which is able to handle multiple serial lines by assigning a separate thread to each one. All the usual PPP functions, including dial-up on demand, are supported through the pppd options. The PPP API is provided by the actor 2.9 POSIX Message QueuesThe mq_open() system call establishes the connection between an actor and a message queue with a message queue descriptor. In the ChorusOS 3.2 operating system, the identifier returned by mq_open() was from an identifier space specific to the POSIX message queue. In the ChorusOS 4.0 operating system, this identifier is a standard file descriptor, similar to the file descriptor returned by open(), as stated in the POSIX standard. See the mq_open(2POSIX) man page for more information. 2.10 BSD Compatible InterfacesThe 4.3 BSD compatible interfaces in the ChorusOS 3.2 operating system have been replaced by 4.4 BSD compatible interfaces in the ChorusOS 4.0 operating system. IOM is no longer compiled with the COMPAT_43 option. As a result of this change, the sockaddr structure has a new field, sa_len: struct sockaddr {
u_char sa_len; /* total length */
u_char sa_family; /* address family */
char sa_data[14]; /* actually longer; address value */
}
Any applications using the old form of sockaddr, without the sa_len field, must be updated to initialize the structure correctly. 2.11 RTTYThe raw serial line device feature, See the tcsetattr(3POSIX) and tcgetattr(3POSIX) man pages for more information. 2.12 POSIX_FILEIO
For information on POSIX compliant I/O system calls on top of the MSDOS File System, see the MSDOSFS(5FEA) man page. For information on POSIX compliant I/O system calls on top of the UNIX File System, see the UFS(5FEA) man page. For information on POSIX compliant I/O system calls on top of the Network File System implementation, see the NFS_CLIENT(5FEA) man page. |
||||||||||||||||||||||||||||||||||||||||||||