Sie sind auf Seite 1von 31

PREFACE

As an integrated part of our B.Tech. syllabus in Computer Science Engineering I had to undergo the practical training of 45 days .I took my training at Hewlett Packard for 6 weeks. It is situated in Sector-6, Noida. I studied about Red Hat Enterprise Linux in network services, system and security administration. The report consists of various kinds of network servers, connecting to the Internet, and configures various types of servers such as Apache sever, Squid Server and so on. I also done project on WINDOWS & LINUX AUTHENTICATION & CENTRALIZATION LOGIN PROFILE using Samba Server. In this report I covered different type of networking services on Red Hat Enterprise Linux as Server side setup configuration, and basic administration of common networking services: NFS, APACHE, SMB, DHCP, TELNET and FTP.

CONTENT
Company Profile Student Certificate Introduction to Linux Salient Features of Linux Linux Kernel & Shell Linux Networking NFS Server Samba Server Squid Server Apache Server FTP Server DHCP Server Telnet Bibliography

COMPANY PROFILE

HP was founded in 1939. Corporate headquarters are in Palo Alto, California. Meg Whitman is CEO and President. HP is the world's largest IT Company, with revenue totaling $127.2 billion for fiscal 2011. HP's 2011 Fortune 500 ranking: No. 11. HP Education Services is the most reputed name in High End Technical Education. HP mentors, Guides and encourages you to strive for excellence. HP is the largest IT solutions company worldwide. Largest Unix training company worldwide. Has been in the education business for over 28 years. They have trained professionals the top most companies of the world.

They are Red Hat Professional Consulting and provide a vendor-neutral approach. The consulting approach is multi-platform, integrated, reliable network infrastructure solutions based on individual client needs. Red Hat Network is the internet-based system support and management service for Red Hat Linux networks. It provides a platform for Linux System

management that improves system reliability and security while saving time and increasing productivity of technical administrators. While Red Hat has the capability to provide a comprehensive outsourced support solutions, many customers may seek a blended approach to support and management of their open source solutions. For those who demand in-house expertise, Red Hat Global Learning Service provides the premier training curriculums and performance-based certification (RHCE) for open source platform and application development and administration. Red Hat develops, deploys, and manages solutions built on an open source Platform, including the Red Hat Linux Operating System for mainframes, Servers, workstations, and embedded services. The company offers a range of open source development tools, a suite to end-to-end professional services, including Consulting, engineering, enterprise support and global learning with growing popularity and acceptance of Linux in the govt. sector.

INTRODUCTION TO LINUX
LINUX is an open source / free software. With its advanced server configuration, Red Hat is putting Linux as an operating system at the core of enterprise computing. Today Linux is found in Web infrastructure, file server, ERP, and point of sale system, increasingly in the systems running critical applications at large companies. Analysts predict that by the end of this decade Linux will be a common element in the enterprise computing landscape. Over the last year, weve seen Linux go from being focused on small and medium business to being used very deep in the enterprise, says Paul Cormier, executive vice president of engineering at Red Hat, a leading Linux platform provider. Salient Features of LINUX Linux is the fastest operating system in the world. It runs much faster than Windows 9X/NT. It is about 1.2 to 3 times faster than Windows. In command-line console mode without X-window it runs even faster (console mode is ideal for Database servers, Apache Web servers, Email servers, News servers, File servers, DNS servers, Print servers, Network Computer servers, etc..). Linux is also the most powerful yet most simple and easy to use operating system in the world. Linux UNIXs is the like most IRIX, reliable Solaris, OS. Windows AIX, 9X/NT SCO fails all the fail

CRASH_OS_TEST Programs and only Linux passes. Also commercial HPUX, the crash test and Linux is the only OS which passes the crashme test. Very often Windows 95 users will get GPF errors and the system freezes. Linux is very robust because it is built by millions of people on internet and there are no errors in the kernel. It runs for one full year without any re-

boots or any problems non-stop, guaranteed. It is the best designed OS.

Linux has an excellent scalability - it runs on Uni-processor, Multiprocessors, Parallel Processors and even Super-computers. It fully supports SMP (Symmetric Multi-Processing) boxes with more than one CPU.

