330

Understanding UnixLinux Programming

Embed Size (px)

DESCRIPTION

by Bruce Molay

Citation preview

  • 1 Unix1.1 1.2 1.2.11.2.21.2.31.2.41.31.3.1 1.3.2 1.3.31.4Unix1.4.1 Unix1.4.21.4.3 1.4.41.5Unix1.5.11.5.2 1.5.3 bc:Unix1.5.4bc/dcWeb1.61.71.7.11.7.2 Unix1.7.3 Unix2 who2.12.2who2.3 1who2.42who2.5 3who2.5.1 2.5.2 openreadclose2.5.3 who1.c2.5.4 2.5.5 who2.c2.5.6 2.6 cp2.6.1 1cp2.6.22cp2.6.33cp2.6.4 Unix2.7I/O2.7.12.7.22.7.3who2.c2.7.4who2.c2.82.92.9.12.9.22.9.32.9.42.103 Is3.13.21ls3.2.1 1s3.2.23.2.33.2.413.33.42ls3.4.13.4.2openreadclose3.4.33.53ls3.6ls-l3.6.1 1ls-l3.6.22ls-l3.6.3stat3.6.4 stat3.6.53.6.63.6.7ID3.6.8 ls2.c3.73.7.1 set-user-ID3.7.2 set-group-ID3.7.3 sticky3.7.4ls-13.8 ls3.93.9.13.9.23.9.33.9.43.9.53.9.6 3.9.7 4 pwd4.14.24.2.1 4.2.2 4.2.34.2.44.2.5 4.2.6 Unix4.3 Unix4.3.14.3.24.3.34.3.44.3.54.3.6cat4.3.7 i-4.3.8 Unix4.44.4.14.4.24.5pwd4.5.1 pwd4.5.2 pwd4.64.6.14.6.2i-4.6.35 stty5.15.25.2.15.2.25.2.35.2.45.2.5write5.2.6i-5.35.45.4.115.4.225.4.3open5.4.45.55.5.1I/O5.5.25.5.3 stty5.5.45.5.55.5.65.5.75.5.85.6ioctl5.7 6 6.16.26.2.16.2.26.2.36.3play_again.c6.46.4.1 Ctrl-C6.4.26.4.36.4.46.5play_again4.c6.66.7 7 7.17.2Pong7.3curses7.3.1curses7.3.2 curses7.4 sleep7.51Alarms7.5.1sleep7.5.2 sleep()UnixAlarms7.5.37.627.6.1usleep7.6.27.6.37.6.47.6.57.6.67.71signal7.7.17.7.27.7.37.7.47.82sigaction7.8.1sigaction7.8.27.9 Data Corruption7.9.17.9.2Critical Sections7.9.3sigprocmasksigsetops7.9.4Reentrant Code7.9.57.10 kill7.117.11.1 bou nceld.c7.11.2 bounce2d.c7.11.37.12I/O7.12.1I/O7.12.2 1O_ASYNC7.12.32aio_read7.12.47.12.58 sh8.18.2ps8.2.1 8.2.28.2.38.3 shell8.4 shell8.4.1 shell8.4.2 18.4.328.4.438.4.5shell8.5shell:psh2.c8.68.7 exitexec8.7.1exit_exit8.7.2 exec9 shellshellshell9.1 shell9.2shell9.3 smshl9.4 shell9.4.1 if9.4.2 if9.4.3smshif9.4.4 smsh2.c9.5 shell9.5.1shell9.5.29.5.3 Built-ins9.5.49.69.6.19.6.29.6.3smsh9.6.4 varlib.c9.7 shell10 I/O10.1 shell10.2shell10.3 I/O10.3.11310.3.2tty10.3.3stdout10.3.4I/Oshell10.3.5I/O10.3.62Lowest-Available-fd10.3.710.4stdin10.4.11close then open10.4.22open..close..dup..close10.4.3dup10.4.43open..dup2..close10.4.5 shellstdin10.5I/O:whouserlist10.610.6.110.6.2fork10.6.3pipeforkexec10.6.411 Socket 11.1 11.2 11.3 bc:Unix11.3.1 bc:pipeforkdupexec11.3.211.3.3 fdopen 11.4 popen11.4.1 popen11.4.2popenfdopen11.4.3API 11.5 socket11.5.111.5.2 DAP11.5.311.5.4timeserv.c11.5.5timeserv.c11.5.6timeclnt.c11.5.7timeclnt.c11.5.8ls 11.6 12 Web12.112.212.31212.3.11socket12.3.2212.3.3 socklib.c12.4312.4.1socklib.ctimeserv/timeclnt12.4.22fork12.4.3DIY 12.5Web12.5.1 Web12.5.2Web12.5.3 Web12.5.4Web12.5.5Web12.5.6 Webserv12.5.7Web13 Datagram13.113.213.313.3.113.3.2 13.413.4.113.4.213.4.3 13.5socket13.5.113.5.213.5.3 sendtorecvfrom13.5.413.5.513.61.013.6.1113.6.2113.6.3113.6.413.713.7.113.7.213.7.3213.813.9 Unix socket13.9.1socket13.9.2Unixsocket 13.10socket 14 14.1 14.214.2.114.2.214.2.314.314.3.1 1incrprint.c14.3.2 2twordcount.c14.3.3 14.4 14.514.5.114.5.214.5.314.5.4 Web14.6Web14.6.1 Web14.6.214.6.3 Zombie Threads14.6.4 Web 14.714.7.114.7.2bounceld.c14.7.3tanimate.c14.7.4 tanimate.c14.7.515 IPC15.115.2 talk15.2.1 15.2.2 select15.2.3 selecttalk15.2.4 selectpoll 15.315.3.115.3.215.3.315.3.415.3.515.415.4.115.4.2Semaphores15.4.3 socketFIFO 15.515.5.115.5.215.6IPC15.7