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 12-03-2012, 09:51 AM   #1
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 58

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, 01: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, 02:32 PM   #3
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 58

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:	30
Size:	65.2 KB
ID:	11339  
 
Old 12-03-2012, 02:35 PM   #4
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 58

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, 05:55 PM   #5
mbstemps
LQ Newbie
 
Registered: Feb 2009
Location: Eugene
Distribution: Kylix3 on Red Hat 4.7
Posts: 4

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, 09:36 AM   #6
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 58

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, 11: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, 08:20 AM   #8
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 58

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, 01: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 01:17 PM.
 
Old 12-06-2012, 12:04 PM   #10
DavidDiepUSC
Member
 
Registered: Jan 2008
Posts: 58

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


All times are GMT -5. The time now is 02:38 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