home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  

Unix Power ToolsUnix Power ToolsSearch this book

3.6. Tip for Changing Account Setup: Keep a Shell Ready

The shell is your interface to Unix. If you make a bad mistake when you change your setup file (Section 3.3) or your password, it can be tough to log in and fix things.

Before you change your setup, it's a good idea to start a login session to the same account from somewhere else. Use that session for making your changes. Log in again elsewhere to test your changes.

Don't have a terminal with multiple windows or another terminal close to your desk? You can get the same result by using rlogin or telnet (Section 1.21) to log in to your host again from the same terminal. What I mean is:

somehost% vi .cshrc
   ...Make edits to the file...
somehost% rlogin localhost
   ...Logs you in to your same account...
An error message
somehost% logout
Connection closed.
somehost% vi .cshrc
   ...Edit to fix mistake...

If you don't have rlogin or telnet, the command su - username, where username is your username, will do almost the same thing. Or, if you're testing your login shell configuration, login will do as well.

--JP and SJC

Library Navigation Links

Copyright © 2003 O'Reilly & Associates. All rights reserved.