AIX笔记1

本文详细介绍了AIX操作系统的组成部分,如内核、用户界面、文件系统等,并讲解了如何使用系统、文件和目录的基本操作。
Unit 1.  Introduction to AIX

The AIX Kernel
A computer consists of many hardware devices that the users of a computer system want to use. For example, they want to print documents or they want to play a game from a CD-ROM. To control these hardware devices and to share them between multiple users, an operating system must be loaded during the system startup. In the case of the AIX operating system, there is one special program which interfaces directly to the hardware devices: the AIX Kernel. The Kernel controls the access to the devices. On the other hand, the users start different programs, for example, a program that prints a document or removes a file. These programs that run in AIX processes are also controlled by the AIX Kernel.
To say it simply: The AIX Kernel is the heart of your operating system.

Log in
AIX is a multi-user system. Before a user can work with AIX, an authentication process takes place. The user must log in with the user’s username and password.

The shell
After a successful authentication, AIX starts a certain program for the user, a shell. The shell is a command interpreter that waits for input and executes the commands and programs the user types in. As you will learn in this course, the shell is not only a command interpreter; it offers great flexibility. Working with the shell is one of the major topics in this course.

Communication
Multiple users can work at the same time on an AIX system or in a network. One of the basic tasks in your daily work is to communicate with other users on a system or in the network. In this course, you will learn different commands that allow communication with other users.

Additional information
AIX offers a wide range of tools and commands. There are multiple ways to obtain assistance with commands; for example, the man command or the AIX Online
Documentation. How to work with these help tools is also a major topic in this course.

AIX file structure
One of the major tasks of a computer system is to read and write data. In order to do this, AIX uses a hierarchical(等级制度的) file tree that consists of directories, subdirectories, and files. The top level directory is called the root (/) directory that has many subdirectories. Each of these subdirectories can contain files or other subdirectories. A directory is like a folder in which you put certain documents.

File system types
The file tree is mounted during the system startup. AIX supports different file system types, which are all mounted to one big file tree. This is shown on the visual. Parts of this file tree reside on a disk, other parts may reside on a CD-ROM, or are mounted from another computer in a network.

What you will learn
This course explains how to work with directories and files on a user level. You will learn how to navigate in the file tree and how to manage directories. You will learn how to copy, move, delete and print files, and how to edit files using vi, which is the common UNIX editor. Another topic will show how to specify correct file permissions.

Operating system components:
Kernel: Interface to hardware
Shell: User's interface
File Sysytem: Access to data

The shell
The shell waits for input and executes the commands and programs you type in. In other words the shell is a command interpreter.
The shell offers many features (like wildcards to match file names, variables, command line editing) that help the user in his daily work. We will discuss all these features in this course.
The shell offers different ways to control processes. In this course, we explain how a user can control his processes.

Customization
The shell is customizable. That means the user interface may be tailored(定做的) according to the requirements of each user. Customizing the user environment is another topic in this course.
Besides all these properties, the shell is a programming language. You can write shell scripts to create and tailor commands. Writing simple shell scripts will be covered later in this course.

AIX utilities
Two components that you use on AIX are files and directories. To work with these components, AIX offers a wide range of utilities:
  - The find command to search for specific files
  - The grep command to search for patterns in files
  - Commands to compare files and directories
  - Commands to compress and uncompress files to save disk space
Note that this list is not complete. Besides these utilities, the course introduces additional tools that are useful for your work.

Graphical user interfaces
Modern operating systems are based on graphical desktops. These desktops consist of multiple windows where you can start different applications, icons that are minimized windows to manage the screen space, and further controls.
To execute certain actions on the desktop, you have to use the mouse attached to the system.
AIX offers two different graphical user interfaces:
  - AIXwindows
  - Common Desktop Environment (CDE)
Information on using and customizing these desktops is included in the appendix of this course.

Additional user interfaces
In AIX 5L, if you add the AIX Toolbox for Linux Applications, you can install two other graphical user interfaces:
  - KDE
  - GNOME

Unit Summary:
The AIX Kernel interfaces to hardware devices and controls processes running in the AIX system.
The user's interface to AIX is the shell. The shell is a command interpreter that offers great flexibility.
To store data AIX uses a hierarchical file tree that consists of directories and files.
AIX offers a wide range of useful utilities.

