- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Error message on Shell Program in Linux (this ...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2003 12:48 PM
тАО09-16-2003 12:48 PM
I had put this question earlier on this forum and couldnt get a reply. I am not able to solve it myself and hence this attempt once more. Please see if anybody has any wise words for me.
I have this long shell script that I have ported to Linux from HPUX. It is running fine on HPUX. I am running it under ksh in both the places.
On Linux it gives me an error message that doesn't give me any clue to what is happening. The error message is this.
SquDex: binLinux/Milling[128]: 0.00: unexpected `.'
SquDex is the main program that I started and binLinux/Milling is the other program it calls in between. I have no idea what this means: 0.00: unexpected `.'
I tried to run set -vx, but that doesn't give me any clue. Is there a way to run shell scripts line by line and debug?
Or does anybody have any clue what such an error means?
THe program runs and gives me the out put but since this error message is coming, I cant run the program in the production env. Please let me know if anybody has any suggestions...
Regards
Thanks in anticipation...
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2003 01:33 PM
тАО09-16-2003 01:33 PM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
Check that the shell statement at the top is valid.
I do not recall your earlier thread. I have never met a HP script I could not port to Linux or vice versa.
I will check the thread later.
If I help, please assign points. I'm in quite a Linux drought lately, lots of thank you's 10 points this week total.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2003 04:24 PM
тАО09-16-2003 04:24 PM
SolutionThere are something liek 5-6 different scritps in total, including various Awk routiens, is that correct?
I remember posting back a fixed routine (for the segment posted), but havnig no test data, I couldn't confirm everything.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-17-2003 08:28 AM
тАО09-17-2003 08:28 AM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-19-2003 11:19 AM
тАО09-19-2003 11:19 AM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
I didn't get any of the scripts back. I am attaching four of the scripts. SquDex is the first one to be run. This calls the Squaring and then it calls the Milling and from there GenMIll is called. I can see the parameters getting assigned the 0.00 values. I ran the script with set -xv on the first line in 'Milling' program and if you see this is where it gets the problem.
>> Kiwa3_Squaring.nc
+ binLinux/GenMill Kiwa3 RotBro 1 0 1 0.00
+ echo 0.00
+ gawk -F. {print $1}
+ Bro1=0
+ gawk -vOp=1 -vOffset=0.0,0.0,0.0 -vBro=0 -vSafeZ=11.2912 -vBlk=0 -f awk/Position usr/Kiwa3_Squaring.par usr/Kiwa3_Station#1.par FixLib
+ WriteOps
./SquDex: binLinux/Milling[129]: 0.00: unexpected `.'
./SquDex: binLinux/Milling[129]: 0.00: unexpected `.'
+ ReadOpLine 2 1
The last two lines are the errors. I am attaching the tar file that contains the four programs. I hope if I can define that as integar the problem may be over.
THanks for the help
Regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-21-2003 03:23 PM
тАО09-21-2003 03:23 PM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-21-2003 10:42 PM
тАО09-21-2003 10:42 PM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
Thanks. The output shown in my previous e-mail is the result of putting -x
Kiwa3_Squaring.nc
+ binLinux/GenMill Kiwa3 RotBro 1 0 1 0.00
+ echo 0.00
+ gawk -F. {print $1}
+ Bro1=0
+ gawk -vOp=1 -vOffset=0.0,0.0,0.0 -vBro=0 -vSafeZ=11.2912 -vBlk=0 -f awk/Position usr/Kiwa3_Squaring.par usr/Kiwa3_Station#1.par FixLib
+ WriteOps
./SquDex: binLinux/Milling[129]: 0.00: unexpected `.'
./SquDex: binLinux/Milling[129]: 0.00: unexpected `.'
+ ReadOpLine 2 1
The output RotBro 1 0 1 0.00 and the vOffset=0.0,0.0,0.0 are the ones that cause the errors below that I guess.(My guess is not very good as I don't have much insight into shell scripts). MY question will be to how to get them to be '0' rather than 0.0. Where I do define the variable associated with them to be integers with out decimal places. One thing that I didn't understand is why they ran ok in HP-UX, but has this problem in Linux. COuld it be because of anything else. If so, what and how could I get over it?
Thanks for the inputs. I will remember to assign points
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-22-2003 01:05 PM
тАО09-22-2003 01:05 PM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-22-2003 04:45 PM
тАО09-22-2003 04:45 PM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
Have you changed the shell from /bin/ksh or do you have a shell on your system.
The first thing I always do to a script in conversion is change that.
Of course it would have failed before line 91 in that case.
I recently fixed an HP-UX script that was using the shift command to wipe out its $1 and $2 variables. Nothing like that here.
Could there be an extraneous character in the script tripping it up. The error almost looks like when the closed quotes is missing in a script.
echo "schmo bagel
instead of
echo "schmo bagel"
Its not that simple, but one nasty little inviviible character can mess it up.
I've finally gotten to downloading the script and am attempting to run it.
I just run it ./Milling
No command line parameters?
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-23-2003 03:02 AM
тАО09-23-2003 03:02 AM
Re: Error message on Shell Program in Linux (this runs perfectly under HP-UX 10.20)
$Bro gets set in GenMill as I understand
Steven,
Yes, I have set up /bin/ksh as my environment. I have ksh running.
The first script to run is SquDex. That calls Milling and then GenMill and Squaring. Since you don't have a lot of the data files, it may give errors. But I am not sure if that will stall everything. To send the data files, it will be impossible as it will run into many MBs.
As you suggested I also suspect some where " is missing. But how do I find that? Is there any way, to match it using a debug program?
Thanks for your help. I look forward to hearing something more on this.
Regards