Book Image

Linux Utilities Cookbook

By : James Kent Lewis
Book Image

Linux Utilities Cookbook

By: James Kent Lewis

Overview of this book

<p>Linux is a stable, reliable and extremely powerful operating system. It has been around for many years, however, most people still don't know what it can do and the ways it is superior to other operating systems. Many people want to get started with Linux for greater control and security, but getting started can be time consuming and complicated. <br /><br />A practical, hands-on guide that provides you with a number of clear step-by-step examples to help you solve many of the questions that crop up when using an operating system you may not be familiar with.</p> <p>Presenting solutions to the most common Linux problems in a clear and concise way, this helpful guide starts with spicing up the terminal sessions by command retrieval and line editing, and shell prompt variables. We will then get to know the different desktops (GUIs) available for Linux systems and which is the best fit for you. We will then explore the world of managing files and directories, connectivity, and what to do when it goes wrong. We will also learn a range of skills, from creating and managing user accounts to securing your system, managing and limiting processes, and letting information flow from one process to another using pipes. Later, we will master disk management, working with scripts and automating tasks quickly, and finally, understand the need for a custom kernel and tips on how to build one.</p> <p><br />Based on the author's extensive experience, there is a section on best practices that every Linux user should be familiar with.</p>
Table of Contents (19 chapters)
Linux Utilities Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Root user versus normal user


Running as the root user versus a normal user mostly depends on the environment you are in. If each person has their own workstation and is in charge of how it is set up, then running as root might be very natural for you (especially if you don't make mistakes). However, if you're working in a bank or other situation where a typing error might wipe out a million dollar account, running as root is certainly not advisable. In these cases, assuming you have the authority, you would switch to root only when necessary and only to perform the needed task. Using sudo, if it has been configured correctly, is also an option. See Chapter 5, Permissions, Access, and Security, for more information on sudo.

Another thing to keep in mind is how comfortable you are running as root. If you are error prone or nervous, and/or have caused serious damage in the past running as root, you obviously need to take great care when doing so. On the other hand, if you consistently run as root and don't ever make a mistake then that is great. It is certainly more efficient.

A special note to system administrators: I have seen this on more than one occasion and so will mention it here. This applies to both novice and seasoned system administrators.It is customary for you (and maybe your manager) to be the only ones with root authority on the systems. This sounds like a good idea, right? It might avoid having someone make a mistake that could take out an entire project. And, it just feels good being the person in charge. People come to you when they need something changed and you happily do it. Then they come again, and again, and again. At some point you realize you can't get any of your work done because of all the requests, and that they can't have their work done if you are not around. So you try and set up sudo. Now it's even worse; every time you think you have it set up to handle anything, someone may come to you if it fails again. So what do you do?

You may be able to give selected users root access. Use your instincts. For example, watch how the individual users type. Are they comfortable when using the command line? Do they type with authority, or seem scared of the machine? If a particular user consistently uses the GUI to perform tasks that are done much more efficiently on the command line, then I would see that as a strong warning sign.

In time you will get a feel of who can be trusted with root access and be able to grant it to them. If, of course, someone does make a mistake, then it should not be the end of the world. They can't really hurt the entire project, because you have been creating and verifying daily backups, right? You can restore the damage and take root back from them. Note, one mistake is all it takes. I would not trust that user with root again.