⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 106-109.html

📁 linux-unix130.linux.and.unix.ebooks130 linux and unix ebookslinuxLearning Linux - Collection of 12 E
💻 HTML
字号:
<HTML>

<HEAD>

<TITLE>Linux Unleashed, Third Edition:Getting Started</TITLE>

<SCRIPT>
<!--
function displayWindow(url, width, height) {
        var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>

 -->




<!--ISBN=0672313723//-->

<!--TITLE=Linux Unleashed, Third Edition//-->

<!--AUTHOR=Tim Parker//-->

<!--PUBLISHER=Macmillan Computer Publishing//-->

<!--IMPRINT=Sams//-->

<!--CHAPTER=6//-->

<!--PAGES=106-109//-->

<!--UNASSIGNED1//-->

<!--UNASSIGNED2//-->



<CENTER>

<TABLE BORDER>

<TR>

<TD><A HREF="101-106.html">Previous</A></TD>

<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>

<TD><A HREF="109-111.html">Next</A></TD>

</TR>

</TABLE>

</CENTER>

<P><BR></P>

<H3><A NAME="Heading4"></A><FONT COLOR="#000077">What&#146;s This About &#147;Logging In&#148;?</FONT></H3>

<P>After you boot the system, Linux waits for a login. A login is simply the name that you supply to Linux to identify yourself to the operating system. Linux keeps track of which names are permitted to log in to the system and allows only valid users to have access. All others are refused access.

</P>

<P>Every login name on the system is unique and typically, a password is assigned to each one. This secret password is like the identification number you use with your bank card to prove that you are who you say you are. Also, the things you can do with your login&#151;the login&#146;s privileges&#151;are controlled by Linux; different logins have different levels of privileges. Some logins can do anything they want to the system, while others may not be able to do very much. The system administrator (or whoever creates the login) assigns these privileges.</P>

<BLOCKQUOTE>

<P><FONT SIZE="-1"><HR><B>Warning:&nbsp;&nbsp;</B><BR>Usually, login names reflect a person&#146;s real name. On larger systems, login names are usually composed of the first and last names, such as <TT>tparker</TT> or <TT>rmaclean</TT>. Smaller systems tend to be less formal, so you may simply have first names or first name and an initial, such as <TT>tim</TT>, <TT>timp</TT>, or <TT>tjp</TT>. Some administrators base login names on something else entirely, such as <TT>wizard</TT> or <TT>goblin</TT>, but these tend to have very little meaning to others outside the single machine.

<P>Although you can&#146;t have two identically named logins on your system, you can easily create logins for users with the same (real) name by changing one or two characters. So the login names <TT>suej</TT> and <TT>suek</TT>, for example, are treated by Linux as completely separate logins.</P>

<P>Conversely, there is no reason that one person (for instance, you) can&#146;t have two, three, or a dozen login names. In fact, because you will be the system administrator of your Linux system, you will have one or more administrative logins and one or more regular user logins.<HR></FONT>

</BLOCKQUOTE>

</P>

<P>At the login prompt, type your name, your dog&#146;s name, or any other random name that occurs to you. None of these are valid logins (at least not yet). The system asks you for a password; it doesn&#146;t matter what you type, so simply press Enter or type a random string of characters. Because the logins are not valid on the system, Linux won&#146;t let you in. It displays the message <TT>Login incorrect</TT> to tell you that either the name or the password you entered is not valid.</P>

<P>Most likely, the only valid login on your Linux system after installation is the most powerful and dangerous login Linux offers: <TT>root</TT>. In the section &#147;Creating a New Login&#148; that appears later in this chapter, we will create a safe login for you to use. This safe login can have your name, your dog&#146;s name, or whatever you choose. Some versions of Linux prompt you to create a user login during the installation procedure, so you have two logins (<TT>root</TT> and a username) that you can use.</P>

<BLOCKQUOTE>

<P><FONT SIZE="-1"><HR><B>Warning:&nbsp;&nbsp;</B><BR>Why does Linux bother asking for a password even when the login name is not valid? It&#146;s because Linux uses a program called <TT>login</TT> that&#146;s instructed to get your login and password first, then check the list of valid users. The login program then displays a message that shows if you are denied access or it lets you through to the next program that starts your user session.<HR></FONT>

</BLOCKQUOTE>

<H4 ALIGN="LEFT"><A NAME="Heading5"></A><FONT COLOR="#000077">Why You Should Not Use the root Login</FONT></H4>

<P>You will have to use the <TT>root</TT> login from time to time. Some things simply cannot be done on the Linux system without logging in as <TT>root</TT>. You should not, however, use the <TT>root</TT> login as your regular user login. This is especially true if you are exploring the system, poking around and trying out new commands that may not do what you thought they would. You could cause damage to your operating system installation and have to reinstall from scratch.</P>

<P>Linux, as you already know, is a multiuser, multitasking operating system. Multiuser means that several people can be using Linux at the same time (of course, you have to add some additional terminals to your system, or it will get very crowded around the keyboard). Multitasking means that Linux can do more than one thing at a time. For example, you can spell-check a document while downloading information from a remote system. (Multiuser implies multitasking, because all users must be able to do their own work at the same time.) Linux, therefore, is very good at juggling all of these tasks, keeping them from interfering with one another and providing safeguards so that you cannot damage the system or another user&#146;s work.</P>

<BLOCKQUOTE>

<P><FONT SIZE="-1"><HR><B>Warning:&nbsp;&nbsp;</B><BR>The <TT>root</TT> login does not restrict you in any way. This means that with one simple command, issued either on purpose or by accident, you can destroy your entire Linux installation. For this reason, use the <TT>root</TT> login only when necessary. Avoid experimenting with commands whenever you log in as <TT>root</TT>.<HR></FONT>

</BLOCKQUOTE>

<P>When you log in as <TT>root</TT>, you <I>become</I> the system. The <TT>root</TT> login is also sometimes called the <I>superuser</I> login and with good reason. To use an analogy, instead of being simply a passenger on an airplane, you suddenly have all the power and responsibility of the flight crew, the mechanics, and the cabin crew. &#147;Hmm, what does this do?&#148; becomes an extremely dangerous phrase when logged in as <TT>root</TT>.</P>

<P>One of the oldest stories in UNIX lore tells of new users who log in as <TT>root</TT> and, in ten keystrokes, destroy their system completely and irrevocably. But if you&#146;re careful to follow the steps given here, and stop and take a moment to think about the commands you are giving, none of the &#147;How many new users does it take to nuke a system?&#148; jokes will apply to you!</P>

<BLOCKQUOTE>

<P><FONT SIZE="-1"><HR><B>Note:&nbsp;&nbsp;</B><BR>System administrator is another term you will see often. A system administrator is the actual person who sets up and maintains the Linux system. The amount of work involved in system administration varies from system to system. A full-time system administrator may be required in an office that has several powerful machines with many users, peripheral units such as printers and tape drives, and are connected to a network. Your Linux system will most likely not require that level of dedication!<P>System administration, because it deals with sensitive matters such as creating or deleting logins, requires superuser privileges. These privileges are provided by the <TT>root</TT> login. So, the system administrator is an actual person wielding superuser powers gained by logging in as <TT>root</TT>.<HR></FONT>

</BLOCKQUOTE>

</P><P><BR></P>

<CENTER>

<TABLE BORDER>

<TR>

<TD><A HREF="101-106.html">Previous</A></TD>

<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>

<TD><A HREF="109-111.html">Next</A></TD>

</TR>

</TABLE>

</CENTER>





</td>
</tr>
</table>

<!-- begin footer information -->





</body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -