10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all
Below code works in bash but it is not working in ksh.
enddate=`date -d "$enddate + $i day" "+%Y_%m_%d"`
Please help me how it works in ksh
Thanks (10 Replies)
Discussion started by: pmreddy
10 Replies
2. Shell Programming and Scripting
Hi I am having a problem exiting a WHILE loop. I am on a Sun server using ksh.
I am running a Veritas Cluster Software (High Availablity) command to obtain a group status and grepping the command output for status "G" which means that the filesystem is frozen and therefore not available to... (3 Replies)
Discussion started by: bigbuk
3 Replies
3. Shell Programming and Scripting
I am parsing file for the fields using awk command, first i check 26th field for two characters using substr function if it matches then using for loop on array i search 184th field for 4 chars if it matches then i print the required fields but on execution i get the error, please help...... (5 Replies)
Discussion started by: siramitsharma
5 Replies
4. Shell Programming and Scripting
Hi,
typeset -l sgf # all lowercase letters
typeset -u SGF # all uppercase letters
sgf=$1
SGF=$sgf
these lines used in my scripts . It ran fine in ksh but when we convert this to bash it erroring out.
I like to know what the use of typeset ??
Thanks & Regards
kanagaraj (3 Replies)
Discussion started by: kanagaraj
3 Replies
5. Shell Programming and Scripting
I'm trying to do a script where I want to see if all users home directories are only writable by owner. However, in my script I do not know how to implement the for loop so that all directories are checked. In mine, I am only checking the permissions for the first directory found. I do know that a... (3 Replies)
Discussion started by: detatchedd
3 Replies
6. Shell Programming and Scripting
I am using a Linux machine and it's default shell is BASH . I have korn shell script and inside it's setting environment variables. But after execuitng the script those env values are not holding the values . If I run the script outside of that ksh script with source a.sh , it's able to hold to... (2 Replies)
Discussion started by: talashil
2 Replies
7. Shell Programming and Scripting
I am using a Linux machine and it's default shell is BASH . I have korn shell script and inside it's setting environment variables. But after execuitng the script those env values are not holding the values . If I run the script outside of that ksh script with source a.sh , it's able to hold to... (1 Reply)
Discussion started by: talashil
1 Replies
8. UNIX for Advanced & Expert Users
Hello,
I have lib file which contain a function that get text to print on screen by echo command.
Several scripts are inculde this lib and use this function.
Each one of them is written in different shell language (sh ksh & bash).
This causing some issues when using backslash charater as... (4 Replies)
Discussion started by: Alalush
4 Replies
9. Shell Programming and Scripting
Hi,
I use AIX (ksh) and Linux (bash) servers. I'm trying to do scripts to will run in both ksh and bash, and most of the time it works. But this time I don't get it in bash (I'm more familar in ksh).
The goal of my script if to read a "config file" (like "ini" file), and make various report.... (2 Replies)
Discussion started by: estienne
2 Replies
10. Shell Programming and Scripting
Hi,
I'm having a problem with the while loop in bash. I try the following script:
#!/bin/bash
while true
do
echo "test"
done
When I try this, it gives me this error:
while: Too few arguments.
What am I doing wrong?
Thanks (5 Replies)
Discussion started by: Kweekwom
5 Replies