Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8413759
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T00:59:04+00:00 2026-06-10T00:59:04+00:00

I am trying to run an shell script on a Linux Ububtu 12.04 LTS

  • 0

I am trying to run an shell script on a Linux Ububtu 12.04 LTS server.
Here is my script:

#!/bin/bash
PROGRAM=./home/lab/data/setup_exp/Simulator
FILE_PART_PREFIX="/home/lab/data/pcap_partial/h_"
FILE_PART_NUM=3
RECEIVER_SIZE=4096
SENDER_SIZE=4096
BETA=0.25
UPDATE=400
MARKER=20
MODE=5
RESULT_PREFIX="/home/lab/data/setup_exp/size/size_eq4/res_"
time_part=1200
if [ ${time_part} -eq 1200 ];then
 nohup ${PROGRAM} 1 ${FILE_PART_PREFIX}${time_part}.pcap ${RECEIVER_SIZE} ${SENDER_SIZE} ${BETA} ${UPDATE} ${MARKER} ${MODE} >> ${RESULT_PREFIX}${time_part} 2>&1 &
fi
time_part=1500
if [ ${time_part} -eq 1500 ];then
nohup ${PROGRAM} 1 ${FILE_PART_PREFIX}${time_part}.pcap ${RECEIVER_SIZE} ${SENDER_SIZE} ${BETA} ${UPDATE} ${MARKER} ${MODE} >> ${RESULT_PREFIX}${time_part} 2>&1 &
fi
time_part=1900
if [ ${time_part} -eq 1900 ];then
nohup ${PROGRAM} 1 ${FILE_PART_PREFIX}${time_part}.pcap ${RECEIVER_SIZE} ${SENDER_SIZE} ${BETA} ${UPDATE} ${MARKER} ${MODE} >> ${RESULT_PREFIX}${time_part} 2>&1 &
fi

Then, These are files and sub-directory in the directory of the script above, called sizesetup.sh : Simulator size sizesetup.sh
The permission of Simulator and sizesetup.sh are set to 755.

In addition,the input files of Simulator are under /home/lab/data/pcap_partial
, which are named h_1200, h_1500 and h_1900.

My problem is that I used sh sizesetup.sh to run this script without any error messages popping out. However, the script was not executed (I used ‘top’and ‘ps’ commands to check the state of the script)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T00:59:05+00:00Added an answer on June 10, 2026 at 12:59 am

    This line looks suspicious to me:

    PROGRAM=./home/lab/data/setup_exp/Simulator
    

    I don’t think the leading dot is to be there. You might have come from Windows and heard that on Linux in order to run a program you need to invoke it like this: ./program.

    That’s not technically true. The reason of that confusion is the difference in PATH handling in Windows and Linux.

    On Windows when you try to execute a program the current directory is searched first regardless of current directory being listed in %PATH% environment variable.

    On Linux the current directory is neither searched implicitly (as opposite to the Windows behavior) nor the current directory (that is .) is included in the $PATH environment variable by default. Thus in order to execute a program residing in the current directory you invoke it like this: ./program, i.e. explicitly specifying a relative path to the executable.

    ./home/lab/data/setup_exp/Simulator doesn’t look like a relative path (though I might be wrong for sure), thus the leading dot is not supposed to be there.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been trying to run Linux shell script on Windows machine. to run
You can run a scala script as a linux shell script: #!/bin/sh exec scala
I am trying to run a jar using this command in my shell script
I've been trying to run a file through a shell script and write its
I'm trying to run a script which stops and starts Tomcat on linux. When
I am trying to run a shell from my python program. I have used
I am trying to Run Shell script in Cygwin but I am getting Following
I'm trying to use the linux utility make in order to Run a script
I am trying to run a shell script from within a .vimrc file (three
I'm trying to run this shell script in order to install RVM in an

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.