bourne shell or korn shell?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers bourne shell or korn shell?
# 1  
Old 10-06-2006
bourne shell or korn shell?

Hi,
I have a script that uses "nohup" command to execute a korn shell script. Which one is the correct shell to use bourne shell or korn shell to execute a korn shell? and why?

Thanks in advanced.
# 2  
Old 10-06-2006
if you want to execute a korn shell script, use korn shell to execute it. If you use bourne shell to execute a korn shell script, you may get syntax errors since some korn shell syntax differs from bourne shell.
# 3  
Old 10-06-2006
Use at the first line of the korn script
#!/bin/ksh

and then you can run this script from sh

Last edited by Hitori; 10-06-2006 at 03:43 AM..
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Cybersecurity

'Shell Shock' vulnerability in Bourne shell

A severe vulnerability was discovered in Bourne shell. Just google for: bash vulnerability ... for more details. (5 Replies)
Discussion started by: Cochise
5 Replies

2. Shell Programming and Scripting

Bourne shell & Korn shell

Could some one tell me the difference btw Bourne shell and the Kshell? Which is more flexible and reliable in terms of portability and efficiency. When i type the following command .. $ echo $SHELL yields me /bin/sh Does this tells me that I am in Bourne shell. If yes, how can i get... (6 Replies)
Discussion started by: bobby1015
6 Replies

3. Shell Programming and Scripting

How to activate Korn Shell functionnalities in Bourne Shell

Hi All I have writing a Korn Shell script to execute it on many of our servers. But some servers don't have Korn Shell installed, they use Borne Shell. Some operations like calculation don't work : cat ${file1} | tail -$((${num1}-${num2})) > ${file2} Is it possible to activate Korn Shell... (3 Replies)
Discussion started by: madmat
3 Replies

4. Shell Programming and Scripting

I need to understand the differences between the bash shell and the Bourne shell

I do not claim to be an expert, but I have done things with scripts that whole teams of folks have said can not be done. Of course they should have said we do not have the intestinal fortitude to git-r-done. I have been using UNIX actually HPUX since 1992. Unfortunately my old computer died and... (7 Replies)
Discussion started by: awk_sed_hello
7 Replies

5. UNIX for Dummies Questions & Answers

what are some different commands in c shell and korn shell??

I am doing this simple script using c shell and korn shell. The commands I use are fgrep , ls, and also some redirecting. Is there any difference in using both of these commands in c shell and korn shell? Thanks and sorry for the stupid question. (1 Reply)
Discussion started by: EquinoX
1 Replies

6. AIX

tsh shell to korn shell

i got stuck in IBM AIX unix and i was googling for the answer. but i didn't find one. can anyone tell me how to get back from tsh# shell to korn shell my system is showing tsh shell in the terminal but i am unable to get back to korn shell. i tried chsh, shell, su, logout, exit commands but not 1... (7 Replies)
Discussion started by: arifkhan
7 Replies

7. Shell Programming and Scripting

C shell & Bourne Shell

Hi Guys, My first post and simple one at that .. Really rusty with this shell scripting..\ I have a script called .. j.sh I am calling > j.sh LOG_PATH $BLMBRGDATA/blmbrg.properties where j.sh is grep $1 $2 | cut -d',' -f2 . $BLMBRGDATA is set to a directory path. why do i get :- $... (3 Replies)
Discussion started by: jsm66
3 Replies

8. Shell Programming and Scripting

how to convert from korn shell to normal shell with this code?

well i have this code here..and it works fine in kornshell.. #!/bin/ksh home=c:/..../ input=$1 sed '1,3d' $input > $1.out line="" cat $1.out | while read a do line="$line $a" done echo $line > $1 rm $1.out however...now i want it just in normal sh mode..how to convert this?... (21 Replies)
Discussion started by: forevercalz
21 Replies

9. Shell Programming and Scripting

KORN Shell - Spawn new shell with commands

I want to be able to run a script on one server, that will spawn another shell which runs some commands on another server.. I have seen some code that may help - but I cant get it working as below: spawn /usr/bin/ksh send "telnet x <port_no>\r" expect "Enter command: " send "LOGIN:x:x;... (2 Replies)
Discussion started by: frustrated1
2 Replies

10. Shell Programming and Scripting

Read a file and replace a value- Bourne and Korn shell

Hello, I have a file called Delete and within the delete file I have the following statement: delete from employee where employee_id = " " how do I write a script that read from this file and replace: employee_id = " " with employee_id is null Please assist...greatly... (3 Replies)
Discussion started by: kenix
3 Replies
Login or Register to Ask a Question