LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   problem with vncserver and boot script (https://www.linuxquestions.org/questions/linux-general-1/problem-with-vncserver-and-boot-script-782362/)

RAFAL 01-15-2010 06:44 AM

problem with vncserver and boot script
 
Hi,

Today I wanted to start something when our SLES 10.2 server starts.
Just one command like
"sudo -u myuser vncserver :1"

However the problem was that I couldn't find a right place to add the command. According to this post
http://fixunix.com/suse/552471-how-e...g-boot-up.html
I should edit someting like /etc/rc.local or /etc/init.d/boot.local
This didn't work.
I found a way searching for how SLES shows message put in /etc/issue wile ("Welcome to SLES...etc")
I found /etc/init.d/rc in which I added:
"sudo -u myuser vncserver :1"
Command was executed, however system informed me that "vncserver command not found"
This worked ONLY with full path:
"sudo -u mysuser /usr/X11R6/bin/vncserver :1"

Strange but the way described in the official SUSE HOWTO:
http://en.opensuse.org/VNC_HOWTO
didn't worked at all (like "chkconfig --add vnc" which says "vnc: not runlevel service").
I have installed tightvnc 1.2.9-2001.17

If somebody can post any comments why in my case system worked differently and show me more proper way to execute command when SLES system starts, then it will be helpful. Otherwise I just post my solution in case somebody will face something similar.

regards
Rafal

acid_kewpie 01-15-2010 09:05 AM

Can I suggest that you try a decent remote control client like NX from nomachine.org instead of VNC? VNC is such a nasty and insecure service.

RAFAL 01-17-2010 05:09 AM

Quote:

Originally Posted by acid_kewpie (Post 3827572)
Can I suggest that you try a decent remote control client like NX from nomachine.org instead of VNC? VNC is such a nasty and insecure service.

security is not a issue here, because its local corporate network behind a several firewalls. This server is 3 meters from my desk and using VNC is only because I am to lazy to change my sit ;-)
Thanks for suggestion about NX. I see its based on Java. Personally I do not like Java applications.


All times are GMT -5. The time now is 11:21 PM.