|
|
|
command TR suddenly fails
|
Original Message
|
Name: tvc02
Date: June 3, 2008 at 07:02:58 Pacific
Subject: command TR suddenly failsOS: w2kCPU/Ram: n/aModel/Manufacturer: n/a |
Comment: Using TR command like this: echo Test | tr [A-Z] [a-z] ... with Bourne shell. Worked OK for a bunch of users on same server, suddenly, it does not work anymore for 1 particular user. I do not see any differences between this user and other ones. When it fails, he just displays : "Test" For the other users, he displays "test" What's wrong ?
Report Offensive Message For Removal
|
|
Response Number 2
|
Name: tvc02
Date: June 4, 2008 at 03:47:06 Pacific
|
Reply: (edit)The shell is not different, both have /usr/bin/bash as shell, checked that as first thing. If I use syntax: echo Test | tr [:upper:] [:lower:] ... I'm getting "Bad String", on the user that does work, if you do : echo Test | tr [upper] [lower] I'm gessing that the TR command is just buggy, but I would like somebody to confirm this. There's obviously an external factor, deciding on the behaviour of this command, which should not be.
Report Offensive Follow Up For Removal
|
|
Response Number 5
|
Name: nails
Date: June 9, 2008 at 20:07:29 Pacific
|
Reply: (edit)I'm running these tr tests on a Solaris 9 unix box. Both examples work fine, but the Solaris tr MAN pages examples exclusively use quotes around the tr arguments. Until I saw your post, I had never heard of not using quotes. I looked in my favorite Unix reference - Unix in a Nutshell - and this reference exclusively uses quotes. If I were you, I'd exclusively use quotes as obviously without quotes tr usage is inconsistent.
Report Offensive Follow Up For Removal
|
|
Response Number 6
|
Name: tvc02
Date: June 10, 2008 at 02:06:32 Pacific
|
Reply: (edit)OK Thanks, I'm using Solaris 10 by the way I need to updat all my scripts now, because otherwise it does not run for this one unix-user only, since some days, for an unknown reason
Report Offensive Follow Up For Removal
|
Use following form to reply to current message:
|
|

|