基于 Linux 网络聊天室的设计摘要本课程设计实现了在 linux 下简单的网络聊天室。在 Linux 下编写并调试服务器端程序和客户端程序,实现了客户、服务器之间的连接和通信。可以在单机上开辟两个窗口分别运行客户、服务器端的程序,或者将两台主机连接分别作为客户和服务器的方式。本设计使用网络套接字 socket 和多线程在网络中的应用, 并基于 linux 下的 vi 编辑器。本方案经 gcc 调试器调试成功, 可以在单机网络聊天中使用。关键词网络聊天室; linux ; socket ; vi Abstract Design and Implementation of the course in under linux work chat rooms. Prepared in the Linux and debugging server-side processes and client to achieve the client, server munications link between. Can open up two windows on the stand-alone operation, respectively, customers, server-side procedures, or to connect two hosts, respectively, as the way the client and server. The design of work socket using the socket and multi-threaded applications in work, and under linux based vi editor. The program by the ess of gcc debug debugger, you can chat in the use of stand-work. Key work Chat R ooms; Linux; S ocket; Vi 基于 Linux 网络聊天室的设计........................................................................ 1 1 背景.................................................................................................................. 3 linux 介绍................................................................................................. 3 2 技术说明........................................................................................................ 6 TCP 和 UDP 通信的概念...................................................................... 6 UDP 通信.................................................................................................. 6 TCP 通信................................................................................................... 6 客户/ 服务器模型......................................................................................... 7 网络套接字( socket )的概念.................................................................... 8 多线程的概念.............................................................................................. 8 3 系统实现.......................................................
基于Linux网络聊天室的设计3 来自淘豆网m.daumloan.com转载请标明出处.