Discussion Locked

RedHat 7.1 and tcsh

0 helpful
15 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I have a script using csh to set permissions. It uses simple chown and chmod commands and has worked in RedHat 5.2, 6.2, and 7.0. With this version for some reason the script does not work. I tried making a test script that was just a one line csh script with a chown command and it didn't work. So I change it to bash and it worked. Can someone give me a clue here?
At this point I don't know if it makes a differnce but I am set to No Firewall.

15 replies

by valachi

It's not an answer (since I still run RH 6.2 I'm not very aware of the problems of RH 7.1) but, good manuals recommend that you use Bourne Shell syntax (or bash) to write the scripts. Many people are using csh or tcsh syntax because it looks like the C to which they are accustomed.
Btw - try to write some NT scripts and you'll see more weird things than in a freak show :-)

by hanes_ray

That would work but when I already have 50 some csh scripts that worked great in every other version of Linux that doesn't help me.

by mike12env

hey, can you tell me where you got your redhat 7.1 from? i have been searching all over the place you download it, but cannot find it.
could you tell me the exact url where i can download it?

thanx heaps champ!!

by mayurdeodhar

dear,
pl check whether u hv installed the C shell because it may be possible that it may not hv been installed by default. i suggest this cause as u say it works in bash. this may be the most basic reason for ur problem.
hope this helps.

by hanes_ray

Well unless I'm missing something tcsh is there and csh is linked too it. Just to make this a little clearer it is not all csh scripts I have just found that some commands especially chown an chmod will not work in the cshell

by beeba

When you call the programs, are you being explicit in naming exactly which chown etc.? With some systems, there are both SysV and BSD versions of programs.

/usr/ucb on Sun systems, for example, contains the Berkeley variants of commands.

Also,are you explicitly using csh as opposed to tcsh, even if they're symlinked to the same? If you call it "as" tcsh, instead of calling it "as" csh, it runs differently.

by maxwell edison

.
.
By the way, you should find your particular download about 3/4 down the page of the aforementioned link.

Best of luck,

Maxwell

by hanes_ray

Already found this with the release of RH 7.2 but I'm giving the points for the right answer.

by ann777

The last poster has the proper lead. You need to install the patches for 7.1 or upgrade to the current version (which is 7.2).

This discussion is closed to new replies.