-----------------------------------------------------------------------
Unit 2.  Using the System

Introduction
Because AIX is designed as a multi-user system, a level of security is implemented to control access. Each user of the system has a user name and associated password (optional).

User name
When the system has started and is ready for a user to log in, the login prompt (typically the word login:) is presented on the screen. At that point, the user should enter the supplied user name.

User password
If the user name requires a password, the system will prompt for the password in a similar manner. While the user is typing a password, it does not appear on the screen. It is highly recommended to use passwords on all user accounts.
If the user password was set up by the system administrator, the first time that the user logs in to the system, the user will be prompted to change their password.

Successful login
When logged in, the user is presented with a prompt (normally a dollar sign) which is the shell's way of requesting a command.

Exiting the system
To terminate the session the user may either enter the exit or logout command, or press the key combination <Ctrl+d> (holding down the Ctrl key while pressing the d key). The <Ctrl+d> combination generates the “end of file” (EOF) or “end of transmission” (EOT) character.
logout only works if you are in your login shell.
When the user logs out, after a few seconds a new login prompt will appear on the screen.

Changing the user password
The user password is the primary mechanism for ensuring security on an AIX system.
All passwords are encrypted and cannot be decoded by other users.
The passwd command is used to change the user password and is an example of a simple command which may be entered at the shell prompt.
The system will start the passwd process which will prompt the user for their old password first. The characters typed are not displayed to the screen. To prevent users being locked out of the system through a simple typing error, the new password is entered twice. Only if the two entries match is the new password accepted. The old password is invalid thereafter.
When the passwd process terminates, the user is again presented with the prompt requesting another command.

command option(s) argument(s)

Formatting a command
The order and separation of the elements of a command are important. The command or process name must come first. Spaces are used by the shell as separators on the command line and should not be placed within the command name.

Command options
The options should follow the command name, separated by a space, and preceded by a minus sign (-). Usually, multiple options may be grouped together immediately after a single minus sign or separated by spaces and each preceded by a minus sign. Options are typically used to modify the operation of the process.

Command arguments
The arguments follow the options, again separated by spaces. The order of the arguments will depend on the command.
Example
All three elements are not required to be present at all times, for example:
$ ls just command
$ ls -l command and option
$ ls /tmp command and argument

