10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Good Morning,
I have a copy script on Solaris 9 machine that is supposed to copy some files to a NAS using: cp -r /dir/dir/ /dir/dir/dirThe script doesn't finish. The directory contains user files of which one seems to copy fine, a second was failing until I did achmod -R -777 to it. Now,... (6 Replies)
Discussion started by: Stellaman1977
6 Replies
2. Shell Programming and Scripting
I have made a shell script(/bin/sh) that starts a perl script (that I haven't made my self) that's starts a ssh session. The ssh session uses a private/public key to login so no password is needed. The Perl script works perfect.
But when I put it in a cronjob (crontab) the ssh connection asks... (6 Replies)
Discussion started by: splinter_cell
6 Replies
3. Shell Programming and Scripting
I'm currently trying to write a login script. I have already written a logoff script that uses an if/else statement.
#!/bin/bash
TIMED=$(date +%H)
if ' then
echo Have a Great Day $USER
else
echo Have a Great Night $USER
fi
But I'd like to write one that give me the option of... (1 Reply)
Discussion started by: bbowers
1 Replies
4. Shell Programming and Scripting
Hi all,
When I cp a script, this section of the code stops reading from a file.
if ; then
while read dirtoclean
do
DIRSTOCLEAN=${DIRSTOCLEAN}' '$dirtoclean
done < ${BASEDIR}test.conf
fi
${DIRSTOCLEAN} doesn't return anything, even though it will work right before... (6 Replies)
Discussion started by: nicksantos1
6 Replies
5. Shell Programming and Scripting
Hi
I am working on a server that is set up and maintained by a third party. It seems whenever I run bash scripts in the background (with a &) with while loops in them they seem to me killed in around 2.5 hours. ( I am running them as a normal user with no special privileges ) . Is there a... (3 Replies)
Discussion started by: pkabali
3 Replies
6. Shell Programming and Scripting
I need help for writing a logon/logoff script for recording user's computer usage time. This is for local login only, not for ssh or something like that.
When a user logon, there should be a temp file (/home/acct/login_temp) generated including the logname and logon time information in the... (8 Replies)
Discussion started by: jimx
8 Replies
7. Shell Programming and Scripting
Hi Guys,
See the below code. The command below the cleartool setview ITG_Automation is not executing.
Could you please suggest.
#!/bin/ksh
echo $0
cleartool setview ITG_Automation
echo $0 (3 Replies)
Discussion started by: ajincoep
3 Replies
8. Shell Programming and Scripting
My script is very simple. It call isql and then echo a message. The problem is after the 1st command (isql), it stops so that the echo line never gets executed. Can anyone let me know what is wrong?
#!/usr/bin/sh
userid=xxxx
server=xxxx
db=xxxx
pwd=xxxx
isql -U ${userid} -S ${server}... (3 Replies)
Discussion started by: robbyls
3 Replies
9. UNIX for Advanced & Expert Users
I know we can put whatever we need to run during login inside /etc/profile or .profile file. I want to run a set of commands before logoff. Where should I put my commands/scripts? Is such facility available? (3 Replies)
Discussion started by: praveenkumar_l
3 Replies
10. UNIX for Dummies Questions & Answers
Will someone please share a script with me that will read in each line of the who -u output and if idle time is more than 50 min, execute a kill on the PID? This is what I have so far:
who -u | cut -c 40-56
I am comfortable in the korn shell, but I can broaden my horizons if you've got... (4 Replies)
Discussion started by: michieka
4 Replies