LinuxQuestions.org
Help answer threads with 0 replies.
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 12-03-2012, 08:51 AM   #1
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 61

Rep: Reputation: 0
VNC question


Hi,

I have some questions about VNC... maybe you guys can help me out.

When I finish my VNC session, the next time I log back in, I do not get the desktop but just checkboxes for clipboard options. The only way I can get the desktop again is if I go and restart the VNCSERVER on the Linux machine.

What can I do keep me from doing this... it kinda sucks.

Here is my /.vnc/xstartup:

#!/bin/sh

[ -r /etc/sysconfig/i18n ] && . /etc/sysconfig/i18n
export LANG
export SYSFONT
vncconfig -iconic &
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
OS=`uname -s`
if [ $OS = 'Linux' ]; then
case "$WINDOWMANAGER" in
*gnome*)
if [ -e /etc/SuSE-release ]; then
PATH=$PATH:/opt/gnome/bin
export PATH
fi
;;
esac
fi
if [ -x /etc/X11/xinit/xinitrc ]; then
exec /etc/X11/xinit/xinitrc
fi
if [ -f /etc/X11/xinit/xinitrc ]; then
 
Old 12-03-2012, 12:38 PM   #2
shivaa
Senior Member
 
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
It sounds that when you login back, your VNC desktop services do not start properly or your gnome profile is not loading properly.
Generally there's GNOME desktop associated with VNC/Linux machines. So I guess you're not getting that default fully functional GUI desktop, but only some wierd screen with gray icon and an xterm.

So you could try:

Save all your jobs, kiil the VNC session and create a new VNC port (i.e. session) for yourself.
If it cannot help, then once share the screenshot of that wierd desktop, and permissions/ownership info. of your home plus .vnc directory.

And if still problem persists, then I'd suggest you to reset your gnome profile.
 
Old 12-03-2012, 01:32 PM   #3
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 61

Original Poster
Rep: Reputation: 0
Thanks shivaa

I created another port, but it did not help. After the initial VNCSERVER start, I would be able to login and see the desktop. I would then quit and log off. My next VNC session would result in what you see in the attachment.

Thanks for all your help...
Attached Thumbnails
Click image for larger version

Name:	Capture.JPG
Views:	43
Size:	65.2 KB
ID:	11339  
 
Old 12-03-2012, 01:35 PM   #4
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 61

Original Poster
Rep: Reputation: 0
This is all that is in the .vnc folder:

lsysg01a.in.dc.gov:1.log lsysg01a.in.dc.gov:1.pid passwd xstartup
 
Old 12-03-2012, 04:55 PM   #5
mbstemps
LQ Newbie
 
Registered: Feb 2009
Location: Eugene
Distribution: Kylix3 on Red Hat 4.7
Posts: 6

Rep: Reputation: 0
vnc logoff

I don't know how you are looking off, but just click the vnc in the upper left hand corner of the screen, click on 'close' the screen should be there when you come back.

John.
 
Old 12-04-2012, 08:36 AM   #6
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 61

Original Poster
Rep: Reputation: 0
mbstemps,


Thanks! Apparently thats what will retain your session...

Man, I wish there was an explanation why.

Thanks again!
 
Old 12-04-2012, 10:35 PM   #7
shivaa
Senior Member
 
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
Close option will do something like what hibernate option do in windows. It will keep your session & jobs alive. You can use F11 key to open the option.
On the other hand, could you open a terminal or able to do a right click on VNC desktop? If not then try to open it using ALT+CTRL+T and check for following process:
Code:
ps -aef | grep metacity
Also check your DISPLAY variable, as:
Code:
echo $DISPLAY
And set it to "hostname:<port-no>", if not set. Then logout & login and check.

Although it may problem with a corrupt xstartup, but first once reset your gnome profile:
Code:
cd ~
ls -la gno* gcon*
mkdir old_gnome
mv gno* gcon* old_gnome
Then again logout & login again. It will create new .gno* and .gcon* files in your home dir. So check if it works. If it also couldn't help, then sure there's pb with xstartup.
 
Old 12-05-2012, 07:20 AM   #8
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 61

Original Poster
Rep: Reputation: 0
Thanks!

Here are the results of ps -aef | grep metacity
root 21245 21216 0 Dec04 ? 00:00:00 metacity
root 36032 36005 0 08:16 pts/1 00:00:00 grep metacity
echo $DISPLAY
:1.0
This is what is in XSTARTUP right now:

#!/bin/sh
[ -r /etc/sysconfig/i18n ] && . /etc/sysconfig/i18n
export LANG
export SYSFONT
vncconfig -iconic &
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
OS=`uname -s`
if [ $OS = 'Linux' ]; then
case "$WINDOWMANAGER" in
*gnome*)
if [ -e /etc/SuSE-release ]; then
PATH=$PATH:/opt/gnome/bin
export PATH
fi
;;
esac
fi
if [ -x /etc/X11/xinit/xinitrc ]; then
exec /etc/X11/xinit/xinitrc
fi
if [ -f /etc/X11/xinit/xinitrc ]; then[/INDENT]
 
Old 12-05-2012, 12:13 PM   #9
shivaa
Senior Member
 
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
(1) Metacity is running. It's ok.
(2) Are you using a remote VNC server and connecting through vncviewer? If yes, then after login into it, set your DISPLAY variable as:
Code:
<vnc-hostname>:<your-vnc-port-no>
For example (below is just sample):
myvnvcserver.myorg.com:1.0
Append the same in your .bashrc or .cshrc as:
Code:
DISPLAY=myvnvcserver.myorg.com:1.0; export DISPLAY (In .bashrc)
setenv DISPLAY myvnvcserver.myorg.com:1.0 (in .cshrc or .tcshrc)
(3) Then try to reset gnome profile as I wrote above. Also mention is right click working on vnc display?

Last edited by shivaa; 12-05-2012 at 12:17 PM.
 
Old 12-06-2012, 11:04 AM   #10
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 61

Original Poster
Rep: Reputation: 0
Shivaa,

I'm not using a remote VNCSERVER, the VNC Server is native on the server. Right click does work, I've attached the screenshot.

Thanks!
Attached Thumbnails
Click image for larger version

Name:	Capture.JPG
Views:	31
Size:	73.3 KB
ID:	11349  
 
  


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
VNC Question ceantuco Linux - Newbie 4 12-30-2008 11:56 AM
VNC question sureshot324 Linux - Software 4 08-23-2007 09:06 PM
Yet another vnc question section31 Fedora 2 09-22-2005 01:26 AM
vnc question coal-fire-ice Solaris / OpenSolaris 9 09-13-2005 12:48 PM
VNC Question iz3r Linux - Software 11 02-04-2005 09:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:24 AM.

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
Open Source Consulting | Domain Registration