LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-09-2006, 01:03 AM   #1
3saul
Member
 
Registered: Aug 2004
Location: Brisbane, Australia
Distribution: Ubuntu/Fedora
Posts: 86

Rep: Reputation: 15
Hiding arguments in shell scripts


I'm writing some shell scripts that execut a lot of external commands and when I look at the process in system monitor it displays every single command in the arguments section. How can I prevent this from happening? How can I stop the arguments from being displayed?
 
Old 01-09-2006, 01:26 PM   #2
bulliver
Senior Member
 
Registered: Nov 2002
Location: Edmonton AB, Canada
Distribution: Gentoo x86_64; Gentoo PPC; FreeBSD; OS X 10.9.4
Posts: 3,760
Blog Entries: 4

Rep: Reputation: 78
Don't run the scripts...

A trite answer, but I don't think it is possible. If your real problem is that you don't want regular users to see what you're doing, then look into the grsecurity patches and use 'proc restrictions' which will allow users to view only their own processes in /proc, ps, etc...

If not, then please tell us what your real goal is.
 
Old 01-09-2006, 02:44 PM   #3
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Mint
Posts: 17,809

Rep: Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743Reputation: 743
When you run a script, anything that generates output goes to the mysterious "stdout". When you call your script from a terminal session, then that terminal is stdout. All you need to do to suppress the output is redirect it elsewhere---eg to a file, to /dev/null, etc.
If you run a script from an application link, then nothing gets displayed anywhere--unless of course, the script tells the OS to open a window by some means.

Does this relate to your question??
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting 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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Passing arguments to a shell script subu_s Programming 3 09-02-2005 05:13 AM
Hiding Server Side Scripts TomalakBORG Linux - Enterprise 3 07-26-2005 02:47 PM
number of command line arguments to shell u4u Linux - General 1 03-04-2005 06:09 PM
Apache passing arguments to a shell script disabled? mikeyt_333 Linux - Security 3 08-03-2004 06:09 PM
Shell Programming: Hiding the o/p of the Kill command funkymunky Programming 5 06-10-2004 06:38 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:22 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration