LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-05-2015, 09:10 PM   #1
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Rep: Reputation: 174Reputation: 174
x11vnc on Ubuntu Mate - issue when not logged on to remote PC


I have Ubuntu Mate 15.04 on my "remote" PC. I can connect with ssh and start vncserver and access the resulting desktop with Vinagre on my CentOS desktop without being logged onto the physical terminal of the remote PC. This is all well and good. Except...

Sometimes I need to access the physical terminal session on the remote PC. I have installed x11vnc for this purpose. If I manually logon to the remote PC first I can connect with x11vnc thusly:
Code:
x11vnc
However, if I am not logged in to the physical terminal I am unable to start x11vnc. The messages provide in part this information
Quote:
** If NO ONE is logged into an X session yet, but there is a greeter login
program like "gdm", "kdm", "xdm", or "dtlogin" running, you will need
to find and use the raw display manager MIT-MAGIC-COOKIE file.
Some examples for various display managers:

gdm: -auth /var/gdm/:0.Xauth
-auth /var/lib/gdm/:0.Xauth
kdm: -auth /var/lib/kdm/A:0-crWk72
-auth /var/run/xauth/A:0-crWk72
xdm: -auth /var/lib/xdm/authdir/authfiles/A:0-XQvaJk
dtlogin: -auth /var/dt/A:0-UgaaXa

Sometimes the command "ps wwwwaux | grep auth" can reveal the file location.

Starting with x11vnc 0.9.9 you can have it try to guess by using:

-auth guess
-auth guess does not work so I tried
Code:
ps wwwwaux | grep auth
/var/run/lightdm/root/:0
/var/run/lightdm/root of course belongs to root so I am forced to use this command to start x11vnc
Code:
sudo x111vnc -auth /var/run/lightdm/root/:0
This is certainly a workable solution. However, I am wondering if I can start x11vnc as my normal user ID? Perhaps the greeter, before anyone logs in belongs to root? If I start x11vnc with sudo from my user ID "ken" and then attempt to login to the remote system with another user ID... perhaps something will tilt? I will have to try.

While I am setting up a second user on the remote system and testing... am I wrong in wanting to start x11vnc on a non-logged on PC without sudo?

TIA,

Ken

p.s. I have created a second, not sudoer user. I can start x11vnc and logon as that user on the remote PC using the x11vnc remote desktop. When I logout as that user x11vnc shuts down as it is supposed to. I did notice that if I restart x11vnc or logon physically to the remote PC with MY ID there is a terminal in the upper left part of the screen. This is not normally present. If I login as the new user, exit, restart x11vnc and login as the new user again I do not sees the terminal window. Strange.

Last edited by taylorkh; 07-05-2015 at 09:22 PM. Reason: more info
 
Old 07-06-2015, 11:46 AM   #2
sudowtf
Member
 
Registered: Nov 2013
Posts: 206

Rep: Reputation: 46
i've always used sudo myself because it works as expected.
also see this post as it may have some further tips.
 
Old 07-06-2015, 11:57 AM   #3
taylorkh
Senior Member
 
Registered: Jul 2006
Location: North Carolina
Distribution: CentOS 6, CentOS 7 (with Mate), Ubuntu 16.04 Mate
Posts: 2,127

Original Poster
Rep: Reputation: 174Reputation: 174
Thanks sudowtf! Sudo makes sense I suppose. At least now I can access either my "internal" vncserver session - almost like a REAL computer (mvs, Zos etc.) And, if necessary I can access the physical console without having to walk across my office

I am familiar with the -forever option in x11vnc and the use of & and screens. I do thank you again for pointing me to that excellent thread. x11vnc has a LOT of options - too many for my brain. I may explore some additional ones but for now I am good to go.

Regards,

Ken
 
  


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
Desktop sharing (remote desktop) Ubuntu Mate 14.10 taylorkh Ubuntu 5 06-03-2015 11:31 AM
LXer: Ubuntu MATE 15.04 Arrives With MATE Desktop 1.8.2 and MATE Tweak LXer Syndicated Linux News 0 05-15-2015 10:30 AM
LXer: Ubuntu MATE 14.10 PPA Updated, Includes MATE 1.8, User Intervention Required LXer Syndicated Linux News 0 03-20-2015 09:10 AM
best soft for desktop remote support? x11vnc? matiasar Linux - Software 3 03-06-2013 06:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:51 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
Open Source Consulting | Domain Registration