Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I recently bought a router (Billion 7404VGP) and replaced my dial-up internet connection with an ADSL connection via eth0.
This connection activates at boot. My ISP is named "internode".
I now notice that the prompt at the command line has changed from what it used to be.
The prompt now takes the form of; [myname@internode]$
I cannot remember what it used to be, but the word "internode" was definately not there.
I think it may have been [myname@localhost]$
I have now found that when I try to execute some simple Java commands such as javac, I get an error that reads; bash: javac: command not found
Even entering; [myname@internode]$ java -version
results in a similar error.
The java tools cannot be found anymore. I set the classpath a long time ago when I first installed the Java Development Kit and previously used java commands without problems. Do I now have to add something new to the classpath because of the new "internode" Internet connection?
Connecting to the Internet via eth0 and the router has done something I do not understand, both to the command line prompt and access to my system's Java tools.
Well, it's OK with your prompt, it prints your host name.
To elaborate, when you were on dial up your computer was directly connected to the internet and your hostname and a few other things were being dictated by your net connection. Now the router is the connected device, not your computer.
Thanks. I am guessing that if I closed the eth0 connection, that the command line prompt would change back to what it used to be (ie "localhost" rather than "internode"). Is this true?
As far as my Java commands are concerned, it seems a little too coincidental that as soon as I connected the router (which caused the host name to change at the command line prompt) that my ability to execute Java commands from the command line suddenly stopped.
As far as the PATH is concerned, if I enter [user@ispname user]$ env
I look down the list and see that PATH is as follows; PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/share/pvm3/
Would I simply add a path to the directory where Java is anstalled to allow it to be accessed?
ie add :/usr/java
If so how do I edit it? I tried [user@ispname user]$ emacs env
but this didn't seem to give me access to the PATH for editing.
Also to try I want to try and work backwards on how the command line prompt is constructed.
Can anyone tell me what file the command line prompt gets the string that represents the hostname from?
For example in my new prompt; [user@ispname user]$