Linux is a very secure OS. Windows is not a secure OS, break-ins are easy. Windows 95/2000, NT, XP have computer viruses. But Linux does not have any viruses. Computer viruses cause lot of damages to Windows 95/2000/NT/XP but not to Linux.

Linux is very mature and is one of the oldest operating system in the world. UNIX (which is another name for Linux) was born in AT&T Bell Labs 27 years ago for Telecom research. Linux (UNIX) is the end-result of 27 years of research and development effort by U.S/European Universities and mega-corporations of Europe / America. It took 27 years to create vast amount of UNIX information, and all that info is now just sitting inside this Linux cdrom on our hand. For example programs like 'grep' had not changed for the past 27 years and they are still used in Linux. Functionality and command line options of grep had not changed for the past 27 years. Linux started the Linux during 1991, but he borrowed lot of concepts, code from UNIX and this means Linux is 27 years old. Today Linux is the OCEAN wherein all other unixes like Solaris, HPUX, and AIX merge into. And in near future all other unixes will be replaced by Linux.

Linux is less demanding on system resources. Linux runs on 386 PC with as little as 2 MB RAM in command-line console mode. Windows 9cannot because the graphic engine is included in the kernel, which makes Windows 95/NT a resource hog. Graphic engine makes the Windows extremely unreliable and unpredictable.

Linux has very low total_cost_of_ownership since Linux supports diskless nodes. Cost of maintaining Linux is five times lower than MS Windows.

Linux runs most windows applications (16bit) like MSOffice, MSWord using WABI ($40), WINE (free) and MSDOS applications using DOSemu, FreeDOS, and Dr.DOS. But Windows will run only few of UNIX and

Linux applications. Linux supports su (super user) command. Using su command it is possible to switch user without logging off. For example 'su - root' will login as user 'root'. In Windows you must log off completely to switch user. Linux kernel is very small and it can fit on a single floppy. It is less complex but very sophisticated and powerful. Small kernel means it is very reliable. Linux applications are much bigger running on top of the Linux Kernel. Linux has many powerful desktops like KDE desktop, GNOME, Triteal CDE, Motif mwm, Open look olwm, twm, fvwm95, xdm, xsm, Windows Afterstep, Window maker (NeXTstep-lookalike), Qvwm, amiwm (amiga), mlvwm (mac) etc. KDE desktop is much more user friendly than Windows95! You have more freedom and choice in Linux desktops as compared to Windows. Linux is 100% POSIX compliant OS, whereas Windows NT/9X are not. POSIX is IEEE (Institute of Electrical Engg) standard as well as ANSI and international ISO standard spec. U.S. govt generally require full compliance of POSIX on any operating system. Most of the Unix's like Solaris, HPUX, AIX, SCO are 100% POSIX. We can get the complete source code for Linux OS and all of its applications, whereas Windows is proprietary and we get only the binaries. Having the source code of Linux is vital for companies because they can quickly add advanced features and share it with every other company in the world. Linux is free of any cost. Linux is trouble free and we will not have any problems with Linux, whereas you will have more headaches with Windows(MS is not as reliable as Linux). The movie Titanic was created using Linux on Digital Alpha. Linux was used to create computer graphics, animations of all the shots in the movie Titanic. Linux was also used for storing data from experiments in the space shuttle. Linux was orbiting the earth in space.

Advantages of Linux:Virus proof Economical Multi-user Powerful networking Advanced OS Secured Multi-tasking Variety of servers Crash proof Fully supported Multi-desktop

Who are using Linux:Private sector Raymonds ICICI IDBI Bombay Dyeing Asian Paints Bharat petroleum Reliance Government sector Air-India Central Excise Govt. of MP Govt. of Goa Govt. of Kerala Govt. of A P etc. Railways

LINUX KERNEL & SHELL


KERNEL The core of the Linux system is the kernel-the operating system program. The kernel controls the resources of the computer, allotting them to different users and tasks. It interacts directly with the hardware, thus making the programs easy to write and portable across different platform of hardware. Since the kernel communicates directly with the hardware, the parts of the kernel must be customized to the hardware features of each system. However, the kernel does not deal directly with a user. Instead, the login process starts up a separate, interactive program, called the shell, for each user. SHELL Linux has a simple user interface called the shell that has the power to provide the services that a user wants. It protects the user from having to know the intricate hardware details. Feature of Shell: Command Execution Redirection Background processing History Aliases Variables File Name Expansion Command completion