Introduction
The commands in the visual display some examples of correct and incorrect command formats.
Exceptions
A few commands in AIX do not adhere to the common command format. Commands such as tar, date, and ps accept arguments that do not begin with a minus sign (-). This is to ensure backwards compatibility with older implementations of UNIX.
$ tar cvf /dev/rmt0 /home/team01/*
$ ps aux
$ date +%D

Introduction
The visual shows how the date and cal commands can be executed.

More commands
This visual shows how the clear, echo, and banner commands work.
Note: Instead of echo you can use the print command:
$ print Lunch is at 12:00
Lunch is at 12:00

who command
The who command identified who is logged in and where they have logged in from.
Sometimes it is desirable to know what terminal you are working with, which can easily be identified with the who am i command. This will produce output similar to the who command but only from your own login session.
Earlier in the unit, options were introduced with the who command. Here are some more details on their functions:
-u  displays the user name, extended workstation name, login time, line activity and process ID of the current user.
-m  displays information about the current terminal and this is equivalent to the who am i command.

finger command
The finger command has a default format which displays: Full user name, login time, user's $HOME directory and user's login shell.
You can use your own username with the finger command to find out information about yourself.

Introduction
The mail command is an interactive command used to send and receive mail messages.

Sending a message
To send a message, invoke the command by passing it valid user IDs. If more than one name is given, the names must be separated from each other with a blank space.
Next the prompt Subject: will automatically be displayed. The sender should fill in this field with one line of text which closely describes the contents of the mail body. This is the line which will appear in the recipient's list of incoming mail.
After the subject line, the note body should then be entered, and once complete, press a <Ctrl-d> on the next available blank line.
Note: This must be the first and only character on that line. This is the end of file marker.
The Cc: prompt (denoting carbon copy) will then be displayed, which can be left blank, or a string of user IDs can be entered.
After the last prompt, the shell prompt should be displayed.

Sending mail to other systems
When sending mail to another user on your same system, enter mail <username>. To send mail to a user on another computer system, it is necessary to indicate the name (the host name) of that computer. For example, mail <username>@<hostname>

Introduction
The user is informed that new mail items have arrived when the [YOU HAVE NEW MAIL] message is displayed. This message does not get automatically displayed as soon as the incoming mail arrives. The shell does a check on all the mailboxes by default once every 600 seconds. If it detects a new piece of mail, then it displays the message (which itself can be customized by the system administrator).

Receiving mail
To receive the mail items use the mail command without any options. It will list header information and a one line description for each unread item followed by the prompt ?. This is different from the shell prompt. AIX uses the ? as the mail subsystem prompt.

Controlling the mail subsystem
At this prompt, the user may enter any of the mail subsystem commands. To obtain a list enter a ? at the prompt. Normal operations like saving, deleting, viewing, and so forth, can be carried out on each mail item.
Some of the commands that can be used at the ? prompt are:
d delete messages
m forward messages
R send reply to sender of messages in the queue
q exit mail and leave messages in the queue
s append messages to a file
t display a message
x exit mail and discard all changes to the queue
Certain subcommands like “d” and “t” accept message numbers as arguments. They default to the current message if none is specified.
There are many more. To obtain a the list of commands available type in a ? at the ? prompt or see the AIX 6.1 Commands Reference Manual.

Leaving the mail subsystem
Having finished working with the mail items, to return to the shell prompt, you must enter a q (for quit) at the ? prompt. This will take you out of the mail subsystem.
If you wish to quit the mail subsystem and discard any changes to the queue, enter an X (for exit) at the prompt. Messages that were marked for deletion are not deleted.
Any saved mail items which have been read but not deleted cannot be viewed again using the above method. Once the mail item is read, it will be stored in a file in the user's home directory called $HOME/mbox.
To view these items you must use the mail -f command. This will look at your default mailbox. If you have created other mailboxes, then you have to also specify the mailbox name.

write and wall commands
The write command can be used to send messages to users on this system as well as users of other systems connected to the network.
Both write and wall will only send messages to users that are logged in. By default, all users have the ability to execute the wall command.
write sends messages to a single user. wall sends messages all users currently logged in to the system.

Receiving messages
For a user to receive a message, that user must be logged in and must not have refused permission.

Write example
To hold a conversation using write enter:
$ write sam
Press <enter> and type:
I will need to re-boot the system at noon.<enter>
o <enter>
This starts the conversation. The o at the beginning of the next line means the message is over and you are waiting for a response. Now, Sam enters:
$ write bill
Thank you for letting me know! <enter>
oo <enter>
The oo means “over and out” telling the sender you have nothing more to say. Press <Ctrl+d> to end the write session.
Sending messages to users on other systemswrite can also be used across a network as long as the writesrv daemon is running.
To use write over the network type write <username>@<hostname>.

Two-way communication
The talk command allows two users to hold a conversation. One user invites the other to hold a conversation by issuing the talk command. The talk command opens a send window and a receive window on each user's display. Each user is then able to type into the send window while the talk command displays what the other user is typing.
If the invitation is accepted, each user's screen is split horizontally into two windows. In the top window everything the other user types is displayed.
To close the connection, press the INTERRUPT key <Ctrl+c>.
talk can also be used in a network. To talk to fred on sys1, the command would be talk fred@sys1.

The wall command writes to all terminals. This is useful to notify all users of a system event.

Permitting messages
The shell startup process permits messages by default. The visual shows how the mesg command work can be used to allow or deny messages.
The mesg command determines whether messages can be sent to the user with either the talk, the write, or the wall commands.
Permitting or denying messages can also be set as part of your session customization which we will cover later in this course.

<Backspace> Corrects mistakes
<Ctrl-c> Terminates the current command and returns to the shell
<Ctrl-d> End of transmission or end of file
<Ctrl-s> Temporarily stops output to the screen
<Ctrl-q> Resumes output (stopped by Ctrl-s)
<Ctrl-u> Erases the entire line Keyboard Tips

Keyboard tips
Do not use the cursor keys to correct mistakes, such as the up or down arrow key or the tab keys. The best way to correct mistakes is to use the Backspace key.
The <Ctrl-s> and <Ctrl-q> keys are somewhat system-dependent. On some ASCII terminals, the Hold key can be used as a toggle key to start and stop output to your terminal.

AIX commands can use multiple options and arguments and must follow proper syntax rules.
There are many simple, yet powerful commands such as:date cal who, who am I finger echo clear banner
Communicate with other UNIX users using commands such as: mail, write, talk, and wall.
-----------------------------------------------------------------------
Unit 3.  AIX 6.1 Documentation

man command features
The man command will look in the online manual for information on the commands, subroutines, and files with the name title. This information will be presented on the screen one page at a time for the user to browse.
The information consists of:
Purpose  The title and a one line description of the command
Syntax  A list of all valid options and arguments
Description  Many pages of information about the function and usage of the command with examples
Flags Description of available options
Examples Samples of how to use the command
Files  Any system files associated with the command
Related Info.  The names of any related commands

Enabling the -k feature
To use the -k flag, a superuser must have typed catman -w to create the /usr/share/man/whatis file.

man -k command
The man -k command shows the manual sections that contain any of the given keywords in their purpose section. The output from the command begins with the name of a command and the section number in which the command appears.
If you want to view the output from the command enable(1), then you can enter $ man enable to obtain the manual pages for the enable command. If the section number is omitted, the man command searches all the sections of the manual.
To obtain further information about the various man sections enter man man. Note that the apropos command is equivalent to man -k.

Documentation server
In addition to providing man commands to make finding information easy, AIX also provides system manuals. The documents are available on the Internet at the IBM Web site http://publib.boulder.ibm.com/infocenter/pseries/v6r1/index.jsp. For sites without access to the Internet, softcopy documentation can be loaded on a documentation server within a private network. Any other computer in the network with Web browser software can then become a documentation client and access these documents from the server.

Requests for documents
When users on a client computer request an AIX document, the request is sent to the Web server on a documentation server which then sends back the requested item.
When searches are performed, they are done on the server computer and the results are then sent back to the user on the client computer.

The man command can be used from the command line to view descriptions of AIX commands.
Use a Web browser to access online documentation with AIX 6.1.
The online documentation and System p InfoCenter use the same interface.

-----------------------------------------------------------------------
Unit 4.  Files and Directories

A file is:
–A collection of data
–A stream of characters or a "byte stream"
– No structure is imposed on a file by the operating system

Various file types
Most ordinary files are comprised of alphanumeric characters and punctuation coded in ASCII and can be viewed, edited, and printed using common tools.
Some ordinary files have data coded in a format that is unique to an application and special tools are needed. For example, the file /etc/utmp, which contains a list of currently logged in users, can only be read by the who command.
Other files contain code that can be executed by users on the computer. These files are known as binary files. These programs are treated by AIX as ordinary files.
Directories contain a list of files within that directory, and the information the system needs to access the file data. Each directory entry represents either a file or another directory, known as a subdirectory.
Special files behave differently from ordinary files in that the data written to the file is processed by a device driver and typically sent to that device, such as a printer, rather than being stored in the file.

Directory contents
Each directory entry contains a file or subdirectory name and its associated index node (or i-node) number.

User access to files
When a user executes a command to access a file, they will use the file name. The system then matches the file name with the corresponding i-node number. Once the i-node number is known, the system will access an i-node table, which holds information about the characteristics of the file.

i-node information
Examples of what is stored in the i-node table include the user ID of the owner of the file, the type of file, the date the file was last accessed and last modified, the size of the file, and the location of the file. Once the system knows the location of the file, the actual data can be located.

Physical file systems
The term file system refers to both the physical storage of the file data, and the logical organization of directories to allow quick and easy storage and retrieval of that data.
A physical file system is an allocation of storage, on a device such as a hard disk or a CD-ROM drive. The concept is very similar to partitions on some operating systems.
Space is assigned on a device, and associated with an identifier that the user can access. In AIX, this identifier is a directory in the system-wide logical filesystem structure.
If a physical file system fills up, then no more files can be created within the system.

AIX file system
This file structure represents only part of a typical AIX file system. The file structure will always start at the / (root) directory. It contains many directories that are critical in the operations of the system.
Examples
Some of the typical directories that can be found in an AIX root directory are:
/sbin - Utilities for system startup
/dev - Special files that represent devices
/etc - System configuration files
The /usr directory contains programs, libraries, and data files for various AIX applications:
The /home directory contains user login directories and files.
The /var directory contains files that dynamically change.
The /tmp directory will hold files created by executing programs.
The /opt directory is where third-party application programs can be stored. An example of files in this directory are the basic Linux commands, such as tar, gzip, gunzip, bzip2, and so forth, which are installed in the /opt/freeware/bin directory.
The /proc directory is where AIX maps processes and kernel data structures to corresponding files.

Accessing directories on other systems
It is also possible to access files on another computer in the network. Several facilities are available to do this, most notably, the Network File System (NFS). From a user's perspective, remote files will appear to behave just like local files.

File path names
The path name is written as a string of names separated by forward slashes (/). The rightmost name is the file you wish to access. The other names are the directories and subdirectories that describe how to get to the file’s location.
A path name is always considered to be relative unless it begins with a slash. An absolute or full path name always starts with a slash.

源码直接下载地址: https://pan.quark.cn/s/a4b39357ea24 过采样与欠采样构成了数字信号处理领域中两种基础的采样策略,它们在工程实践应用时各自展现出独特的长处与短处及适用情境。以下将深入阐释这两种采样方法的运作机制,并对它们在实际操作中的区别进行细致对比。 我们首先阐释过采样的核心概念。过采样(Oversampling)一般是指运用高于必要标准频率对模拟信号实施采样。举例而言,当信号频率为70MHz且信号带宽为20MHz时,依据奈奎斯特采样准则,理论上采样频率只需略高于40MHz(即信号带宽频率的两倍)即可达成无失真采样。然而,在现实操作中,系统构造者常常会采用超过140MSPS(每秒百万次采样)的采样速率,这通常超出理论所需。过采样的主要不利之处涵盖:提升ADC输出数据速率,引发FPGA的时序挑战;增大功耗、ADC及FPGA的制造成本。尽管存在这些不足,过采样依然具备其有利之处,例如可提供处理增益、频率规划的伸缩性以及能够处理更宽的信号带宽。 接下来,我们探讨欠采样的基本原理。欠采样(Undersampling)是指以低于理论标准频率对信号进行采样,这在处理高输入信号频率时尤为有效。例如,针对70MHz的中频(IF)信号,通过欠采样能够采用低于40MHz的采样频率进行采样,从而将数据速率降至FPGA,减少时序挑战,节省能量消耗和成本。实现欠采样的关键设计考量在于它能够在系统设计中达成所需的ADC动态性能。 欠采样的优势体现为能够简化硬件构造,比如降低对高速数据捕获的需求,并且在设计条件允许时,可选用较慢的ADC来削减成本。然而,欠采样技术也存在其局限性,例如在ADC的非理想表现可能导致非线性失真,诸如二阶(HD2)和三阶(HD3)谐...
源码链接: https://pan.quark.cn/s/3523d8c4b5d2 ### Qt5.9.1开发的应用程序转换为可安装`.exe`文件的详细流程 #### 一、概述 本资料将系统性地阐述如何将基于Qt5.9.1版本或其他Qt框架版本开发的应用程序转化为可直接安装的`.exe`安装文件。这一过程不仅适用于Qt5.9.1版本,对其他版本的Qt框架开发的应用同样适用。 #### 二、前期准备 在开展相关操作前,需确保已达成以下准备要求: 1. **开发环境配置**: 利用Qt5.9.1或其他版本完成应用程序的开发工作,并保证能够顺利编译出可执行程序。 2. **NSIS安装**: NSIS(Nullsoft Scriptable Install System)作为一个开源的Windows安装系统,能够支持创建专业的安装程序。用户可从官方渠道或可靠来源获取最新版的NSIS并进行安装。 #### 三、制作可执行程序的流程 ##### 3.1 打包应用程序文件 需要将已开发好的Qt应用程序的所有组件和资源整合到一个文件夹中,例如命名为`Qt_Video`。确保该文件夹内包含所有必要的库文件和资源文件,以便应用程序能够独立运行。 ##### 3.2 压缩文件随后,将整个`Qt_Video`文件夹压缩成`.zip`格式的文件。这一步骤可通过Windows内置的压缩工具或第三方软件完成。 ##### 3.3 创建安装文件接下来,借助NSIS将压缩文件转化为安装文件。具体操作如下: 1. **启动NSIS**: 运行NSIS软件并进入其主界面。 2. **选择基于ZIP的安装模式**: 在主界面中选取“**Installer based on ZIP file**...
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值