LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 03-19-2006, 10:24 AM   #1
zingfharn
LQ Newbie
 
Registered: Apr 2002
Location: London
Posts: 2

Rep: Reputation: 0
Synergy [vnc], ssh, cron and X from XP to Ubuntu


Hi,

This is sort of a complex one.

I run a laptop at work which has a secondary monitor and gets its IP via DHCP. I also have a linux box under my desk which is static IP. This, too, has a monitor.

I got sick of switching keyboards all the time, and tried to find a software solution to my problem, before I invested in a KVM.

Synergy is a neat little tool which creates a 1-pixel wide vnc window on the edge of your screen, so when you mouse to the edge, you get control over the other computer.

I have tried setting up the linux box as a the server, and the laptop as the client. This results in me not being able to access both laptop screens, only the master. This is not ideal. So, setting the laptop as the master, and the linux box as the client works a treat.

However, since the laptop is DHCP, when I boot up, I get a new IP most days. So, I still have to log into the linux box, and restart synergyc

Now, I thought I might be able to get around this using ssh.
I could ssh into the linux box, kill synergyc, restart with my new ip. However, I get the following error messages:

chewy@toaster:~$ synergyc -f -1 <ip_address>
INFO: synergyc.cpp,708: Synergy client 1.2.7 on Linux 2.6.13.4-gg5vb7 #1 SMP Tue Nov 29 11:33:51 PST 2005 i686
DEBUG: CXWindowsScreen.cpp,776: XOpenDisplay(":0.0")
Xlib: connection to ":0.0" refused by server
Xlib: Invalid MIT-MAGIC-COOKIE-1 key
WARNING: synergyc.cpp,337: cannot open secondary screen: unable to open screen

So, if I muck about with xhost (xhost +, for example) it works. However, I can't run xhost + from the remote command line, because I get 'cannot open display ""'. So, I still need to do something manually from the linux box. Not wanting to leave xhost + active, I do xhost - afterwards.

I've since discovered xauth, but again, can't get this working.
What I -really- want to do is have a cronjob, which picks up the ip address of my laptop automatically (done this bit) and restarts synergyc when it detects a new ip (done this bit, too).

The problem is the same as that with ssh = I get the cookie denied stuff, and nothing I can do with xauth seems to make it work.

So, basically, how can I set up a cronjob with permission to set up a process that requires usage of x?
 
Old 03-19-2006, 04:53 PM   #2
tamoneya
Member
 
Registered: Jan 2005
Location: MA
Distribution: Ubuntu 7.10
Posts: 558

Rep: Reputation: 30
why dont you just use no-ip to give your self a static ip on the linux box?
http://www.no-ip.com/
 
  


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 over ssh ieuuk Linux - Networking 18 01-18-2006 07:11 AM
vnc with ssh lawkh Linux - Newbie 1 02-10-2004 01:12 AM
ssh and VNC linuxnube Linux - Security 4 01-28-2004 10:12 PM
how to use vnc with ssh ? norikage Mandriva 9 08-30-2003 12:40 PM
VNC on SSH??? Jerry78 Linux - Newbie 3 07-17-2003 03:20 AM


All times are GMT -5. The time now is 07:03 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration