Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Mac OS X > Linux sudo issue

Linux sudo issue
Thread Tools
Professional Poster
Join Date: Dec 2000
Location: Chicago, Illinois
Status: Offline
Reply With Quote
Sep 11, 2004, 11:48 AM
 
I have an issue with launching vncserver on my new slackware machine, and I was wondering if anyone has any ideas. In my /etc/rc.d/rc.local file, I have added the following:

sudo -s -u fahrenba /usr/local/bin/vncserver

the file vncserver is a perl script.

Now, if I execute the script vncserver while logged in as fahrenba, it works. But through sudo, it almost seems like perl is not set up correctly... which sounds odd.

Essentially, the first real line of perl code is a subroutine call "&SanityCheck();", and I get an error, not that the system is insane, but that there was a syntax error... which doesn't make any sense to me at all.

Does anyone have any suggestions?

Thanks!
     
Senior User
Join Date: Jan 2001
Location: Mahwah, NJ USA
Status: Offline
Reply With Quote
Sep 11, 2004, 12:50 PM
 
Originally posted by Ghoser777:
I have an issue with launching vncserver on my new slackware machine, and I was wondering if anyone has any ideas. In my /etc/rc.d/rc.local file, I have added the following:

sudo -s -u fahrenba /usr/local/bin/vncserver

the file vncserver is a perl script.

Now, if I execute the script vncserver while logged in as fahrenba, it works. But through sudo, it almost seems like perl is not set up correctly... which sounds odd.

Essentially, the first real line of perl code is a subroutine call "&SanityCheck();", and I get an error, not that the system is insane, but that there was a syntax error... which doesn't make any sense to me at all.

Does anyone have any suggestions?

Thanks!
What is the first line of the script?

#!/usr/bin/perl -w

or something?
-DU-...etc...
     
   
Thread Tools
Forum Links
Forum 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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 06:48 AM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2