VNC Start up Script

Discussion and Technical Support for general software applications and utilities including OS related issues.
Post Reply
SergeantBort
Member
Member
Posts: 36
Joined: October 19th, 2012, 5:31 pm
Location: Baltimore, MD USA
Contact:

VNC Start up Script

Post by SergeantBort »

Hello, been using your page to help as a guide to set up my servers for a while now.

Decided to do a clean install, as I had some issues on my previous install, and decided to do 14.04. Had some issues getting the VNC desktop working, but found the other topic and using the alternate desktop vs gnome so that works for me.

I am trying to create my StartVNC.sh and I have created the script (actually same exact script that was previously on my server working fine, I backed up most of my files to notepad on my desktop to make rebuilding easier) and I am getting an error when trying to run the script.

Code: Select all

user@server:~/MyScripts$ ./StartVNC.sh
-bash: ./StartVNC.sh: /home/user/MyScripts/StartVNC.sh: bad interpreter: Too many levels of symbolic links
the VNC service works fine when I run it.

My script is the following

Code: Select all

#!/home/user/MyScripts/StartVNC.sh
#!/bin/sh
echo "JOB RUN AT $(date)"
echo "============================"
echo ""
/usr/bin/vncserver -geometry 1920x1080
Haven't gotten to getting to try to get it to work at start up, which I had previously used webmin (not yet installed want to get it to run at start up vs webmin, as using webmin for just cron jobs seems a bit excessive to me, but I may do that anyway)

Will be continuing to build the server, since this is a hiccup and does not stop me from doing anything, but I would really like to figure out what happening.
SergeantBort
Member
Member
Posts: 36
Joined: October 19th, 2012, 5:31 pm
Location: Baltimore, MD USA
Contact:

Re: VNC Start up Script

Post by SergeantBort »

Just an update, having the same issue with my DriveTempShutdown.sh script.. but my CPUTempShutdown is working without issue...

Tried both sudo and non, slighty different responses, but same basic message, too many levels of symbolic links

Code: Select all

user@server:~/MyScripts$ sudo ./DriveTempShutdown.sh 30 45
sudo: unable to execute ./DriveTempShutdown.sh: Too many levels of symbolic links
user@server:~/MyScripts$ ./DriveTempShutdown.sh 30 50
-bash: ./DriveTempShutdown.sh: /home/user/MyScripts/DriveTempShutdown.sh: bad interpreter: Too many levels of symbolic links
SergeantBort
Member
Member
Posts: 36
Joined: October 19th, 2012, 5:31 pm
Location: Baltimore, MD USA
Contact:

Re: VNC Start up Script

Post by SergeantBort »

Well I was able to get the VNC script to work, but my drive temp script remains having the issue.

After some google searching it appears basically this error means there is a loop in symbolic links (or there are to many links, there is a max of 32 jumps apparently)

The recommendation is to remove the link and recreate it. So I removed it, recreated the file re chmod the file and start VNC works now, but the Drive temp does not want to work, i have deleted and recreated it about 3 times at this point with the same issue, that one is not as important but still would be nice to have it working, I will keep looking around.
SergeantBort
Member
Member
Posts: 36
Joined: October 19th, 2012, 5:31 pm
Location: Baltimore, MD USA
Contact:

Re: VNC Start up Script

Post by SergeantBort »

Well I thought I got the drive one taken care of by uninstalling the tools and reinstalling it and recreating the script. , managed to run the script once, with errors, went to start editing the file and got the same error again, tried a quick uninstall reinstall again, not working, but will attempt again. Have tried several times without success.

And now even more fun, have some scripts to start virtual machines, two work fine,and two giving me the same symlink issue.. maybe i should start over again.. seems like something got messed up in the OS... but I would rather not do everything again, but getting these scripts to work, is fairly important, I have these four virtual server that need to be started, and VNC starting is helpful...
SergeantBort
Member
Member
Posts: 36
Joined: October 19th, 2012, 5:31 pm
Location: Baltimore, MD USA
Contact:

Re: VNC Start up Script

Post by SergeantBort »

Not really sure why this worked, but since I had working scripts, I had no luck creating a new one, but if I copied one of my working Start scripts with cp, to create the new script, they work without issue...

Very strange, maybe it will work for the Drive Temp script as well.
Post Reply