Types of Shell in Linux: Bash- Bourne Again Shell Pdksh-Public Domain Korn Shell Tcsh- Toms C Shell Ash- A Shell Zsh- Z Shell

Linux Utilities and Application Program The Linux utilities or commands are a collection of programs that service day-to-day processing requirements. These programs are invoked through the shell, which is itself another utility

File system In all of the preceding configurations, automatic partitioning sets up multiple volumesseparate volumes on each directory. The advantage of separate partitions for certain directories is that it limits the risks to your system. For example, many Webmasters configure their Web sites to write daily log files with data relating to all users who visit their sites. These files can become quite large, especially for large online merchants. Before you decide how to set up partitions, you need to know about each of the major Linux directories. Linux directories are organized according to something known as the File system Hierarchy Standard (FHS). File system Hierarchy Standard The FHS is a standard for organizing directories for Linux- and Unix-based systems. Every FHS-compliant operating system starts with a top directory, root, symbolized by the forward slash. All other directories are subdirectories of root. Directory / Description The root directory. Other directories are below root in the FHS hierarchy. Unless mounted separately, the contents of other directories are in the root directory partition. /bin /boot /dev /home /lib /mnt /opt /proc /root /sbin /tmp /usr /var /etc Essential command line commands. Do not mount this directory on a separate volume, or else you may not be able to find these commands when you use a rescue disk. Linux startup programs. Normally includes the Linux kernel. Separate/boot partitions are common; the default size is currently 100MB. Linux device drivers. Do not mount this directory on a separate partition. /etc Basic configuration files. User home directories (accept the root user). Program libraries. Do not mount this directory on a separate partition. Mount point for removable media (floppy disks, CD drives). For applications, such as Star Office or VMWare. Running kernel processes. Home directory for the root user. Do not mount this directory separately. System administration commands. Do not mount this directory separately. Temporary file default directory. Small programs. Log files, print spools, and other variable-sized data. All configurations files.

LINUX NETWORKING

For networking firstly your hardware must be properly configured. Your network card should have been setup during the Linux installation or after the installation. Under Linux most drivers for network cards are implemented as modules, after the module is inserted, you may want to inspect the file /proc /modules to see if the module is loaded. The module configuration file is modules.conf in /etc. After setting up the network and connecting the cables, set up the network by running the command: - netconfig While setting up the network, doesnt mess up with the loop back driver which has the IP address 127.0.0.1. It is always there-it is the IP through which the computer talks to itself. IP address is allocated either statically or dynamically. For Linux Networking (communication through a network), the two basic Requirements are Media and Rules:By media we mean the communication link (cables), hubs and switches. It may be wired or wireless. Hubs are dumb, not an intelligent device. It works at the Physical layer whereas Switches are intelligent devices and works at Data link layer. To obtain good performance we make use of Switches. In a Switch, direct routing is possible, the data packet is unicasted and not broadcasted, the packet doesnt traverse to all the port but direct connection is made via IP address. Thus it has high performance; Switches maintain the IP address table for mapping process. By rules we mean the set of protocols used for communication. Rules or the Protocol to be used depends on the OS on the end systems, if both the endSystems have MS-Windows then for small network we use Netbui protocol & for larger networks use of TCP/IP is made. End systems having LINUX as OS Make use of TCP/IP protocol. Some Basic Networking Command Ping Measures connectivity and network latency between local & remote system. It uses ICMP echo packets. Example: ping 192.168.0.1 Or

ping www.redhat.com Traceroute Shows network path between local and remote systems. Useful for pinpointing network congestion. Example: traceroute www.redhat.com Netstat Example: netstat a ifup/ifdown For each installed network adapter, there is a Lists network statistics and parameters, including Network

Connection, Routing table, Interface statistics.

Corresponding ifcfg-* file in/etc/sysconfig/network- Scripts. You can activate or deactivate that adapter with the ifup and ifdown commands. Either one of the Following commands will activate the eth0 network Adapter: Example: ifup ifcfg-eth0 Ifup eth0

Ifconfig - The ifconfig command is used to configure and display network devices. Here is some sample output of an ifconfig command: #ifconfig eth0 Eth0 Link encap: Ethernet HWaddr 00:50:56:40:1E:6A Inet addr: 192.168.199.131 Bcast: 192.168.199.255 Mask: 255.255.255.0 UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU: 1500 Metric: 1 RX packets: 11253 errors: 0 dropped: 0 overruns: 0 frame: 0 TX packets: 1304 errors: 0 dropped: 0 overruns: 0 carrier: 0 Collisions: 0 txqueuelen: 100 RX bytes: 2092656 (1.9 Mb) TX bytes: 161329 (157.5 Kb) Interrupt: 10 Base addresses: 0x10a0

# ifconfig eth0 207.174.142.142 The first parameter, eth0, tells us which interface is being configured. The next Argument, 207.174.142.142, indicates the new IP address being assigned to this interface. If we want to make sure our change worked, we issue the ifconfig command again to view its current settings. # ifconfig eth0 Eth0 Link encap: Ethernet HWaddr 00:50:56:40:1E:6A Inet addr: 207.174.142.142 Bcast: 192.168.199.255 Mask: 255.255.255.0 UP BROADCAST NOTRAILERS RUNNING MULTICAST MTU: 1500 Metric: 1 RX packets: 11253 errors: 0 dropped: 0 overruns: 0 frame: 0 TX packets: 1304 errors: 0 dropped: 0 overruns: 0 carrier: 0 Collisions: 0 txqueuelen: 100 RX bytes: 2092656 (1.9 Mb) TX bytes: 161329 (157.5 Kb) Interrupt: 10 Base addresses: 0x10a0

NFS SERVER
The Network File System (NFS) was developed to allow machines to mount a disk partition on a remote machine as if it were a local disk. It allows for fast, seamless sharing of files across a network.

It also gives the potential for unwanted people to access your hard drive over the network (and thereby possibly read your email and delete all your files as well as break into you r system) if you set it up incorrectly. Packages: nfs Port Number: 2049 nfsd Configuration File: /etc/exports Service: rpcbind nfs Daemons: nfsd 1. Create a directory and make files or paste files you want to share from in network. (ex.-/dump) 2. Edit file for sharing [root@demo.com ~]# vi /etc/exports /dump *(rw) /share 192.168.1.15(ro) (save the file) In first line, we have share /dump for all users in a network with read & write permission & in second line, we have shared /share only for the PC having IP address 192.168.1.15 with read only permission 3. [root@demo.com ~]# service nfs restart 4. [root@demo.com ~]# service rpcbind restart 5. [root@demo.com ~]# showmount -e To check NFS Server and its shared directory from Server itself 6. [root@demo.com ~]# showmount -e <IP address of Server > To check NFS Server and its shared doc from client 7. CLIENT END: For taking NFS server service we have to mount directory from server to client [root@demo.com ~]# mount -t nfs <server IP>:/var/dump /mnt [root@demo.com ~]# cd /mnt here you will find all the shared files or

[root@demo.com ~]# cd /net [root@demo.com ~]# cd /IP of NFS Server 8. For installation from NFS, copy whole DVD/CD in a folder and share it. 9. Boot from CD & press Tab Key and write linux askmethod on client side, here it will ask to select the installation media, select NFS, now it will ask to give IP for your client computer, give IP, Now it will ask for Name of NFS Server: <Give IP of NFS Server>, and directory : <Give the path>. Now your system will install very quickly with the help of NFS server.

SAMBA SERVER
Samba is a suite of utilities that allows your Linux PC to share files and other resources, such as printers, with Windows PC. This part describe you how can you make your Linux PC into a Windows Primary Domain Controller (PDC) or a

server for a Windows Workgroup. Either configuration will allow everyone at home to have: Their own logins on all the home windows PC while having their files on the Linux PC appear to be located on a new Windows drive Shared access to printers on the Linux PC Shared files accessible only to members of their Linux user group.

