LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   path problem - startkde :command not found (https://www.linuxquestions.org/questions/linux-newbie-8/path-problem-startkde-command-not-found-256432/)

batfastad 11-18-2004 09:51 AM

path problem - startkde :command not found
 
Hi

I'm new to Linux and I think I have a path problem.

Not sure what a path problem is, not sure how to solve it.

Basically this is because I'm trying to install xvnc and I want to use kde as my default window manager rather than twm.
So apparently all I have to do is replace 'twm' on the last line in the ~./vnc/xstartup script with 'startkde'

However when I start the vncserver and login on my windows machine, I get a grey background and a terminal screen.

When I look at the server startup log in ~./vnc/ there seems to be a problem with the startkde command.
It says startkde :command not found

I've been led to believe that this is a PATH problem but I have no idea as to how I fix it.

Any ideas?

Thanks

Ben

qwijibow 11-18-2004 10:24 AM

before that commandd, add the line

Code:

export PATH=$PATH:/usr/kde/bin/
replace /esr/kde/bin with the kde/bin path of your system.

batfastad 11-18-2004 10:56 AM

How do I find the kde/bin path of my system?

I'm assuming it will probably be the default so usr/kde/bin

But if I do a search for the command 'startkde' in search files then I'm assuming whatever folder that file is in, is the path I need.

Thanks for your help

Ben

jschiwal 11-18-2004 11:04 AM

On my system the startkde command is in '/opt/kde3/bin/'

Type in 'locate startkde' to find the path to the kde executables. Then edit your ~/.profile or ~/.bash_login file to add this directory to your PATH environment variable.

qwijibow 11-18-2004 11:07 AM

be sure to run "updatedb" before you run "locate"
locate is an optimed searvh, that uses a database of your hard-drive generated by the updatedb command...

everything your system has changed significantly, and you want to use locate, re-run updatedb.

anyways.. yeah, you need to search for a /bin/startkde

batfastad 11-18-2004 03:16 PM

Sorted!

Just another quick question...

The files
~/.profile
~/.bash_login

Are they run when you first login?
Or when you start KDE?
What's the difference between them?

I can't find a .bash_login file in my home dir

Would it work if I added the following commands to the end of .profile...

cd /usr/local/bin
./vncserver

??
I'm trying to get the vnc server to run automatically on startup.

I must admit I'm loving Linux. Everything goes into your home dir. So you can easily backup application settings. Not like in windows with the registry. I liked windows when it kept everything in .ini files - that was good.

Thanks

jschiwal 11-18-2004 05:28 PM

They are run when you log in. You don't need to use kde.
The .bash_login is bash specific while more then one shell will use .profile.

They are alternatives. You can use just .profile. Read 'info bash' for details on the startup scripts run. The login scripts will sometimes call other scripts. On some distros for instance, there is a scripts called aliases and .aliases which are run if they exist. Reading through your .bashrc and .profile scripts will help locate such files.

For things like setting the path, you don't want to use the .bashrc script because it is run every time you open a new shell. This could result in the same path being tagged on to the end of the PATH variable.

batfastad 11-18-2004 07:12 PM

Excellent!

I'll just use .profile then.

One final final question...

In .profile is it ok to have something like this...

cd /usr/local/bin
./vncserver

Would that run as expected or does the script in .profile have to be a special scripting language, rather than just command line syntax?

Thanks

Ben


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