VectorLinux
July 28, 2014, 04:22:24 pm *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: 1 [2]
  Print  
Author Topic: Autostart sshd and vncserver on 5.9 light[SOLVED]  (Read 5581 times)
nightflier
Administrator
Vectorian
*****
Posts: 4018



« Reply #15 on: July 29, 2008, 09:43:42 am »

Glad you made some headway.   Grin

I did try this on one of my machines. Created a script similar to yours, made it executable and tested it. Next, added /home/user/vncstart to /home/user/.jwmrc right below "pcmanicons on". Works for me every time. Not sure what the issue may be.
Logged
dukefluke
Member
*
Posts: 31


« Reply #16 on: July 29, 2008, 09:56:05 am »

I just want to say thank you again to M0E-lnx and nightflier for all of your help and suggestions.

What I need is to be able to connect to this machine remotely through vnc. I thought I would need to autostart vnc to achieve this. But I have discovered a better way. Instead of having vnc running all the time with 5900 open. I can just have 22 for ssh open and then start x11vnc(btw I switched from tightvnc to x11vnc cause I can control local display of remote machine) from my desktop like this:

Code:
ssh -t user@192.168.3.111 "x11vnc -display :0 -bg"

 this starts vnc on port 5900 then I can connect with:

Code:
vncviewer 192.168.3.111:5900

I'll just make a small script to automate those two commands.

I think this is better from a security point of view, plus now I don't have to setup every window manager(jwm,fluxbox,etc) Cheesy

nightflier, I think because I had switched to x11vnc that might have been the problem I'm going to reinstall tightvnc and test it again just to see if I can make it work.
Logged
dukefluke
Member
*
Posts: 31


« Reply #17 on: July 29, 2008, 10:11:26 am »

Yeah that was it.

me=dumb. Sorry guys. I should have mentioned I had switched to x11vnc. Tightvnc server starts fine from ~/.jwmrc. It was x11vnc that wasn't starting correctly.

In a way I'm glad I went through all that trouble 'cause I learned a lot and figured out a better way to do
what I wanted. I'm just sorry I wasted your guys time.

Thanks again.  Undecided
Logged
bigpaws
Vectorian
****
Posts: 1843


« Reply #18 on: July 29, 2008, 10:35:49 am »

Quote
I'm just sorry I wasted your guys time.
If you learned something then nothing was wasted.

Bigpaws
Logged
nightflier
Administrator
Vectorian
*****
Posts: 4018



« Reply #19 on: July 29, 2008, 11:37:57 am »

No waste at all. Happy to be of help.  Smiley
Logged
M0E-lnx
Administrator
Vectorian
*****
Posts: 3178



« Reply #20 on: July 29, 2008, 01:10:25 pm »

Glad you figured it out.

Actually, if I were you i'd enhance security by forwarding my port 22 to something else.
I used to ssh then vnc to my box @ home from work, using the standard ports, until one day, looking @ the logs, I discovered thousands of attempts to hack my box. (maybe automated scripts)..

to avoid that, you either change the ports your ssh server will listen on or forward your 22 to some other port.
Logged

dukefluke
Member
*
Posts: 31


« Reply #21 on: July 30, 2008, 06:54:21 am »

Good idea M0E-lnx I'll do that.

On another slackware server I setup in the past I had the exact same problem with tons of login attempts showing up in the logs. So in the past I've done what you suggested and forwarded some weird random port number from the router/firewall to 22 on ssh server.

Right now this is just for play.  Grin
Logged
Pages: 1 [2]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!