11-02-2011
It is more a permission issue than a scripting issue then ... i think you should clearly identify what are you needs in terms of access granting and then set the relevant chmod chown chroot and sudo stuff to achieve those restrictions instead of adding new lines of code to handle such kind of things.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
While logged on as root, I created a user 'usera'
I also created a group called 'groupa'
I need to modify the permission of the user i created to not have root privileges.
I also need to change groupa to be in 'others'
please help!
thanks,
nieves (3 Replies)
Discussion started by: mncapara
3 Replies
2. Shell Programming and Scripting
Hi
I am trying to add variables(float values) in a unix script but am getting an error
value=`expr $a + $b + $c`
The error I am getting is "expr: non-numeric argument"
I guess it has got to something with the decimal points.
Plz help (13 Replies)
Discussion started by: akashtcs
13 Replies
3. Shell Programming and Scripting
Hi,
I am running a Java program from a unix script. I need to pass a variable to the Java code from a file. Here are teh details:
cat Parm <<this is my Parameter file>>
queuename=queue1
and my shell script is :
#!/bin/ksh
. ./Parm
/opt/java1.5/bin/java -classpath ./java.jar... (1 Reply)
Discussion started by: sangharsh
1 Replies
4. Shell Programming and Scripting
I'm creating a script that asks a user for a variable
ex
read filename;
read numberinput;
I also have a bunch of files named file.0 file.1 ... file.55
I'm trying to delete all files (if they exist) about file.$numberinput.
Can someone help me out on how to include the variable as part... (6 Replies)
Discussion started by: jenix4545
6 Replies
5. Shell Programming and Scripting
Hi,
I am trying to use a database to store configurations in an environment definition scripts to make the configurations easily modifiable. (long story short - it is an easier process to make changes in the db than trying to deploy a file). The values will be stored in the database in the... (1 Reply)
Discussion started by: gbala
1 Replies
6. Shell Programming and Scripting
Hi All,
I am using ETL tool Datastage and is installed on Linux environment. Few environment variables are set in datastage. Now my requirement is to use those environment variables in a unix script.
Is there any option I can do it?
Sugeestions from people working on datastage and linux... (1 Reply)
Discussion started by: bghosh
1 Replies
7. Shell Programming and Scripting
I'm pretty new to scripting in Korn shell so please forgive me...
What I'm trying to do is to create a script that calls multiple other ksh scripts and defines variables for text files.
I need it to define my user defined variables (file paths, date & time stamps, etc that are currently in... (1 Reply)
Discussion started by: bluejwxn8
1 Replies
8. Shell Programming and Scripting
Dear Shell script Experts,
I am working on shell script which is defined here, qsub_seq.csh . The purpose of this script is to read few input files (with defined starting index and last index) and make processing faster over server.
For some task, I had 1064 of input files, so I wrote another... (8 Replies)
Discussion started by: emily
8 Replies
9. Shell Programming and Scripting
Hi,
I just define the variable in script and use those script in another script but the variable not recognize.
test1.sh
#!/bin/bash
DB="test_db"
USR="test_user"
PWD="test_pwd"
HST="24.254.87.12"
test2.sh
#!/bin/bash
./test1.sh
mysql -u $USR -p $PWD -h $HST... (2 Replies)
Discussion started by: fspalero
2 Replies
10. Shell Programming and Scripting
I have written a script to execute some sql statement via executable file.
It is working fine via command line, however when I schedule it in cron.
The executable file is looking for library file in its root directory.
Wonder where does cron run the script from, and can we get the script... (4 Replies)
Discussion started by: jaapar
4 Replies
MINGETTY(8) Linux Programmer's Manual MINGETTY(8)
NAME
mingetty - minimal getty for consoles
SYNOPSIS
mingetty [--noclear] [--nonewline] [--noissue] [--nohangup] [--nohostname] [--long-hostname] [--loginprog=/bin/login] [--nice=10]
[--delay=5] [--chdir=/home] [--chroot=/chroot] [--autologin username] [--loginpause] tty
DESCRIPTION
mingetty is a minimal getty for use on virtual consoles. Unlike agetty(8), mingetty is not suitable for serial lines. I recommend using
mgetty(8) for this purpose.
OPTIONS
--noclear
Do not clear the screen before prompting for the login name (the screen is normally cleared).
--nonewline
Do not print a newline before writing out /etc/issue.
--noissue
Do not output /etc/issue.
--nohangup
Do not call vhangup() to disable writing to this tty by other applications.
--nohostname
Do not print the hostname before the login prompt.
--long-hostname
By default the hostname is only printed until the first dot. With this option enabled, the full text from gethostname() is shown.
--loginprog /bin/login
Change the login app.
--nice 10
Change the priority by calling nice().
--delay 5
Sleep this many seconds after startup of mingetty.
--chdir /home
Change into this directory before calling the login prog.
--chroot /chroot
Call chroot() with this directory name.
--autologin username
Log the specified user automatically in without asking for a login name and password. Check the -f option from /bin/login for this.
--loginpause
Wait for any key before dropping to the login prompt. Can be combined with --autologin to save memory by lazily spawning shells.
ISSUE ESCAPES
mingetty recognizes the following escapes sequences which might be embedded in the /etc/issue file:
d insert current day (localtime),
l insert line on which mingetty is running,
m inserts machine architecture (uname -m),
inserts machine's network node hostname (uname -n),
o inserts domain name,
inserts operating system release (uname -r),
insert current time (localtime),
s inserts operating system name,
u resp. U the current number of users which are currently logged in. U inserts "n users", where as u only inserts "n".
v inserts operating system version (uname -v).
EXAMPLE
"Linux eos i386 #1 Tue Mar 19 21:54:09 MET 1996" was produced by putting "s
m v" into /etc/issue.
FILES
/etc/issue, /var/run/utmp.
SEE ALSO
mgetty(8), agetty(8).
AUTHOR
Copyright (C) 1996 Florian La Roche <laroche@redhat.com>. Man-page written by David Frey <David.Frey@eos.lugs.ch> and Florian La Roche.
Debian-Local 6 Apr 1996 MINGETTY(8)