1. Configuration
Apue. H is a file written by the author. It contains common header files and is not provided by the system. This includes common header files and definitions of error handling functions. It is really convenient to use.
To use it, perform the following operations to complete the configuration.
Download the compressed src.tar.gzsource code package at http://www.apuebook.com.
1. decompress the package to the/home/user/directory.
2. Modify wkdir =/home/XXX/apue.2e in make. Define
1, in the linux bash Beijing time and Unix time stamp mutual transfer: Get UNIX Timestamp:
Command: Date "+%s"
Output: 1372654714
Get Beijing Time:
Command: Date ' +%y-%m-%d%h:%m:%s '
Output: 2013-07-01 12:55:56
Unix timestamp transfer to Beijing time:
Command: Date [email protected] ' +%y-%m-%d%h:%m:%s '
Output: 2013-07-01 12:58:34
Introduction to advanced programming in Unix environment: Basic Unix knowledge (III)
Some shame ~, I haven't updated it for a year and a half. I came to a new organization and made an embedded system as I expected. I thought it was okay;This time, I continue with the advanced programming series for the unix environment, hoping to stick to it :)1. programs and pro
UNIX advanced environment programming (13) signal, unix programming 13 Signal
The signal is Soft Interrupt.
Signals provide an asynchronous way to process events. For example, you can press the End Process key on the terminal to terminate a process in advance.
1. Concept of Signal
Each signal has a name whose names are headers with SIG. For example, every time a process calls the abort function, a SIGABRT s
I recently studied Unix programming art. The first chapter is very good. It tells us a lot about the history and philosophical basis of Unix. The most important part is the 17 design principles mentioned. I know many principles, but I have never summarized them in such detail.
Most of the content below comes from the book "Unix programming art", which is
[UNIX Network Programming] basic TCP socket programming and unix Network Programming
The concurrent server described in this chapter is a single customer Process Model Implemented by fork.
The following is the socket function of the basic TCP client/server program (the schedule of some typical events ):
TCP status transition diagram:
1. socket functions:
# Include
Family: protocol family (AF_INET, AF_
Several lines of code to call functions in the unix pipeline style, and several lines of unixAfter using linux, you basically know its pipeline, which is to use the output of a program or command as the input of another program or command.
To put it bluntly, let's look at how python can be used to call functions in the unix pipeline style.
#coding=utf-8class Pipe: def __init__(self, func): self.f
This configuration instance pro-test success, mutual encouragement, there are questions to everyone message.Environment: VMware + unbuntu 14.04For UNIX network programming, programming the first UNIX program encountered problems, can not contain unp.h file, this feeling and apue.h almost, but here need to compile source code, for later convenience, now tidy up as follows:The main 2.1 is to generate LIBUNP.A
extension of single UNIX specification provides the Getrlimit (2) function, which can be used to return the maximum number of descriptors that a process can open at the same time.Options:If we want to write some portable applications first, and these programs are related to the supported options, then a portable method is required to determine whether a given option is supported.As with restrictions, SUS defines three processing methods:
Com
# CD/USR/SRC
# tar Xvzf apache_1.3.6.tar.gz (Generate apache_1.3.6 directory)
# tar Xvzf php-3.0.8.tar.gz (Generate php-3.0.8 directory)
# CD apache_1.3.6
#./configure--prefix=/usr/local/apache (Set the Apache installation directory to/usr/local/apache)
# CD php-3.0.8
#./configure--with-mysql=/usr/local/mysql \
--with-apache=. /apache_1.3.6 \
--enable-track-vars (configuration support MySQL, as Apache function module, tracking variable valid)
# make; Make install
In the Configure parameter above
It is no exaggeration to say that the Unix model is the prototype of the modern operating system! Whether it is the original UNIX major series such as Aix, Solaris, HP-UX, FreeBSD, NetBSD ,... or UNIX like Linux... or a variety of Microsoft Operating Systems Based on the Windows NT architecture, the basic idea is derived from
Label: What to do next in Windows Linux
It is no exaggeration to say that the Unix model is the prototype of the modern operating system! Whether it is the original UNIX major series such as Aix, Solaris, HP-UX, FreeBSD, NetBSD ,... or UNIX like Linux... or a variety of Microsoft Operating Systems Based on the Windows NT architecture, the basic idea is derived fr
Unix system introduction, unix Operating System
I. Basic Knowledge
2. solaris installationReference: http://wenku.baidu.com/link? Url = install the Solaris10 ZF6WHQdnzOGc1why-ke86hU6JQfgsvjHP2s7Vek1AAFeu1aY_QmKPlovF2e7F-L94I7pG4yMEOhN5s5mxYuMfhspo_5g9pcWMOHVzJi9USy under the http://wenku.baidu.com/link Virtual Machine? Url = installation _ Virtual Machine installation of the solaris10 System Image File
H
[UNIX] the generation of an executable file to the distribution (on) of processes in the memory/the generation of executable files, unix executable files
From the generation of an executable file to the distribution of processes in the memory (on)
Generation of executable files
To generate executable files for a source program, it must be implemented through the compiler. the compiler translates the high-le
trying to earn revenue by legal means. They claim that Linux has stolen UNIX source code. IBM is also involved in this lawsuit because IBM supports LinuxPublisher. In the end, SCO lost.
At present, there are three manufacturers in the Unix field advantage: HP (HP-UX), SUN(Solaris) and IBM (Aix ). Most Unix users do not really care much about BSD, System V
Unix experience center: http://www.unix-center.net/
Users can be registered for free. JDK 5.0 is installed on linux systems, including kernel CPU, freebsd, solaris, and other operating systems.
I registered a user at this morning, and then ran to the Dragon Kernel Machine Installed in Debian linux to write a java hello program. The dragon Kernel Machine is a little slow, but it's okay, barely usable.
It seems that it is interesting to see the fil
1.2 UNIX architecture:
Kernel: Controls hardware resources and providesProgramRunning environment.
System Call: the kernel interface.
The public function library is built on the system call. Applications can call the public function library or the system call.
1.3 Login
1./etc/passwd. Login Name: encryption password: Value user ID: Value group ID: Comment field: Home Directory: shell program.
1.4 files and directories
The stat and fstat f
are unusually complex. However, today's Unix applications are still dominated by character interfaces, which exactly reflects the simple characteristics of Unix. This is another feature of Unix-"mutual support of commands". through a pipeline or redirection, commands can be
what the UNIX process model can build. The early UNIX process was organized, and with the concept of Terminal, Unix gave the concept of process group and conversation.A process group is a collection of associated sets of processes, such as individual commands for pipe-break connections. What's more, the association be
Http://dev2dev.cnblogs.com/archive/2005/10/10/251894.aspxGetting Started with Unix OS and basicsUnlike the familiar Windows user interface and usage habits, UNIX is often used command run, very flexible operating system, the current products are mainly Ibm-aix, Sun-solaris, Hp-unix and so on. Initial exposure to UNIX o
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.