What's the difference between a PDC and Windows Workgroup member? A PDC stores the login information in a central database on its hard drive. This allows each user to have a universal username and password when logging in from all PCs on the network. In a Windows Workgroup, each PC stores the usernames and passwords locally so that they are unique for each PC. This part will only cover the much more popular PDC methodology used at home. By default, Samba mimics a Windows PDC in almost every way needed for simple file sharing. Linux functionality doesn't disappear when you do this. Samba Domains and Linux share the same usernames so you can log into the Samba based Windows domain using your Linux password and immediately gain access to files in your Linux user's home directory. For added security you can make your Samba and Linux passwords different. When it starts up, and with every client request, the Samba daemon reads the configuration file /etc/samba/smb.conf to determine its various modes of operation. You can create your own smb.conf using a text editor or the Web-based SWAT utility which is easier. Keep in mind, however, that if you create /etc/samba/smb.conf with a text editor then subsequently use SWAT to edit the file, you will lose all the comments you inserted with the text editor.

First we will learn about the simple sharing between a Samba server and a windows PC

1. [root@demo.com ~]# yum install samba* [root@demo.com ~]# rpm -ivh samba* 2. Now, edit file

(Install samba package) or

[root@demo.com ~]# vi /etc/samba/smb.conf (at last of file, pressing G copy the following line and paste the lines and then remove ; infont of the line.) [My Share] comment= path= valid users= public= no writable=no printable=no save the file. 3. [root@demo.com ~]# service smb restart 4. To create Samba users [root@demo.com ~]# useradd <username> [root@demo.com ~]# smbpasswd -a <username> 5. To check samba is configured of not [root@hes.copm ~]# testparm 6. Samba users entry can be find in /etc/samba/smbpasswd 7. On client computers: on run: \\<IP address of samba server> Now it will ask for samba user give username and password. Now we make samba server as windows domain controller [root@demo.com ~]# vi /etc/samba/smb.conf (edit file) Global Setting Workgroup=FIRST #remove semicolon and give workgroup name Netbios name=FIRST # remove semicolon and give Netbios name # Domain controller options Domain logons =yes # remove semicolons Domain master=yes # remove semicolons #Browser Control options # remove semicolons Local master = no (Here give the permission you want to give) (Share name) (any comment) (here give the path which you want to share) (Here give samba users)

OS level = 35 #Share Definations Net logon Profiles [Profiles]

#increase from 33 i.e. default

Preffered master = yes # remove semicolons # remove semicolons # remove semicolons # remove semicolons and give the profile path # remove semicolons # remove semicolons

Path=/home/%u Browseable =yes Writable=yes Guest ok =yes and save file :wq Create samba user

[root@demo.com ~]# smbpasswd -a root [root@demo.com ~]# smbpasswd give samba passwd [root@demo.com ~]# service smb restart Now at client side, windows PC, MY Computer Properties Computer Name Change domain name FIRST. Give root samba password, restart the system and then login from the samba user.

SQUID SERVER

The utility squid is an internet proxy server that can be used within a network to distribute an internet connection to all the computers within the network. One central computer is connected to the internet through any means such as dial-up, cable modem, ISDN, DSL, or T1, runs squid, and thus acts as the firewall to the internet. Because it is a proxy, it has the capabilities to log all user actions such as the URLs visited. There are many features that can be configured in squid. Reasons to Create a Squid Proxy Two important goals of many small businesses are to: Reduce Internet bandwidth charges Limit access to the Web to only authorized users.

The Squid web caching proxy server can achieve these fairly easily. Users Configure their web browsers to use the Squid proxy server instead of going to the web directly. The Squid server then checks its web cache for the web information requested by the user. It will return any matching information that finds in its cache, and if not, it will go to the web to find it on behalf of the user. Once it finds the information, it will populate its cache with it and also forward it to the user's web browser. As you can see, this reduces the amount of data accessed from the web. Another advantage is that you can configure your firewall to only accept HTTP web traffic from the Squid server and no one else. Squid can then be configured to request usernames and passwords for each user that users its services. This provides simple access control to the Internet. Packages required: Squid Port Number: 3128 (default) Configuration File: /etc/squid/squid.conf Service/Daemon: squid For squid your system must have two lancard one for internet line & other for your private network.

1. [root@demo.com ~]# yum install squid* [root@demo.com ~]# rpm -ivh Squid* 2. Edit file [root@demo.com ~]# vi /etc/squid/squid.conf

or

