LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 01-10-2010, 07:12 PM   #1
Peterken
Member
 
Registered: Apr 2007
Location: Belgium
Distribution: Debian
Posts: 63

Rep: Reputation: 20
start gqview from windows over ssh with putty/plink


Hi guys,

I'm trying to figure out how to start/stop gqview remotely from a batch script on a windows machine.
Stopping works with killall (thanks to Greenfuse here on LQ) but starting gives me a
Code:
Gtk-Warning **: cannot open display
warning.

Is this because it tries to open a GUI in the terminal and if so, can anyone point me in the direction on how to solve this?

Thanks a lot in advance!
Peter
 
Old 01-10-2010, 09:30 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Depends on where you want the images to show?


On a (remote) Linux box, or on the Windows machine?



Cheers,
Tink
 
Old 01-10-2010, 10:36 PM   #3
Peterken
Member
 
Registered: Apr 2007
Location: Belgium
Distribution: Debian
Posts: 63

Original Poster
Rep: Reputation: 20
Hi Tinkster, thank you for responding.

Well, the situation is like this:
- a linux box with a samba share (server) is running gqview - fullscreen in a loop. The machine will be out of reach, boots and shuts down automatically.
- from a windows machine, pictures are added and removed from that samba share.

From a batch script on the windows pc, I would like to be able to start/stop the presentation for adding/removing pictures and boot (wol), reboot and shutdown the linux box.

I hope the situation is more clear now.
P.
 
Old 01-11-2010, 02:57 AM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910
Somewhat more clear, but not all clear ;}

That server - when it reboots, does it automatically log in a user?
Which user is it using?
Which distro/version of Linux are you using, how does it authenticate
the display of X sessions?

Anyway - at the end of the day the machine needs to
a) have a running X session with someone logged in
b) it must permit X programs to display even if not
started from the current session (which is what your
remote script is doing).

b) is commonly something like "xhost +localhost" which you need
to run from whichever autostart mechanism that users X-session has.

And invoking gqview from the windows box you'll need to prepend the
execution with "DISPLAY=<servername-or-ip>:0.0"



Cheers,
Tink
 
1 members found this post helpful.
Old 01-11-2010, 08:51 PM   #5
Peterken
Member
 
Registered: Apr 2007
Location: Belgium
Distribution: Debian
Posts: 63

Original Poster
Rep: Reputation: 20
Hi Tinkster, thank you for that tip; it got me a little further.
I didn't think the rest was important but here it is:

- yes, I configured it for autologon with a normal user and gqview autostarts after logon.
- I've used debian with gnome
- since the system is physically not reachable, it will be started through a wol script at logon on a windows machine.
- shutting down will be done through crontab

There are just a few tweaks left to do.
I guess there is a problem with the graphics driver since the system doesn't always show the desktop but just a black screen. If I connect to it with vnc, everything seems fine.
I have not found any info about it yet but even by starting gqview from command line, it briefly shows the program interface and I wonder if there is a way to start it minimized.
 
  


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
How to use Putty(plink command line) to using application keypad settings to VT400? hocheetiong Linux - Newbie 1 08-14-2008 09:47 AM
ssh denies putty after windows reboot kav Linux - Networking 3 03-20-2007 10:14 AM
[putty&ssh] Who is really good & expert in ssh https tunnelling and firewalling ? Xeratul Linux - General 12 12-03-2006 04:22 AM
SSH connection from Linux to Windows using PuTTy legendaryhwk Linux - Security 2 04-05-2006 07:34 PM
Printing from Linux to Windows Printer through puTTY (ssh)? itsman Linux - Networking 1 09-22-2004 01:50 PM

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

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