LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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!

Notices


Reply
  Search this Thread
Old 09-18-2006, 12:26 AM   #1
une
Member
 
Registered: May 2004
Location: Australia
Distribution: Mandrake 10, Puppy Linux 2.13
Posts: 201

Rep: Reputation: 30
Command line prompt has changed


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.

Last edited by une; 09-18-2006 at 12:56 AM.
 
Old 09-18-2006, 01:52 AM   #2
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
Well, it's OK with your prompt, it prints your host name.
And it can't affect your Java installation. Check if this commands are in the directories from PATH variable.
 
Old 09-18-2006, 02:17 AM   #3
cs-cam
Senior Member
 
Registered: May 2004
Location: Australia
Distribution: Gentoo
Posts: 3,544
Blog Entries: 4

Rep: Reputation: 57
Quote:
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.
 
Old 09-19-2006, 10:51 PM   #4
une
Member
 
Registered: May 2004
Location: Australia
Distribution: Mandrake 10, Puppy Linux 2.13
Posts: 201

Original Poster
Rep: Reputation: 30
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]$

What file did the string
ispname
come from?

Last edited by une; 09-20-2006 at 10:36 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Can the command line terminal resolution be changed? lazyFoot_theMighty Linux - General 2 08-03-2006 09:44 PM
httpd -l and mysql -p at any command line prompt ZC1 Linux - General 1 05-23-2006 09:58 AM
Hostname was changed on the command prompt pretty.tulip Linux - Newbie 1 04-02-2006 11:21 PM
Bringing Up Command Line\prompt hondagetter Linux - General 3 09-04-2005 06:13 AM
problem with command line prompt ??? robeb Linux - General 2 12-07-2002 08:47 PM


All times are GMT -5. The time now is 10:52 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration