WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: question about vnc and question about slim  (Read 7100 times)

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
question about vnc and question about slim
« on: May 12, 2010, 11:56:18 AM »
We're using pxe booting TCL (base) with x0vncserver (and ntfs-3g) so our support folks can vnc in and work on damaged windows systems.

The problem is that we don't want users to be able to interact with TCL since when it boots it's already logged in.  So I added slim.tcz to the tftplist (and gave the tc user a new password and restored the required files to support this, in a custom.tcz).  We're using 2.11.

How can we get 1) the TCL to boot into graphical mode with a login prompt, and 2) allow vnc into the box so the techs can login remotely?

I can vnc in just fine if I don't use slim-- but if I don't use slim then TCL is already logged in as tc, so the users can muck around and we dont want that.

If I use slim, I cannot vnc in-- I suppose thats because the x0vncserver hasn't started yet because I think that's in the .xsession file for the tc user and they have to log in for that to run.  And when I enter the credentials locally, slim just displays a text page that says "mtrr something..." and then flips back to the slim login -- that's when I log in as tc.  When I log in as root, it says failed to execute login command and then flips to the text screen and then back.

[Seems like this would be a common thing, and I did google and search here to no avail... probably dont have the right terms, sorry.]

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10118
Re: question about vnc and question about slim
« Reply #1 on: May 12, 2010, 01:00:16 PM »
Slim's unmaintained currently, both upstream and the extension. You might have better luck with xdm.

Though, is vnc a requirement? Xdm was designed for network logins over the X protocol itself; way more efficient than vnc in many cases.
The only barriers that can stop you are the ones you create yourself.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: question about vnc and question about slim
« Reply #2 on: May 12, 2010, 01:04:23 PM »
VNC can be encrypted for better security.

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
Re: question about vnc and question about slim
« Reply #3 on: May 12, 2010, 01:09:09 PM »
vnc only because the techs will be running vnc clients on their windows machines.

With xdm, will x0vncserver still start before the login prompt?

I tried xdm and it did nothing-- probably my fault.  I understood from the comments to put "grep -q xdm /proc/cmdline && sudo xdm" as the last line in the /opt/bootlocal.sh file, and "test -r .profile &&. ./profile" as the first line in the /home/tc/.xsession file.

I'll try it again.  Would a different vnc server package work better (before the login)?

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
Re: question about vnc and question about slim
« Reply #4 on: May 12, 2010, 01:23:44 PM »
Nope.  xdm installed with dependencies, setup as specified in the comments, doesn't seem to do anything.  When the machine came up, I was already logged in as tc user so I dropped to the shell and ps -ef | grep xdm showed nothing.  So I started it manually, and still don't see anything, even after I logged out.  I know I'm missing something or don't understand something, but I'm not sure what I need to do to get this working.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: question about vnc and question about slim
« Reply #5 on: May 12, 2010, 01:56:49 PM »
XDM allows you to do an X login from another machine.
Not what you want over the internet.
It is neither secure nor encrypted.

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10118
Re: question about vnc and question about slim
« Reply #6 on: May 12, 2010, 02:05:51 PM »
Okay, lets look at the problem from a different angle. For whom is the password? To stop the local user?

If so, just let the local screen be a text login (noautologin boot code), and use a VNC server that creates a virtual screen, like tightvnc/realvnc.
The only barriers that can stop you are the ones you create yourself.

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
Re: question about vnc and question about slim
« Reply #7 on: May 12, 2010, 02:10:57 PM »
Yes... we don't want the local user logging in.  It's all on our intranet.  I will try one of the other VNCs.  Thanks.

Offline maro

  • Hero Member
  • *****
  • Posts: 1228
Re: question about vnc and question about slim
« Reply #8 on: May 12, 2010, 02:11:23 PM »
@mfrederickson: First off, I have no particular experience in what you are trying to achieve, I merely like to offer my interpretation of what you've reported earlier.

Are you aware of what the entry you've added to '/opt/bootlocal.sh' (i.e. grep -q xdm /proc/cmdline && sudo xdm) does? AFAIK it is a test if 'xdm' was used as a boot code, and if so to start 'xdm' as 'root' (which is a bit redundant since '/opt/bootlocal.sh' is run as 'root' anyway). So unless you have used 'xdm' as boot code I'm not surprised that you did not find 'xdm' running.

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
Re: question about vnc and question about slim
« Reply #9 on: May 12, 2010, 02:15:50 PM »
@maro, I did not know that /proc/cmdline was the boot codes.  I suspected it was a boolean evaluation and might bail before it kicked it off.  Thanks.  I will add xdm to the bootcodes and retry that.

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
Re: question about vnc and question about slim
« Reply #10 on: May 12, 2010, 02:26:41 PM »
Well, I added xdm to the bootcodes and still no dice.  Oh, xdm was found running, but no gui login came up.  I'm going to try another vnc client with a virtual screen.  Our goal was to keep everything as small as possible, so I'll be looking at tightvnc instead of realvnc.

With tightvnc, where do I tell it to start Xvnc :1 in the bootlocal.sh?

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10118
Re: question about vnc and question about slim
« Reply #11 on: May 12, 2010, 03:51:51 PM »
I tried it, and it actually works out pretty nicely :)

Using the bootcode "noautologin", installed tightvnc extension, and this in bootlocal.sh:

Quote
#!/bin/sh
# put other system startup commands here

echo "Xvnc" > /etc/sysconfig/Xserver # This is for our auto-check in startx
cd /home/tc
sed -i 's@Xvesa.*@Xvnc -depth 16 -geometry 800x600 :0 \&@' .xsession # Changing the default
su tc -c startx

No automatic local login, standard TC desktop on VNC screen 0.

 
« Last Edit: May 12, 2010, 03:53:43 PM by curaga »
The only barriers that can stop you are the ones you create yourself.

Offline mfrederickson

  • WikiUser
  • *
  • Posts: 9
Re: question about vnc and question about slim
« Reply #12 on: May 12, 2010, 04:54:07 PM »
You are a genius. 

You would not believe the results I was getting before I tried your last post... oh wait, maybe you would... looks like you've been around a while (all those posts).  I sincerely appreciate the help.

All I need to do now is add the -rfbauth parm and I'll be good to go.  I can manage that.

Thanks again for taking the time to solve this for me.

Offline ^thehatsrule^

  • Administrator
  • Hero Member
  • *****
  • Posts: 1726
Re: question about vnc and question about slim
« Reply #13 on: May 12, 2010, 08:42:24 PM »
I'll just point out that the encryption argument against X forwarding is not really relevant because it could always be tunneled through something like ssh.

Offline gerald_clark

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 4254
Re: question about vnc and question about slim
« Reply #14 on: May 12, 2010, 08:59:50 PM »
X forwarding under ssh is unrelated to XDM.