RE: Running as a certain user
From: Derrick Ryalls (ryallsd_at_datasphereweb.com)
Date: 11/30/03
- Previous message: Trey Sizemore: "Re: Laptop starts back up on its own"
- In reply to: Steve Bertrand: "RE: Running as a certain user"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: <iaccounts@northnetworks.ca> Date: Sat, 29 Nov 2003 18:06:40 -0800
> > > On Sat, Nov 29, 2003 at 02:49:58PM -0800, Derrick Ryalls wrote:
> > > > I am running a Counter Strike server on a 4.7 FreeBSD box, and I
> > > > recently got it all working running as a normal user (had
> > > been running
> > > > as root). The game is installed in a users' homedir and
> > > eventually I
> > > > will be revoking login rights to the user in question to furthur
> > > > minimize risk. To do this, I need to be able to run
> the scripts as
> > > > the user instead of whoever is logged in as.
> > > >
> > > > The structure of the scripts is like this:
> > > >
> > > > master script (start stop, public private args)
> > > > |
> > > > run_hlds wrapper script ( command line args for hlds_run )
> > > > |
> > > > hlds_run ( Valve prog )
> > > >
> > > > All three of the above scripts are owned by the isolated
> > > user and have
> > > > been chmod'ed to 6755. When I log in as a different user
> > > and try to
> > > > run the scripts, I get permission issues and am unable to
> > > fire off the
> > > > game server. What I need is to be able to run it on
> demand as the
> > > > isolated user like a crontab entry.
> > > >
> > > > Any ideas on what I am missing?
> > > I would say you need to make sure that the files are all
> > > owned by the user you're trying to run the hlds_run app as -
> > > in the past this has worked fine for me:
> > >
> > > chown -R user:user /path/to/hlds/
> > >
> >
> > I just double checked, all files under that folder are owned by
> > user:user...
>
> Try running the app with the command:
>
> # su user -c "/usr/bin/program"
>
> from crontab as you said.
>
Thanks, that is close enought to what I was looking for. All this time
I though 'su' meant 'super user'.
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"
- Previous message: Trey Sizemore: "Re: Laptop starts back up on its own"
- In reply to: Steve Bertrand: "RE: Running as a certain user"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
- Re: What programming language for Future
... version of the app. ... app-provided scripts will change with the vm,
... Which is exactly the same as when the compiler is shipped with the app. ...
which was more for things to serve as plain scripting languages. ... (comp.lang.misc) - Re: Newbie Questions
... applications folder within their home folder for apps they do not wish ... >
the switched-to app's body window to the foreground and sometimes not. ... > also not
do it when none of my apps is the current app. ... > - How can I play a song
with iTunes without bringing up an iTunes UI? ... (comp.sys.mac.system) - Re: Newbie-ish dialog box questions
... My app uses FiveWin. ... and elsewhere are written with Clipper ...
writing code blocks. ... and call code blocks in these scripts! ... (comp.lang.clipper) - Re: Security Error over LAN
... Actually, you can run scripts that require high privilege from GPO, but they ...
there are MSI packages - they execute as LOCAL SYSTEM on the client - this ... build an
MSI that programmatically modifies policy (recommended) ... I was able to get the app
to work by ... (microsoft.public.dotnet.security) - Re: Security Exception when deploying a VB.NET 2003 Solution
... It runs fine on any workstation. ... folder 2 levels up from the BIN
folder where the application resides. ... Microsoft .NET security errors upon trying to
start the Executable. ... I bet the workstaion is WinXP and your app is trying to write
data( ... (microsoft.public.vsnet.general)