(in this file set line no. & remove # and do following changes) Search for the line, if not found then write the same http_port 3128 work Cache_dir ufs /var/spool/squid 100 16 256 maintained Cache_log /var/log/Squid/cache.log or name Now for Access list Search for the line acl CONNECT method CONNECT, type under that line acl <any name> url_regex <Websites you want to block or initials, downloadings> acl xyz url_regex orkut mp3 downloading www.gmail.com http_access deny <above name> (xyz) acl xyz url_regex to access) http_access allow xyz http_access deny all (save the file) 3. [root@demo.com ~]# service squid restart/reload 4. [root@demo.com ~]# netstat -tulpn |grep 3128 To check whether squid is working or not 5. To check the record of website opened by client [root@demo.com ~]# vi /var/log/squid/access.log 6. Now on client PC Redhat- FireFox- edit menu- preferences- connection setting- Manual Proxy setting-Proxy Server IP- __________ Port no. 3128- check (use this proxy for all protocols) www.google.com or (Only this website you want your client # Path where cache logs are maintained cache_mgr Administrator@demoindia.com #change with your email-address # directory where cache is stored access_log /var/log/squid/access.log squid #Path where access logs are #deafult port number on which squid will

On Windows:- Internet explorer- Tools- Internet Options- connections- Lan Setting-check (use a proxy for this lan)- Give IP & Port no.- OK.

APACHE SERVER

Apache Server is used for hosting website for Internet/Intranet. By this server we can also authenticate only limited users to access website. For this server you must have DNS server configured or add your IP and server name in hosts file. Apache is probably the most popular Linux-based Web server application in use. Once you have DNS correctly setup and your server has access to the Internet, you'll need to configure Apache to accept surfers wanting to access your Web site. Packages: httpd* 1. Install package for http. [root@demo.com ~]# yum install http* or [root@demo.com ~]# rpm -ivh http* 2. Now make a webpage. [root@demo.com ~]# vi /var/www/html/demo.html (for single webpage, for virtual hosting make another page in another location, ) 3. Now when we enter the DNS address, apache server welcome screen comes, if we want to add our own homepage we have to edit a file. [root@demo.com ~]# vi /etc/httpd/conf/httpd.conf </virtual Host *: 80> (change * with IP address) Document root /var/www/html Servername www.demo.com </virtual Host> (save the file) 4. [root@demo.com ~]# service httpd restart 5. Now when you enter the Domain name (www.demo.com) it will open your webpage 6. AUTHENTICATION: open the same file and at the end of file, type the following <Directory AuthUserfile AuthName AuthType Require /var/www/html> /etc/httpd/conf/htpasswd Web Authentication Basic Valid-User (save the file) (at last of the file)

</Directory>

7. Adduser for http [root@demo.com ~]# useradd demo

[root@demo.com ~]# htpasswd -c /etc/httpd/conf/htpasswd demo (it creates a new file htpasswd and add user demo in it) For adding more user [root@demo.com ~]# htpasswd /etc/httpd/conf/htpasswd <username> again start service 8. Virtual HostingFirst copy the above four lines <Virtualhost *:80> (change * with IP address at both place) Documentroot /var/www Servername www.abc.com </Virtualhost> Come to the lines above these lines Name Virtual Host *:80 remove * and # change * with IP address of the system

FTP SERVER

The File Transfer Protocol (FTP) is used as one of the most common means of copying files between servers over the Internet. Most web based download sites use the built in FTP capabilities of web browsers and therefore most server oriented operating systems usually include an FTP server application as part of the software suite. Linux is no exception. This server will show you how to convert your Linux PC into an FTP server using the default Very Secure FTP Daemon (VSFTPD) package included in RHEL6. FTP relies on a pair of TCP ports to get the job done. It operates in two connection channels :FTP Control Channel, TCP Port 21: All commands you send and the ftp server's responses to those commands will go over the control connection, but any data sent back (such as "ls" directory lists or actual file data in either direction) will go over the data connection.FTP Data Channel, TCP Port 20: This port is used for all subsequent data transfers between the client and server. Regular FTP By default, the VSFTPD package allows regular Linux users to copy files to and from their home directories with an FTP client using their Linux usernames and passwords as their login credentials. VSFTPD also has the option of allowing this type of access to only a group of Linux users, enabling you to restrict the addition of new files to your system to authorized personnel. The disadvantage of regular FTP is that it isn't suitable for general download distribution of software as everyone either has to get a unique Linux user account or has to use a shared username and password. Anonymous FTP allows you to avoid this difficulty. Anonymous FTP Anonymous FTP is the choice of Web sites that need to exchange files with numerous unknown remote users. Common uses include downloading software updates and MP3s and uploading diagnostic information for a technical support engineers' attention. Unlike regular FTP where you login with a preconfigured Linux username and password, anonymous FTP requires only ausername of anonymous and your email address for the password. Once logged in to a VSFTPD server, you automatically have access to only the default anonymous FTP directory (/var/ftp in the case of VSFTPD) and all its subdirectories. Required Package

vsftpd* 1. [root@demo.com ~]# rpm -ivh vsftpd* [root@demo.com ~]# yum install vsftpd* 2. [root@demo.com ~]# vi /etc/vsftpd/vsftpd.conf We have to remove # infront of the following lines. anonymous = default user #FTP uses two users anonymous & FTP anonymous has no password local_enable=yes write_enable=yes #Local user can login through FTP #write permission is enabled to FTP #anonymous user can upload files #anonymous user can create directory

anon_upload_enable=yes dir message enable=yes

anon_mkdir_write_enable=yes Ftpd_banner= welcome to FTP

3. [root@demo.com ~]# service vsftpd restart 4. Client end: ftp <Server IP> >cd pub >get <filename> >put <filename> >bye (exit) (download) (upload)

DHCP SERVER

As the network grows bigger , administering each and every computer can becomes difficult. If you need to change critical information of your domain, then it is impossible to give these new information to hundreds of computers in the network manually. A new member to your network means adding a new user account to multiple computers. DHCP provides a method of dynamically configuring IP addresses, network numbers and server locations for the computers on your local LAN. Setting Dynamic Host Configuration Protocol (DHCP) server allows you to centrally manage all the IP and network information for client computers on your LAN. When you have configur ed a DHCP server on your network all the clients will be able to choose between whether they will get there information Dynamically or statically. DHCP server, when properly configured can provide IP address, network mask, DNS server, NetBIOS server, router (gateway), and other information needed to get up and running on the LAN. After the configuration, you can simplify the initial network configuration that each client computer on your LAN need to do. The DHCP is a very robust server and you can easily expand the network with it. Packages required: dhcp* Port numbers: 67 Bootp, 68 DHCP Configuration file: /etc/dhcp/dhcpd.conf Service/Daemon: dhcpd Step 1. You need to install DHCP package. Example: [root@localhost ~]# yum install dhcp* Sample file copy and paste the specified location /etc/dhcp/dhcpd.conf and get the dhcp service. Step 2. [root@localhost ~]# cd /usr/share/doc/dhcp-4.1.1 Step 3. [root@localhost ~]# cp -v dhcpd.conf.sample /etc/dhcp/dhcpd.conf #### Open the DHCP configuration file and add the following ########

Step 4.[root@localhost ~]# vim /etc/dhcp/dhcpd.conf ##### change subnet, netmask, and range ############ subnet 192.168.0.0 netmask 255.255.255.0 { range 192.168.0.2 192.168.0.10; option domain-name-servers ns1.internal.example.org; option domain-name "internal.example.org"; #option routers 10.5.5.1; #option broadcast-address 10.5.5.31; default-lease-time 600; max-lease-time 7200; } Step 5. [root@localhost ~]# service dhcpd restart Step 6. [root@localhost ~]# chkconfig dhcpd on

TELNET

1. # yum install xinetd* 2. # yum install telnet* 3. Now we have to edit a file for enabling telnet. # vi /etc/xinetd.d/telnet disabled= no (by default it is yes, we have do it no.) (save the file) 4. Start the service # service xinetd restart 5. Now you must have a user in the server pc with whom you login and after that with su command you can take the root access.

BIBLIOGRAPHY

As per the need of my project of networking on Linux operating system, I required information regarding various tools used in networking. Therefore I have gone through several websites for above informations. Websites: www.freelinux.org www.linuxdig.com www.linux-howto.com www.in.redhat.com www.wiliesystem.com

Das könnte Ihnen auch gefallen